vue2-client 1.19.97 → 1.19.99

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vue2-client",
3
- "version": "1.19.97",
3
+ "version": "1.19.99",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "serve": "SET NODE_OPTIONS=--openssl-legacy-provider && vue-cli-service serve --no-eslint",
@@ -1,199 +1,330 @@
1
1
  <script setup>
2
2
  import XFormTable from '@vue2-client/base-client/components/common/XFormTable/XFormTable.vue'
3
- import { ref, computed, useAttrs, nextTick } from 'vue'
3
+ import { ref, computed, useAttrs, nextTick, onMounted, onBeforeUnmount } from 'vue'
4
+
5
+ // 常量配置
6
+ const ROW_HEIGHT_DEFAULT = '37px'
7
+ const BOOLEAN_STYLE_KEYS = [
8
+ 'button-row-0margin',
9
+ 'top-hidden',
10
+ 'dialog-style',
11
+ 'button-style',
12
+ 'header-center',
13
+ 'expanded-grid-white',
14
+ 'report-mode',
15
+ 'listview-hide-selected',
16
+ 'min-height-auto'
17
+ ]
18
+ const ALLOWED_PAGINATION_STYLES = ['pagination-center', 'custom-pagination']
19
+ const SYNC_DELAY_AFTER_PAGE = 80
20
+ const SYNC_DELAY_RETRY = 60
21
+ const SYNC_DELAY_EXPAND = 20
22
+
23
+ // 选择器常量
24
+ const MAIN_TABLE_SELECTORS = [
25
+ '.ant-table-tbody > tr.ant-table-row',
26
+ '.ant-table-body > table > tbody > tr.ant-table-row'
27
+ ]
28
+ const FIXED_TABLE_SELECTORS = [
29
+ '.ant-table-fixed-right .ant-table-tbody > tr',
30
+ '.ant-table-fixed-right .ant-table-body-inner > table > tbody > tr',
31
+ '.ant-table-fixed-right .ant-table-body > table > tbody > tr'
32
+ ]
33
+ const MAIN_TBODY_SELECTORS = ['.ant-table-body > table > tbody', '.ant-table-tbody']
34
+ const FIXED_TBODY_SELECTORS = [
35
+ '.ant-table-fixed-right .ant-table-body-inner > table > tbody',
36
+ '.ant-table-fixed-right .ant-table-body > table > tbody',
37
+ '.ant-table-fixed-right .ant-table-tbody'
38
+ ]
39
+ const TABLE_BODY_SELECTORS = ['.ant-table-body', '.ant-table-body-inner']
40
+
41
+ // 辅助函数
42
+ const getRowKey = (tr) => tr?.getAttribute?.('data-row-key') || tr?.dataset?.rowKey || ''
43
+
44
+ const cleanRowStyles = (element, isCollapse = false) => {
45
+ if (!element) return
46
+ element.removeAttribute('data-synced-height')
47
+ if (isCollapse) {
48
+ element.style.setProperty('height', '0', 'important')
49
+ element.style.setProperty('min-height', '0', 'important')
50
+ element.style.setProperty('max-height', '0', 'important')
51
+ element.style.setProperty('line-height', '0', 'important')
52
+ element.style.setProperty('overflow', 'hidden', 'important')
53
+ } else {
54
+ element.style.removeProperty('height')
55
+ element.style.removeProperty('min-height')
56
+ element.style.removeProperty('max-height')
57
+ element.style.removeProperty('line-height')
58
+ }
59
+ }
60
+
61
+ const cleanCellStyles = (td, isCollapse = false) => {
62
+ if (isCollapse) {
63
+ td.style.setProperty('height', '0', 'important')
64
+ td.style.setProperty('min-height', '0', 'important')
65
+ td.style.setProperty('max-height', '0', 'important')
66
+ td.style.setProperty('line-height', '0', 'important')
67
+ td.style.setProperty('padding', '0', 'important')
68
+ td.style.setProperty('border', 'none', 'important')
69
+ td.style.setProperty('overflow', 'hidden', 'important')
70
+ } else {
71
+ td.style.removeProperty('height')
72
+ td.style.removeProperty('min-height')
73
+ td.style.removeProperty('max-height')
74
+ td.style.removeProperty('line-height')
75
+ td.style.removeProperty('vertical-align')
76
+ }
77
+ }
78
+
79
+ const queryFirst = (container, selectors) => {
80
+ for (const sel of selectors) {
81
+ const el = container.querySelector(sel)
82
+ if (el) return el
83
+ }
84
+ return null
85
+ }
4
86
 
