jmash-core 0.0.59 → 0.0.61
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{401-DE-TXzCc.mjs → 401-Da_FRa8F.mjs} +2 -2
- package/dist/{404-bKhkditH.mjs → 404-B-yLqgzc.mjs} +1 -1
- package/dist/{BarChart-DGjS_f26.mjs → BarChart-C4cVigGd.mjs} +2 -2
- package/dist/{PieChart-D66O_XMl.mjs → PieChart-DXAeeKov.mjs} +1 -1
- package/dist/{PieChart.vue_vue_type_script_setup_true_lang--HJAxB0M.mjs → PieChart.vue_vue_type_script_setup_true_lang-DeO-_Zu_.mjs} +2 -2
- package/dist/{RadarChart-BbEYnVIB.mjs → RadarChart-CWmASBqH.mjs} +1 -1
- package/dist/{RadarChart.vue_vue_type_script_setup_true_lang-BaKQP2dk.mjs → RadarChart.vue_vue_type_script_setup_true_lang-CPfyBKlD.mjs} +2 -2
- package/dist/{el-card-BFMPAwA0.mjs → el-card-BC8c6Nqv.mjs} +1 -1
- package/dist/{el-col-DFVyNU5b.mjs → el-col-DzruSagK.mjs} +1 -1
- package/dist/{el-form-item-Dv464MKF.mjs → el-form-item-FH0FWnW5.mjs} +1 -1
- package/dist/{index-DGsBiCbV.mjs → index-BEcfFlyz.mjs} +6 -6
- package/dist/{index-B_6ikcFI.mjs → index-BJJPA_t4.mjs} +5 -5
- package/dist/{index-DEBaC_jU.mjs → index-BduP3zhq.mjs} +4 -4
- package/dist/{index-otAWIrpX.mjs → index-CXNg2AIY.mjs} +1 -1
- package/dist/{index-BIgjgL-a.mjs → index-RCy_bVl2.mjs} +7 -3
- package/dist/index.mjs +1 -1
- package/dist/{picture-D2hiMs9J.mjs → picture-Be_t0ujg.mjs} +2 -2
- package/dist/{position-CHQrk0lU.mjs → position-Dr7Dp1AA.mjs} +1 -1
- package/dist/{profile-CCJwsEtq.mjs → profile-B7kK9yO3.mjs} +4 -4
- package/dist/{runAs-C8suolP2.mjs → runAs-B0C3T4Rq.mjs} +1 -1
- package/dist/runAs.vue_vue_type_script_setup_true_lang-D24xjdze.mjs +645 -0
- package/dist/{types-DXRor_zc.mjs → types-CQh1KdEj.mjs} +3 -3
- package/dist/{updatePwd-CgWThOVr.mjs → updatePwd-BZwEBKIy.mjs} +1 -1
- package/dist/{updatePwd.vue_vue_type_script_setup_true_lang-CLY6hMmO.mjs → updatePwd.vue_vue_type_script_setup_true_lang-CcqYxpvS.mjs} +2 -2
- package/dts/src/api/types.d.ts +32 -32
- package/dts/src/hooks/table.d.ts +14 -14
- package/dts/src/lang/package/en.d.ts +2 -0
- package/dts/src/lang/package/zh-cn.d.ts +2 -0
- package/package.json +1 -1
- package/dist/runAs.vue_vue_type_script_setup_true_lang-BZBTd_j_.mjs +0 -610
package/dts/src/api/types.d.ts
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import type { AxiosPromise } from "axios";
|
|
2
|
-
export interface EntityApi {
|
|
3
|
-
getKey(model: EntityModel): EntityKey
|
|
4
|
-
findPage?(query: EntityReq): AxiosPromise<EntityPage
|
|
5
|
-
findList?(query: EntityReq): AxiosPromise<EntityList
|
|
6
|
-
findById(key: EntityKey): AxiosPromise<EntityModel
|
|
7
|
-
create(data: EntityCreateReq): AxiosPromise<EntityModel
|
|
8
|
-
update(data: EntityUpdateReq): AxiosPromise<EntityModel
|
|
9
|
-
delete?(key: EntityKey): AxiosPromise<EntityModel
|
|
10
|
-
batchDelete?(keys: EntityKey[]): AxiosPromise<number>;
|
|
11
|
-
enable?(key: EntityKey
|
|
12
|
-
move?(key: EntityKey
|
|
2
|
+
export interface EntityApi<T> {
|
|
3
|
+
getKey(model: EntityModel<T>): EntityKey<T>;
|
|
4
|
+
findPage?(query: EntityReq<T>): AxiosPromise<EntityPage<T>>;
|
|
5
|
+
findList?(query: EntityReq<T>): AxiosPromise<EntityList<T>>;
|
|
6
|
+
findById(key: EntityKey<T>): AxiosPromise<EntityModel<T>>;
|
|
7
|
+
create(data: EntityCreateReq<T>): AxiosPromise<EntityModel<T>>;
|
|
8
|
+
update(data: EntityUpdateReq<T>): AxiosPromise<EntityModel<T>>;
|
|
9
|
+
delete?(key: EntityKey<T>): AxiosPromise<EntityModel<T>>;
|
|
10
|
+
batchDelete?(keys: EntityKey<T>[]): AxiosPromise<number>;
|
|
11
|
+
enable?(key: EntityKey<T>, enabled: boolean): AxiosPromise<boolean>;
|
|
12
|
+
move?(key: EntityKey<T>, up: boolean): AxiosPromise<boolean>;
|
|
13
13
|
downloadTemplate?(): AxiosPromise;
|
|
14
|
-
exportExcel?(data: EntityExportReq): AxiosPromise;
|
|
15
|
-
exportPdf?(data: EntityExportReq): AxiosPromise;
|
|
16
|
-
importExcel?(data: EntityImportReq): AxiosPromise<string>;
|
|
14
|
+
exportExcel?(data: EntityExportReq<T>): AxiosPromise;
|
|
15
|
+
exportPdf?(data: EntityExportReq<T>): AxiosPromise;
|
|
16
|
+
importExcel?(data: EntityImportReq<T>): AxiosPromise<string>;
|
|
17
17
|
}
|
|
18
18
|
export interface EnumEntryReq {
|
|
19
19
|
className: string;
|
|
@@ -29,54 +29,54 @@ export interface LayEntry {
|
|
|
29
29
|
parentId: string;
|
|
30
30
|
children: LayEntry[];
|
|
31
31
|
}
|
|
32
|
-
export interface EntityExportReq {
|
|
32
|
+
export interface EntityExportReq<T> {
|
|
33
33
|
type: number;
|
|
34
34
|
data: any;
|
|
35
35
|
}
|
|
36
|
-
export interface EntityReq {
|
|
36
|
+
export interface EntityReq<T> {
|
|
37
37
|
curPage?: number;
|
|
38
38
|
pageSize?: number;
|
|
39
39
|
orderName?: string;
|
|
40
40
|
orderAsc?: boolean;
|
|
41
41
|
}
|
|
42
|
-
export interface EntityModel {
|
|
42
|
+
export interface EntityModel<T> {
|
|
43
43
|
}
|
|
44
|
-
export interface EntityList {
|
|
45
|
-
results: Array<EntityModel
|
|
44
|
+
export interface EntityList<T> {
|
|
45
|
+
results: Array<EntityModel<T>>;
|
|
46
46
|
}
|
|
47
|
-
export interface EntityPage {
|
|
48
|
-
results: Array<EntityModel
|
|
47
|
+
export interface EntityPage<T> {
|
|
48
|
+
results: Array<EntityModel<T>>;
|
|
49
49
|
curPage: number;
|
|
50
50
|
pageSize: number;
|
|
51
51
|
totalSize: number;
|
|
52
|
-
subTotalDto: EntityTotal
|
|
53
|
-
totalDto: EntityTotal
|
|
52
|
+
subTotalDto: EntityTotal<T>;
|
|
53
|
+
totalDto: EntityTotal<T>;
|
|
54
54
|
}
|
|
55
|
-
export interface EntityTotal {
|
|
55
|
+
export interface EntityTotal<T> {
|
|
56
56
|
totalSize: number;
|
|
57
57
|
}
|
|
58
|
-
export interface EntityKey {
|
|
58
|
+
export interface EntityKey<T> {
|
|
59
59
|
}
|
|
60
|
-
export interface EntityKeyList {
|
|
60
|
+
export interface EntityKeyList<T> {
|
|
61
61
|
}
|
|
62
|
-
export interface EntityCreateReq {
|
|
62
|
+
export interface EntityCreateReq<T> {
|
|
63
63
|
tenant?: string;
|
|
64
64
|
requestId?: string;
|
|
65
65
|
validateOnly?: boolean;
|
|
66
66
|
}
|
|
67
|
-
export interface EntityUpdateReq {
|
|
67
|
+
export interface EntityUpdateReq<T> {
|
|
68
68
|
tenant?: string;
|
|
69
69
|
requestId?: string;
|
|
70
70
|
validateOnly?: boolean;
|
|
71
71
|
updateMask: string;
|
|
72
72
|
}
|
|
73
|
-
export type EntityFormReq = EntityCreateReq | EntityUpdateReq
|
|
74
|
-
export interface EntityExportReq {
|
|
73
|
+
export type EntityFormReq<T> = EntityCreateReq<T> | EntityUpdateReq<T>;
|
|
74
|
+
export interface EntityExportReq<T> {
|
|
75
75
|
title?: string;
|
|
76
76
|
fileName?: string;
|
|
77
|
-
req?: EntityReq
|
|
77
|
+
req?: EntityReq<T>;
|
|
78
78
|
}
|
|
79
|
-
export interface EntityImportReq {
|
|
79
|
+
export interface EntityImportReq<T> {
|
|
80
80
|
tenant?: string;
|
|
81
81
|
requestId: string;
|
|
82
82
|
fileNames?: string;
|
package/dts/src/hooks/table.d.ts
CHANGED
|
@@ -1,27 +1,27 @@
|
|
|
1
1
|
import type { EntityApi, EntityReq, EntityModel, EntityTotal, EntityImportReq } from "../api/types";
|
|
2
2
|
import type { Ref } from "vue";
|
|
3
3
|
/** use table hooks */
|
|
4
|
-
export declare function useTableHooks(t: any, api: EntityApi
|
|
5
|
-
tableHooks: TableHooks
|
|
4
|
+
export declare function useTableHooks<T>(t: any, api: EntityApi<T>, query: Ref<EntityReq<T>>): {
|
|
5
|
+
tableHooks: TableHooks<T>;
|
|
6
6
|
multipleTableRef: Ref<any>;
|
|
7
7
|
queryFormRef: Ref<any>;
|
|
8
8
|
listLoading: Ref<boolean>;
|
|
9
|
-
tableData: Ref<EntityModel[]>;
|
|
9
|
+
tableData: Ref<EntityModel<T>[]>;
|
|
10
10
|
total: Ref<number>;
|
|
11
11
|
};
|
|
12
12
|
/** 表格Hooks */
|
|
13
|
-
export declare class TableHooks {
|
|
13
|
+
export declare class TableHooks<T> {
|
|
14
14
|
multipleTableRef: Ref<any>;
|
|
15
15
|
queryFormRef: Ref<any>;
|
|
16
16
|
listLoading: Ref<boolean>;
|
|
17
|
-
tableData: Ref<EntityModel[]>;
|
|
17
|
+
tableData: Ref<EntityModel<T>[]>;
|
|
18
18
|
total: Ref<number>;
|
|
19
|
-
totalRecord: Ref<EntityTotal
|
|
20
|
-
selectionRows: Ref<EntityModel[]>;
|
|
21
|
-
queryData: Ref<EntityReq
|
|
22
|
-
api: EntityApi
|
|
19
|
+
totalRecord: Ref<EntityTotal<T>>;
|
|
20
|
+
selectionRows: Ref<EntityModel<T>[]>;
|
|
21
|
+
queryData: Ref<EntityReq<T>>;
|
|
22
|
+
api: EntityApi<T>;
|
|
23
23
|
t: any;
|
|
24
|
-
constructor(t: any, api: EntityApi
|
|
24
|
+
constructor(t: any, api: EntityApi<T>, query: Ref<EntityReq<T>>);
|
|
25
25
|
/** 获取Page列表数据. */
|
|
26
26
|
getList(): void;
|
|
27
27
|
/** 处理查询,如果查询数据中存在当前页数,则重置为第一页. */
|
|
@@ -29,13 +29,13 @@ export declare class TableHooks {
|
|
|
29
29
|
handleSort(prop: string, order: string | null): void;
|
|
30
30
|
resetQuery(): void;
|
|
31
31
|
/** 删除记录 */
|
|
32
|
-
deleteRecord(row: EntityModel): void;
|
|
32
|
+
deleteRecord(row: EntityModel<T>): void;
|
|
33
33
|
/** 删除多项记录 */
|
|
34
34
|
deleteRecords(): void;
|
|
35
|
-
handleMove(row: EntityModel
|
|
36
|
-
enableRecord(row: EntityModel
|
|
35
|
+
handleMove(row: EntityModel<T>, up: boolean): void;
|
|
36
|
+
enableRecord(row: EntityModel<T>, enabled: boolean): void;
|
|
37
37
|
handleExport(name: string): void;
|
|
38
38
|
handleExportPdf(name: string): void;
|
|
39
39
|
downloadTemplate(name: string): void;
|
|
40
|
-
importExcel(val: EntityImportReq): Promise<boolean>;
|
|
40
|
+
importExcel(val: EntityImportReq<T>): Promise<boolean>;
|
|
41
41
|
}
|
|
@@ -187,6 +187,7 @@ declare const _default: {
|
|
|
187
187
|
name: string;
|
|
188
188
|
target: string;
|
|
189
189
|
routeName: string;
|
|
190
|
+
resourceCode: string;
|
|
190
191
|
url: string;
|
|
191
192
|
status: string;
|
|
192
193
|
operatePerm: string;
|
|
@@ -199,6 +200,7 @@ declare const _default: {
|
|
|
199
200
|
parentRequired: string;
|
|
200
201
|
nameRequired: string;
|
|
201
202
|
routeNameRequired: string;
|
|
203
|
+
resourceCodeRequired: string;
|
|
202
204
|
urlRequired: string;
|
|
203
205
|
statusRequired: string;
|
|
204
206
|
targetRequired: string;
|
|
@@ -191,6 +191,7 @@ declare const _default: {
|
|
|
191
191
|
name: string;
|
|
192
192
|
target: string;
|
|
193
193
|
routeName: string;
|
|
194
|
+
resourceCode: string;
|
|
194
195
|
url: string;
|
|
195
196
|
status: string;
|
|
196
197
|
operatePerm: string;
|
|
@@ -203,6 +204,7 @@ declare const _default: {
|
|
|
203
204
|
parentRequired: string;
|
|
204
205
|
nameRequired: string;
|
|
205
206
|
routeNameRequired: string;
|
|
207
|
+
resourceCodeRequired: string;
|
|
206
208
|
urlRequired: string;
|
|
207
209
|
urlExistSlash: string;
|
|
208
210
|
statusRequired: string;
|