@juzhenfe/page-model 3.9.37 → 3.9.39

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.
@@ -10,6 +10,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
10
10
  }, {
11
11
  props: any;
12
12
  tableManager: import("vue").ComputedRef<any>;
13
+ handleClickEditIcon: (column: any, row: any) => void;
13
14
  onUpdateTableCellModelValue: (row: any, prop: string, value: any) => void;
14
15
  onSaveEditContent: (row: AnyObject, cellKey: string, column: PageModel.TableBaseItem<any, any>) => Promise<boolean>;
15
16
  onCellDataChange: (row: AnyObject, cellKey: string, column: PageModel.TableBaseItem<any, any>) => void;
@@ -142,10 +143,8 @@ declare const _sfc_main: import("vue").DefineComponent<{
142
143
  multProps: string[];
143
144
  }, {}>;
144
145
  readonly QuestionFilled: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}, {}>;
145
- readonly Select: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}, {}>;
146
- readonly CloseBold: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}, {}>;
147
146
  readonly Loading: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}, {}>;
148
- readonly EditPen: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}, {}>;
147
+ readonly Edit: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}, {}>;
149
148
  }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
150
149
  els: {
151
150
  type: ArrayConstructor;
@@ -8,8 +8,14 @@ export default class TableManager extends IManager {
8
8
  tableRef: typeof ElTable;
9
9
  loadingData: boolean;
10
10
  tableData: any[];
11
- editableOpen: Map<any, any> & Omit<Map<any, any>, keyof Map<any, any>>;
12
- editableData: Map<any, any>;
11
+ /**
12
+ * 表格编辑开启状态对象
13
+ */
14
+ editableOpen: Map<string, boolean> & Omit<Map<string, boolean>, keyof Map<any, any>>;
15
+ /**
16
+ * 表格保存源数据
17
+ */
18
+ editableData: Map<string, string>;
13
19
  total: number;
14
20
  pagination: PageModel.Pagination;
15
21
  currentPage: number;
@@ -26,12 +32,17 @@ export default class TableManager extends IManager {
26
32
  get table(): PageModel.Table<AnyObject, TableManager>;
27
33
  /**
28
34
  * config配置的rowKey
35
+ * 用户自己配置的rowKey
29
36
  */
30
37
  get setedRowKey(): string;
31
38
  /**
32
39
  * 内置的rowKey
33
40
  */
34
41
  randomRowKey: string;
42
+ /**
43
+ * 使用的rowKey
44
+ * 可能是用户配置的id,也可能是生成的随机串
45
+ */
35
46
  get rowKey(): string;
36
47
  init(): void;
37
48
  updateTableRef(tableRef: typeof ElTable): void;
@@ -70,32 +81,48 @@ export default class TableManager extends IManager {
70
81
  patchTableSortable(): void;
71
82
  /**
72
83
  * 构建单元格的唯一key
73
- * column-列-页数-行
84
+ * 列标记 - 行标记
74
85
  * @param columnKey 列的key
75
- * @param rowIndex 行索引
86
+ * @param rowIndex 行数据 或者 行key
87
+ * @returns
88
+ */
89
+ composeTableCellKey(columnKey: string, rowKey: string): string;
90
+ /**
91
+ * 构建单元格的唯一key
92
+ * 列标记 - 行标记
93
+ * @param columnKey table列
94
+ * @param rowIndex 行数据
76
95
  * @returns
77
96
  */
78
- composeTableCellKey(columnKey: string, rowIndex: string): string;
97
+ composeTableCellKeyByData(column: any, row: any): string;
79
98
  /**
80
99
  * 当前聚焦的单元格
81
100
  */
82
101
  focusCellKey: string;
102
+ /**
103
+ * 当前聚焦的列
104
+ */
105
+ focusEl: PageModel.TableBaseItem;
83
106
  /**
84
107
  * 移除当前单元格聚焦
85
108
  */
86
- blurCell(blurRowData: any, blurColumn: any): void;
109
+ blurCell(): void;
87
110
  /**
88
- * 当前单元格聚焦
111
+ * document点击事件
89
112
  */
90
- focusCell(cell?: HTMLElement): void;
113
+ documentClickHandler: (e: MouseEvent) => void;
91
114
  /**
92
- * 当前的点击行
115
+ * 移除单元格外点击事件
93
116
  */
94
- currentRow: AnyObject;
117
+ removeCellOutClickEvent(): void;
95
118
  /**
96
- * 当前的列
119
+ * 单元格外点击,清理选中
97
120
  */
98
- currentColumn: any;
121
+ bindCellOutClickEvent(): void;
122
+ /**
123
+ * 当前单元格聚焦
124
+ */
125
+ focusCell(cell?: HTMLElement): void;
99
126
  /**
100
127
  * 设置表格可编辑
101
128
  * @returns
@@ -195,4 +222,5 @@ export default class TableManager extends IManager {
195
222
  updateScrollTop(top: any): void;
196
223
  scrollLeft: number;
197
224
  updateScrollLeft(left: any): void;
225
+ destroy(): void;
198
226
  }