@juzhenfe/page-model 3.12.4 → 3.13.0
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/components/filter-tools/constructor.d.ts +1 -1
- package/dist/components/filter-tools/index.vue.d.ts +1 -1
- package/dist/components/{table/components/simple-popover → simple-popover}/index.vue.d.ts +20 -3
- package/dist/components/table/components/table-column/components/filter-zone/utils/index.d.ts +40 -0
- package/dist/components/table/constructor.d.ts +17 -4
- package/dist/components/table/type.d.ts +55 -8
- package/dist/index.es.js +953 -451
- package/dist/index.min.css +1 -1
- package/dist/index.umd.js +3 -3
- package/dist/types/common.d.ts +65 -20
- package/package.json +1 -1
- package/dist/components/table/components/table-column/index.vue.d.ts +0 -158
|
@@ -1,12 +1,19 @@
|
|
|
1
|
-
declare const _sfc_main: import("vue").DefineComponent<{
|
|
1
|
+
declare const _sfc_main: import("vue").DefineComponent<{
|
|
2
|
+
width: {
|
|
3
|
+
type: NumberConstructor;
|
|
4
|
+
required: false;
|
|
5
|
+
default: number;
|
|
6
|
+
};
|
|
7
|
+
}, {
|
|
2
8
|
BEMSpace: string;
|
|
9
|
+
props: any;
|
|
10
|
+
nextZIndex: () => number;
|
|
3
11
|
visible: import("vue").Ref<boolean>;
|
|
4
12
|
isRender: import("vue").Ref<boolean>;
|
|
5
13
|
currentTriggerElement: HTMLElement;
|
|
6
14
|
popoverRectInfo: import("vue").Ref<any>;
|
|
7
15
|
getPopoverTriggerElementRectInfo: (element: HTMLElement) => void;
|
|
8
16
|
popoverRef: import("vue").Ref<HTMLElement>;
|
|
9
|
-
POPOVER_WIDTH: number;
|
|
10
17
|
popoverStyle: import("vue").ComputedRef<{
|
|
11
18
|
top?: undefined;
|
|
12
19
|
left?: undefined;
|
|
@@ -17,9 +24,19 @@ declare const _sfc_main: import("vue").DefineComponent<{}, {
|
|
|
17
24
|
width: string;
|
|
18
25
|
}>;
|
|
19
26
|
isChildElement: (rootElement: HTMLElement, childElement: HTMLElement) => boolean;
|
|
27
|
+
isPopperChildElement: (element: HTMLElement) => boolean;
|
|
20
28
|
handleHide: (e: Event) => void;
|
|
21
29
|
handleResize: (...rest: any[]) => void;
|
|
22
30
|
hide: () => void;
|
|
31
|
+
zIndex: import("vue").Ref<number>;
|
|
23
32
|
show: (element: HTMLElement) => void;
|
|
24
|
-
},
|
|
33
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
34
|
+
width: {
|
|
35
|
+
type: NumberConstructor;
|
|
36
|
+
required: false;
|
|
37
|
+
default: number;
|
|
38
|
+
};
|
|
39
|
+
}>>, {
|
|
40
|
+
width: number;
|
|
41
|
+
}, {}>;
|
|
25
42
|
export default _sfc_main;
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 筛选工具
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* 过滤的类型
|
|
6
|
+
*/
|
|
7
|
+
export declare enum FilterItemTypeEnum {
|
|
8
|
+
文字 = "string",
|
|
9
|
+
数字 = "number",
|
|
10
|
+
日期 = "date",
|
|
11
|
+
布尔值 = "boolean",
|
|
12
|
+
多选值 = "list",
|
|
13
|
+
单选值 = "select"
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* 比较模式
|
|
17
|
+
*/
|
|
18
|
+
export declare enum FilterMatchModeEnum {
|
|
19
|
+
包含 = "match",
|
|
20
|
+
等于 = "eq",
|
|
21
|
+
不等于 = "neq",
|
|
22
|
+
大于 = "gt",
|
|
23
|
+
小于 = "lt",
|
|
24
|
+
大于等于 = "ge",
|
|
25
|
+
小于等于 = "le"
|
|
26
|
+
}
|
|
27
|
+
export declare const compareOptions: {
|
|
28
|
+
string: {
|
|
29
|
+
label: string;
|
|
30
|
+
value: FilterMatchModeEnum;
|
|
31
|
+
}[];
|
|
32
|
+
number: {
|
|
33
|
+
label: string;
|
|
34
|
+
value: FilterMatchModeEnum;
|
|
35
|
+
}[];
|
|
36
|
+
date: {
|
|
37
|
+
label: string;
|
|
38
|
+
value: FilterMatchModeEnum;
|
|
39
|
+
}[];
|
|
40
|
+
};
|
|
@@ -47,10 +47,23 @@ export default class TableManager extends IManager {
|
|
|
47
47
|
init(): void;
|
|
48
48
|
updateTableRef(tableRef: typeof ElTable): void;
|
|
49
49
|
updateLoading(loading: boolean): void;
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
50
|
+
/**
|
|
51
|
+
* 获取表格的搜索参数
|
|
52
|
+
* @returns
|
|
53
|
+
*/
|
|
54
|
+
getReqParams(): any;
|
|
55
|
+
/**
|
|
56
|
+
* 列参数
|
|
57
|
+
*/
|
|
58
|
+
columnParamsList: PageModel.TableColumnParamsItem[];
|
|
59
|
+
/**
|
|
60
|
+
* key是否配置参数
|
|
61
|
+
*/
|
|
62
|
+
get columnParamsKey(): {};
|
|
63
|
+
/**
|
|
64
|
+
* 获取每列的参数
|
|
65
|
+
*/
|
|
66
|
+
getColumnParams(): any;
|
|
54
67
|
refreshPage(): void;
|
|
55
68
|
onConfigUpdated(): void;
|
|
56
69
|
updateByConfig(): void;
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
import { PaginationProps } from "element-plus";
|
|
4
4
|
import { Sort } from "element-plus/es/components/table/src/table/defaults";
|
|
5
5
|
import TableManagerDefault from './constructor'
|
|
6
|
-
import { Component
|
|
6
|
+
import { Component } from "vue";
|
|
7
|
+
import { type FilterItemTypeEnum, type FilterMatchModeEnum} from "./components/table-column/components/filter-zone/utils";
|
|
7
8
|
|
|
8
9
|
declare global {
|
|
9
10
|
namespace PageModel {
|
|
@@ -19,6 +20,36 @@ declare global {
|
|
|
19
20
|
filename: string;
|
|
20
21
|
}
|
|
21
22
|
|
|
23
|
+
/**
|
|
24
|
+
* 列筛选条件
|
|
25
|
+
*/
|
|
26
|
+
type TableColumnParamsItem = {
|
|
27
|
+
/**
|
|
28
|
+
* 列的属性
|
|
29
|
+
*/
|
|
30
|
+
prop: string;
|
|
31
|
+
/**
|
|
32
|
+
* 过滤类型
|
|
33
|
+
*/
|
|
34
|
+
filterType?: FilterItemTypeEnum;
|
|
35
|
+
/**
|
|
36
|
+
* 筛选条件文本
|
|
37
|
+
*/
|
|
38
|
+
filterLabel?: string;
|
|
39
|
+
/**
|
|
40
|
+
* 筛选项
|
|
41
|
+
*/
|
|
42
|
+
filterOptions?: Array<{ label: string; value: string | boolean | number }>;
|
|
43
|
+
/**
|
|
44
|
+
* 当前条件
|
|
45
|
+
*/
|
|
46
|
+
condition?: FilterMatchModeEnum;
|
|
47
|
+
/**
|
|
48
|
+
* 输入的值
|
|
49
|
+
*/
|
|
50
|
+
value?: any;
|
|
51
|
+
}
|
|
52
|
+
|
|
22
53
|
type TableProps = {
|
|
23
54
|
size?: Size;
|
|
24
55
|
border?: boolean;
|
|
@@ -104,17 +135,25 @@ declare global {
|
|
|
104
135
|
* 显示多选条数提示
|
|
105
136
|
*/
|
|
106
137
|
showSelectableTip?: boolean;
|
|
107
|
-
|
|
138
|
+
/**
|
|
139
|
+
* 是否多选
|
|
140
|
+
*/
|
|
108
141
|
selectable?: boolean;
|
|
109
|
-
|
|
142
|
+
/**
|
|
143
|
+
* 点击行自动选中
|
|
144
|
+
*/
|
|
110
145
|
rowClickSelect?: boolean;
|
|
111
|
-
|
|
146
|
+
/**
|
|
147
|
+
* 多选的操作按钮
|
|
148
|
+
*/
|
|
112
149
|
selectableButtons?: Button<MODEL, CTX>[];
|
|
113
|
-
|
|
150
|
+
/**
|
|
151
|
+
* 多选操作独自存活
|
|
152
|
+
*/
|
|
114
153
|
selectableButtonLiveAlone?: boolean;
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
154
|
+
/**
|
|
155
|
+
* 开启单选
|
|
156
|
+
*/
|
|
118
157
|
showRadio?: boolean;
|
|
119
158
|
// 是否可编辑
|
|
120
159
|
editable?: boolean;
|
|
@@ -164,6 +203,14 @@ declare global {
|
|
|
164
203
|
text?: string;
|
|
165
204
|
event: string;
|
|
166
205
|
}[]
|
|
206
|
+
/**
|
|
207
|
+
* 列筛选参数处理函数
|
|
208
|
+
*/
|
|
209
|
+
columnParamsProcessFn?: (this: TableManager, paramsList: PageModel.TableColumnParamsItem[]) => void
|
|
210
|
+
/**
|
|
211
|
+
* 列筛选参数查询立即执行
|
|
212
|
+
*/
|
|
213
|
+
columnParamsQueryImmediate?: boolean;
|
|
167
214
|
}
|
|
168
215
|
}
|
|
169
216
|
}
|