5
87
  const props = defineProps({
6
- // HFormTable特有的属性
7
88
  tableStyle: {
8
89
  type: String,
9
90
  default: 'formtable-col1'
10
91
  }
11
92
  })
12
93
 
13
- // 兼容多种样式配置
14
94
  const attrs = useAttrs()
95
+
15
96
  const wrapperClassObject = computed(() => {
16
- const a = attrs
17
97
  const classes = {}
18
98
 
19
- // 通用布尔样式开关(以存在/空字符串/'true' 为真)
20
- const booleanStyleKeys = [
21
- 'button-row-0margin',
22
- 'top-hidden',
23
- 'dialog-style',
24
- 'button-style',
25
- 'header-center',
26
- 'expanded-grid-white',
27
- 'report-mode',
28
- // listView模式下隐藏“已选择”按钮
29
- 'listview-hide-selected',
30
- 'min-height-auto'
31
- ]
32
- for (const key of booleanStyleKeys) {
33
- const val = a[key]
99
+ for (const key of BOOLEAN_STYLE_KEYS) {
100
+ const val = attrs[key]
34
101
  const truthy = val === true || val === '' || val === 'true'
35
102
  if (truthy) classes[`h-form-table-${key}`] = true
36
103
  }
37
104
 
38
- // 兼容通过 attrs 透传的分页样式:将值映射为当前样式中存在的类名
39
- const paginationAttr = a && a.paginationStyle
40
- if (paginationAttr && ['pagination-center', 'custom-pagination'].includes(paginationAttr)) {
105
+ const paginationAttr = attrs?.paginationStyle
106
+ if (paginationAttr && ALLOWED_PAGINATION_STYLES.includes(paginationAttr)) {
41
107
  classes[`h-form-table-${paginationAttr}`] = true
42
108
  }
43
109
  return classes
44
110
  })
45
111
 
46
- // 通过暴露的实例访问 $slots,避免直接依赖 Composition API 的 useSlots
47
- // 在模板中使用 `$slots` 遍历以保持与 Vue2 兼容
48
- // 创建对XFormTable组件的引用
112
+ const wrapperStyleObject = computed(() => {
113
+ const rowHeight = attrs['row-height'] || attrs.rowHeight || ROW_HEIGHT_DEFAULT
114
+ return { '--row-height': rowHeight }
115
+ })
116
+
49
117
  const xFormTableRef = ref()
118
+ const wrapperRef = ref()
50
119
 
51
- // 使用 MutationObserver 监听展开行高度变化,实时同步固定列
120
+ // 状态变量
52
121
  let observer = null
122
+ let resizeObserver = null
123
+ let isSyncing = false
124
+ let rafId = 0
125
+ let syncAfterPageChangeTimer = 0
126
+
127
+ const getWrapperEl = () => wrapperRef.value
128
+
129
+ const scheduleSync = () => {
130
+ if (isSyncing) return
131
+ if (rafId) cancelAnimationFrame(rafId)
132
+ rafId = requestAnimationFrame(() => {
133
+ rafId = 0
134
+ syncFixedExpandedHeights()
135
+ })
136
+ }
137
+
138
+ const clearAllFixedRowHeights = () => {
139
+ try {
140
+ const wrapper = getWrapperEl()
141
+ if (!wrapper) return
142
+ const fixedRows = wrapper.querySelectorAll(FIXED_TABLE_SELECTORS.join(', '))
143
+ fixedRows.forEach(f => {
144
+ if (!f) return
145
+ cleanRowStyles(f, true)
146
+ f.querySelectorAll('td').forEach(td => cleanCellStyles(td, true))
147
+ })
148
+ } catch (e) {
149
+ console.warn('[HFormTable] clearAllFixedRowHeights error:', e)
150
+ }
151
+ }
152
+
153
+ const scheduleSyncAfterPageChange = () => {
154
+ clearAllFixedRowHeights()
155
+ if (syncAfterPageChangeTimer) clearTimeout(syncAfterPageChangeTimer)
156
+ syncAfterPageChangeTimer = setTimeout(() => {
157
+ syncAfterPageChangeTimer = 0
158
+ scheduleSync()
159
+ setTimeout(scheduleSync, SYNC_DELAY_RETRY)
160
+ }, SYNC_DELAY_AFTER_PAGE)
161
+ }
162
+
53
163
  const setupHeightSync = () => {
54
164
  try {
55
- const wrapper = document.querySelector('.h-form-table-wrapper')
165
+ const wrapper = getWrapperEl()
56
166
  if (!wrapper || observer) return
57
167
 
168
+ const mainTable = queryFirst(wrapper, MAIN_TBODY_SELECTORS)
169
+ const fixedTbody = queryFirst(wrapper, FIXED_TBODY_SELECTORS)
170
+ const tableBody = queryFirst(wrapper, TABLE_BODY_SELECTORS)
171
+
172
+ const observerOptions = {
173
+ childList: true,
174
+ subtree: true,
175
+ attributes: true,
176
+ attributeFilter: ['style', 'class']
177
+ }
178
+
58
179
  observer = new MutationObserver((mutations) => {
59
- // 只在展开行相关变化时同步,避免不必要的计算
60
- const hasRelevantChange = mutations.some(mutation =>
61
- mutation.type === 'attributes' &&
62
- (mutation.attributeName === 'style' || mutation.attributeName === 'class') ||
63
- mutation.type === 'childList'
180
+ if (isSyncing) return
181
+ const hasChildList = mutations.some(m => m.type === 'childList')
182
+ const hasAttr = mutations.some(m =>
183
+ m.type === 'attributes' &&
184
+ (m.attributeName === 'style' || m.attributeName === 'class')
64
185
  )
65
- if (hasRelevantChange) {
66
- syncFixedExpandedHeights()
186
+ if (hasChildList) {
187
+ scheduleSyncAfterPageChange()
188
+ } else if (hasAttr) {
189
+ scheduleSync()
67
190
  }
68
191
  })
69
192
 
70
- // 监听主表展开行的属性变化
71
- const mainTable = wrapper.querySelector('.ant-table-body > table > tbody')
72
- if (mainTable) {
73
- observer.observe(mainTable, {
74
- childList: true,
75
- subtree: true,
76
- attributes: true,
77
- attributeFilter: ['style', 'class']
78
- })
193
+ if (mainTable) observer.observe(mainTable, observerOptions)
194
+ if (fixedTbody) observer.observe(fixedTbody, observerOptions)
195
+
196
+ if (!resizeObserver && tableBody && typeof ResizeObserver !== 'undefined') {
197
+ resizeObserver = new ResizeObserver(() => scheduleSync())
198
+ resizeObserver.observe(tableBody)
79
199
  }
80
200
  } catch (e) {
81
201
  console.warn('[HFormTable] setupHeightSync error:', e)
82
202
  }
83
203
  }
84
204
 
85
- // 同步固定列中的"展开行"高度到主表展开行高度,避免错位
86
205
  const syncFixedExpandedHeights = () => {
87
206
  try {
88
- const wrapper = document.querySelector('.h-form-table-wrapper')
207
+ const wrapper = getWrapperEl()
89
208
  if (!wrapper) return
90
- const mainRows = Array.from(wrapper.querySelectorAll('.ant-table-body > table > tbody > tr'))
91
- const fixedRows = Array.from(wrapper.querySelectorAll('.ant-table-fixed-right .ant-table-body-inner > table > tbody > tr'))
92
- const len = Math.min(mainRows.length, fixedRows.length)
93
-
94
- for (let i = 0; i < len; i++) {
95
- const m = mainRows[i]
96
- const f = fixedRows[i]
97
- if (!f) continue
98
-
99
- if (m.classList.contains('ant-table-expanded-row')) {
100
- const h = m.clientHeight
101
- // 缓存高度,避免重复设置
102
- if (f.dataset.syncedHeight === h.toString()) continue
103
- f.dataset.syncedHeight = h.toString()
104
-
105
- // 强制同步高度,使用 !important 覆盖其他样式
106
- f.style.setProperty('height', h + 'px', 'important')
107
- f.style.setProperty('min-height', h + 'px', 'important')
108
- f.style.setProperty('max-height', h + 'px', 'important')
109
-
110
- // 同步单元格高度,确保完全一致
111
- const tds = f.querySelectorAll('td')
112
- tds.forEach(td => {
113
- td.style.setProperty('height', h + 'px', 'important')
114
- td.style.setProperty('min-height', h + 'px', 'important')
115
- td.style.setProperty('max-height', h + 'px', 'important')
116
- td.style.setProperty('padding', '0', 'important')
117
- td.style.setProperty('border', 'none', 'important')
118
- })
119
- } else {
120
- // 清理非展开行的内联样式和缓存
121
- if (f.dataset.syncedHeight) {
122
- f.removeAttribute('data-synced-height')
123
- f.style.removeProperty('height')
124
- f.style.removeProperty('min-height')
125
- f.style.removeProperty('max-height')
126
- const tds = f.querySelectorAll('td')
127
- tds.forEach(td => {
128
- td.style.removeProperty('height')
129
- td.style.removeProperty('min-height')
130
- td.style.removeProperty('max-height')
131
- td.style.removeProperty('padding')
132
- td.style.removeProperty('border')
133
- })
134
- }
135
- }
209
+ if (isSyncing) return
210
+ isSyncing = true
211
+
212
+ const mainRows = Array.from(wrapper.querySelectorAll(MAIN_TABLE_SELECTORS.join(', ')))
213
+ const fixedRows = Array.from(wrapper.querySelectorAll(FIXED_TABLE_SELECTORS.join(', ')))
214
+
215
+ // 只取有 key 的行进行顺序匹配
216
+ const mainRowsList = mainRows.filter(m => getRowKey(m))
217
+ const fixedRowsList = fixedRows.filter(f => getRowKey(f))
218
+ const count = Math.min(mainRowsList.length, fixedRowsList.length)
219
+
220
+ for (let i = 0; i < count; i++) {
221
+ const m = mainRowsList[i]
222
+ const f = fixedRowsList[i]
223
+ const key = getRowKey(m)
224
+ if (!key) continue
225
+
226
+ const h = Math.round(m.getBoundingClientRect().height)
227
+ if (!h) continue
228
+
229
+ const hs = String(h)
230
+ if (f.dataset.syncedHeight === hs) continue
231
+ f.dataset.syncedHeight = hs
232
+
233
+ f.style.cssText = ''
234
+ f.style.setProperty('height', h + 'px', 'important')
235
+ f.style.setProperty('min-height', h + 'px', 'important')
236
+ f.style.setProperty('max-height', h + 'px', 'important')
237
+ f.style.setProperty('line-height', 'normal', 'important')
238
+
239
+ f.querySelectorAll('td').forEach(td => {
240
+ td.style.cssText = ''
241
+ td.style.setProperty('height', h + 'px', 'important')
242
+ td.style.setProperty('min-height', h + 'px', 'important')
243
+ td.style.setProperty('max-height', h + 'px', 'important')
244
+ td.style.setProperty('line-height', 'normal', 'important')
245
+ td.style.setProperty('vertical-align', 'middle', 'important')
246
+ })
136
247
  }
248
+
249
+ // 清理无对应主表 key 的固定列行
250
+ const mainKeys = new Set(mainRowsList.map(m => getRowKey(m)))
251
+ fixedRows.forEach(f => {
252
+ const key = getRowKey(f)
253
+ if (!mainKeys.has(key) && f.dataset.syncedHeight) {
254
+ cleanRowStyles(f, true)
255
+ f.querySelectorAll('td').forEach(td => cleanCellStyles(td, true))
256
+ }
257
+ })
137
258
  } catch (e) {
138
259
  console.warn('[HFormTable] syncFixedExpandedHeights error:', e)
260
+ } finally {
261
+ isSyncing = false
139
262
  }
140
263
  }
141
264
 
142
- const onExpandLog = (expanded, record) => {
143
- // 等DOM完成再测量
265
+ const onExpandLog = () => {
144
266
  nextTick(() => {
145
- // 设置实时监听(如果还没设置)
146
267
  if (!observer) {
147
268
  setupHeightSync()
148
269
  }
149
-
150
- // 立即同步一次(避免第一次展开时错位)
151
270
  syncFixedExpandedHeights()
152
-
153
- // 短延迟再同步一次(应对异步渲染)
154
- setTimeout(() => {
155
- syncFixedExpandedHeights()
156
- }, 20)
271
+ setTimeout(() => syncFixedExpandedHeights(), SYNC_DELAY_EXPAND)
157
272
  })
158
273
  }
159
274
 
160
- // 暴露方法给父组件使用
161
- defineExpose({
162
- // 为了兼容性,保留getXFormTableInstance方法
163
- getXFormTableInstance: () => xFormTableRef.value,
164
- /** 等待配置结束的异步方法,委托给内部 XFormTable */
165
- waitConfigEnd: () => xFormTableRef.value?.waitConfigEnd?.() ?? Promise.resolve()
275
+ onMounted(() => {
276
+ nextTick(() => {
277
+ setupHeightSync()
278
+ syncFixedExpandedHeights()
279
+ })
280
+ })
281
+
282
+ onBeforeUnmount(() => {
283
+ try {
284
+ observer?.disconnect?.()
285
+ resizeObserver?.disconnect?.()
286
+ if (rafId) cancelAnimationFrame(rafId)
287
+ if (syncAfterPageChangeTimer) clearTimeout(syncAfterPageChangeTimer)
288
+ } finally {
289
+ observer = null
290
+ resizeObserver = null
291
+ rafId = 0
292
+ syncAfterPageChangeTimer = 0
293
+ isSyncing = false
294
+ }
166
295
  })
167
296
 
168
- // 计算是否使用自定义分页(兼容 attrs 透传与 tableStyle 配置)
297
+ // 计算属性
169
298
  const isCustomPagination = computed(() => {
170
- const a = attrs
171
- const paginationAttr = (a && a.paginationStyle) || ''
299
+ const paginationAttr = attrs?.paginationStyle || ''
172
300
  return props.tableStyle === 'custom-pagination' || paginationAttr === 'custom-pagination'
173
301
  })
174
- // 是否隐藏顶部功能区
302
+
175
303
  const isHiddenFunctionalArea = computed(() => {
176
- return attrs.hiddenFunctionalArea === 'true' || attrs.hiddenFunctionalArea === true
304
+ return attrs?.hiddenFunctionalArea === 'true' || attrs?.hiddenFunctionalArea === true
177
305
  })
178
306
 
179
- // 从 attrs 中获取 pageMaxSize,如果存在则作为 defaultPageSize
180
307
  const computedDefaultPageSize = computed(() => {
181
- const pageMaxSize = attrs.pageMaxSize
182
- // 将字符串转换为数字,如果无效则使用默认值
308
+ const pageMaxSize = attrs?.pageMaxSize
183
309
  const numericPageSize = pageMaxSize ? Number(pageMaxSize) : null
184
- const defaultSize = (numericPageSize && numericPageSize > 0) ? numericPageSize : 10
310
+ return (numericPageSize && numericPageSize > 0) ? numericPageSize : 10
311
+ })
185
312
 
186
- return defaultSize
313
+ defineExpose({
314
+ getXFormTableInstance: () => xFormTableRef.value,
315
+ waitConfigEnd: () => xFormTableRef.value?.waitConfigEnd?.() ?? Promise.resolve()
187
316
  })
188
317
  </script>
189
318
 
190
319
  <template>
191
320
  <div
321
+ ref="wrapperRef"
192
322
  class="h-form-table-wrapper"
193
323
  :class="[
194
324
  `h-form-table-${tableStyle}`,
195
325
  wrapperClassObject
196
326
  ]"
327
+ :style="wrapperStyleObject"
197
328
  >
198
329
  <x-form-table
199
330
  ref="xFormTableRef"
@@ -213,25 +344,48 @@ const computedDefaultPageSize = computed(() => {
213
344
  </template>
214
345
 
215
346
  <style scoped lang="less">
347
+ // 表格行高度变量,默认37px
348
+ @row-height: var(--row-height, 37px);
349
+
216
350
  .h-form-table-wrapper {
217
351
  // 基础样式
218
352
  :deep(.table-wrapper) {
219
353
  .ant-table {
220
354
  .ant-table-row {
221
- margin: 0px;
222
-
223
- .ant-form-item {
224
- margin: 0px;
225
-
226
- .ant-form-item-control-wrapper {
227
- .ant-form-item-control {
228
- line-height: 0px;
229
-
230
- .ant-select-selection--multiple {
231
- padding-bottom: 2px;
232
- }
233
- }
234
- width: 100%;
355
+ margin: 0 !important;
356
+ height: @row-height !important;
357
+ max-height: @row-height !important;
358
+ line-height: @row-height !important;
359
+
360
+ > td {
361
+ height: @row-height !important;
362
+ min-height: @row-height !important;
363
+ max-height: @row-height !important;
364
+ padding: 0 8px !important;
365
+ box-sizing: border-box !important;
366
+ vertical-align: middle !important;
367
+
368
+ // 去掉内部元素的 margin,防止带下拉框的行被撑高
369
+ .ant-form-item,
370
+ .ant-form-item-control {
371
+ margin-bottom: 0 !important;
372
+ margin-top: 0 !important;
373
+ }
374
+ .ant-select,
375
+ .ant-input,
376
+ .ant-picker {
377
+ margin-bottom: 0 !important;
378
+ margin-top: 0 !important;
379
+ height: @row-height !important;
380
+ max-height: @row-height !important;
381
+ line-height: @row-height !important;
382
+ }
383
+ .ant-select-selection--single {
384
+ height: calc(@row-height - 2px) !important;
385
+ min-height: calc(@row-height - 2px) !important;
386
+ }
387
+ .ant-select-selection__rendered {
388
+ line-height: calc(@row-height - 2px) !important;
235
389
  }
236
390
  }
237
391
  }
@@ -275,6 +429,36 @@ const computedDefaultPageSize = computed(() => {
275
429
  }
276
430
  }
277
431
 
432
+ // 操作列(固定列)高度与主体一致,行内文字垂直居中
433
+ :deep(.ant-table-fixed-right .ant-table-body-inner) {
434
+ table tbody tr.ant-table-row {
435
+ height: @row-height !important;
436
+ max-height: @row-height !important;
437
+
438
+ > td {
439
+ height: @row-height !important;
440
+ min-height: @row-height !important;
441
+ max-height: @row-height !important;
442
+ padding: 0 8px !important;
443
+ box-sizing: border-box !important;
444
+ vertical-align: middle !important;
445
+ line-height: @row-height !important;
446
+ }
447
+ }
448
+ }
449
+ // 主表行高与固定列一致
450
+ :deep(.table-wrapper .ant-table-body > table > tbody > tr.ant-table-row) {
451
+ height: @row-height !important;
452
+ max-height: @row-height !important;
453
+ }
454
+
455
+ :deep(.ant-table-fixed-right .ant-btn),
456
+ :deep(.ant-table-fixed-right a) {
457
+ line-height: inherit !important;
458
+ vertical-align: middle !important;
459
+ padding: 0 4px;
460
+ }
461
+
278
462
  // 表格高度样式
279
463
  &.h-form-table-height {
280
464
  :deep(.table-wrapper) {
@@ -461,7 +645,7 @@ const computedDefaultPageSize = computed(() => {
461
645
  background-color: white;
462
646
  }
463
647
  }
464
- // listView模式下隐藏“已选择”按钮(该按钮包含 monitor 图标)
648
+ // listView模式下隐藏"已选择"按钮(该按钮包含 monitor 图标)
465
649
  &.h-form-table-listview-hide-selected {
466
650
  :deep(.ant-badge:has(.ant-btn .anticon-monitor)) {
467
651
  display: none !important;
@@ -845,7 +845,7 @@ export default {
845
845
  if (this.attr.dataChangeFunc) {
846
846
  this.debouncedDataChangeFunc = debounce(this.dataChangeFunc, 200)
847
847
  // 执行一次
848
- this.dataChangeFunc()
848
+ this.dataChangeFunc(true)
849
849
  }
850
850
  if (this.attr.showFormItemFunc) {
851
851
  this.debouncedShowFormItemFunc = debounce(this.showFormItemFunc, 100)
@@ -1092,7 +1092,8 @@ export default {
1092
1092
  },
1093
1093
 
1094
1094
  // Select组件change处理
1095
- handleSelectChange() {
1095
+ handleSelectChange(a,b,c) {
1096
+ console.warn(a,b,c)
1096
1097
  this.handleFormItemChange()
1097
1098
  },
1098
1099
 
@@ -1246,7 +1247,8 @@ export default {
1246
1247
  this.getDataCallback(option)
1247
1248
  }
1248
1249
  },
1249
- async dataChangeFunc() {
1250
+ // f 是否是初始化执行的
1251
+ async dataChangeFunc(f = false) {
1250
1252
  if (this.attr.dataChangeFunc) {
1251
1253
  await executeStrFunctionByContext(this, this.attr.dataChangeFunc, [
1252
1254
  this.form,
@@ -1255,7 +1257,8 @@ export default {
1255
1257
  util,
1256
1258
  this.mode,
1257
1259
  runLogic,
1258
- getConfigByNameAsync
1260
+ getConfigByNameAsync,
1261
+ f
1259
1262
  ])
1260
1263
  }
1261
1264
  },