imatrix-ui 2.9.13-dw → 2.9.14-boe2

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.
Files changed (186) hide show
  1. package/lib/super-ui.css +1 -1
  2. package/lib/super-ui.umd.min.js +5 -35
  3. package/package.json +2 -2
  4. package/src/api/sso-service.js +19 -1
  5. package/src/assets/nonemessage.png +0 -0
  6. package/src/i18n/i18n.js +1 -1
  7. package/src/i18n/langs/cn.js +18 -6
  8. package/src/i18n/langs/en.js +20 -7
  9. package/src/permission.js +2 -2
  10. package/src/plugins.js +3 -3
  11. package/src/router/index.js +10 -0
  12. package/src/store/modules/tab-content.js +6 -0
  13. package/src/store/modules/user.js +32 -2
  14. package/src/styles/index.scss +74 -4
  15. package/src/styles/theme/black/font-style.scss +70 -0
  16. package/src/styles/theme/black/index.scss +6 -30
  17. package/src/styles/theme/blue/font-style.scss +37 -0
  18. package/src/styles/theme/blue/index.scss +2 -18
  19. package/src/styles/theme/blue2/font-style.scss +70 -0
  20. package/src/styles/theme/blue2/index.scss +3 -13
  21. package/src/styles/theme/dark-blue/card.scss +4 -6
  22. package/src/styles/theme/dark-blue/index.scss +28 -3
  23. package/src/styles/theme/dark-blue/message.scss +8 -0
  24. package/src/styles/theme/dark-blue/radio.scss +13 -0
  25. package/src/styles/theme/dark-blue/sidebar.scss +7 -37
  26. package/src/styles/theme/dark-blue/table.scss +1 -1
  27. package/src/styles/theme/dark-blue/tree.scss +35 -10
  28. package/src/styles/theme/gray/card-style.scss +13 -1
  29. package/src/styles/theme/gray/font-style.scss +38 -0
  30. package/src/styles/theme/gray/index.scss +13 -25
  31. package/src/styles/theme/gray/scrollbar-style.scss +32 -0
  32. package/src/styles/theme/gray/sidebar.scss +7 -14
  33. package/src/utils/auth-api.js +45 -1
  34. package/src/utils/common-util.js +21 -81
  35. package/src/utils/jump-page-utils.js +1 -2
  36. package/src/utils/range-selector.js +185 -0
  37. package/src/utils/request.js +6 -3
  38. package/src/utils/util.js +13 -11
  39. package/src/views/dsc-component/Sidebar/Item.vue +7 -5
  40. package/src/views/dsc-component/Sidebar/SidebarItem.vue +2 -3
  41. package/src/views/dsc-component/Sidebar/index.vue +12 -20
  42. package/src/views/dsc-component/tabs/tab-content.vue +1 -5
  43. package/src/views/layout/NewLayout.vue +6 -65
  44. package/src/views/layout/components/Menubar/Item.vue +23 -7
  45. package/src/views/layout/components/Menubar/Link.vue +11 -2
  46. package/src/views/layout/components/Menubar/SidebarItem.vue +50 -7
  47. package/src/views/layout/components/Menubar/index.vue +51 -16
  48. package/src/views/layout/components/tabs/tab-content.vue +160 -0
  49. package/src/views/layout/tab-content-iframe-index.vue +31 -0
  50. package/src/views/layout/tab-content-index.vue +85 -0
  51. package/src/views/login/index.vue +1 -1
  52. package/packages/breadcrumb/index.js +0 -6
  53. package/packages/breadcrumb/src/breadcrumb.vue +0 -71
  54. package/packages/department-tree/index.js +0 -6
  55. package/packages/department-tree/src/department-tree.vue +0 -108
  56. package/packages/department-tree-inline/index.js +0 -6
  57. package/packages/department-tree-inline/src/department-multi-tree-inline.vue +0 -402
  58. package/packages/department-tree-inline/src/department-single-tree-inline.vue +0 -284
  59. package/packages/department-tree-inline/src/department-tree-inline.vue +0 -86
  60. package/packages/department-tree-inline/src/department-tree-service.js +0 -245
  61. package/packages/department-tree-inline/src/search-result.vue +0 -176
  62. package/packages/department-user-tree/index.js +0 -6
  63. package/packages/department-user-tree/src/department-user-multiple-tree.vue +0 -116
  64. package/packages/department-user-tree/src/department-user-single-tree.vue +0 -76
  65. package/packages/department-user-tree/src/department-user-tree.vue +0 -101
  66. package/packages/department-user-tree-inline/index.js +0 -6
  67. package/packages/department-user-tree-inline/src/department-user-multiple-tree-inline.vue +0 -626
  68. package/packages/department-user-tree-inline/src/department-user-single-tree-inline.vue +0 -269
  69. package/packages/department-user-tree-inline/src/department-user-tree-inline.vue +0 -79
  70. package/packages/department-user-tree-inline/src/department-user-tree-multi-service.js +0 -230
  71. package/packages/department-user-tree-inline/src/department-user-tree-single-service.js +0 -122
  72. package/packages/department-user-tree-inline/src/search-result.vue +0 -197
  73. package/packages/directives/prevent-reclick.js +0 -19
  74. package/packages/dynamic-source-select/index.js +0 -6
  75. package/packages/dynamic-source-select/src/dynamic-source-select-service.js +0 -70
  76. package/packages/dynamic-source-select/src/dynamic-source-select.vue +0 -440
  77. package/packages/dynamic-source-select/src/events.js +0 -55
  78. package/packages/fs-preview/index.js +0 -6
  79. package/packages/fs-preview/src/fs-preview.vue +0 -226
  80. package/packages/fs-upload/index.js +0 -6
  81. package/packages/fs-upload/src/fs-upload-multi.vue +0 -420
  82. package/packages/fs-upload/src/fs-upload-single.vue +0 -312
  83. package/packages/fs-upload/src/fs-upload.vue +0 -189
  84. package/packages/fs-upload/src/see-big-picture.vue +0 -55
  85. package/packages/fs-upload-list/index.js +0 -6
  86. package/packages/fs-upload-list/src/fs-upload-list.vue +0 -287
  87. package/packages/hamburger/index.js +0 -6
  88. package/packages/hamburger/src/hamburger.vue +0 -38
  89. package/packages/index.js +0 -121
  90. package/packages/multipart-upload/index.js +0 -6
  91. package/packages/multipart-upload/src/index.vue +0 -73
  92. package/packages/multipart-upload/src/multipart-upload-form.vue +0 -297
  93. package/packages/multipart-upload/src/multipart-upload-list.vue +0 -378
  94. package/packages/organization-input/index.js +0 -6
  95. package/packages/organization-input/src/organization-input.vue +0 -542
  96. package/packages/plugins/export-data-new.js +0 -466
  97. package/packages/plugins/export-data.js +0 -361
  98. package/packages/plugins/index.js +0 -15
  99. package/packages/plugins/public-method.js +0 -43
  100. package/packages/remove-department/index.js +0 -6
  101. package/packages/remove-department/src/remove-department.vue +0 -172
  102. package/packages/remove-department/src/remove-dept-service.js +0 -20
  103. package/packages/remove-user/index.js +0 -6
  104. package/packages/remove-user/src/remove-user-service.js +0 -20
  105. package/packages/remove-user/src/remove-user.vue +0 -195
  106. package/packages/remove-workgroup/index.js +0 -6
  107. package/packages/remove-workgroup/src/remove-workgroup-service.js +0 -20
  108. package/packages/remove-workgroup/src/remove-workgroup.vue +0 -159
  109. package/packages/rich-editor/index.js +0 -7
  110. package/packages/rich-editor/index.vue +0 -278
  111. package/packages/rich-editor/langs/zh-Hans.js +0 -1
  112. package/packages/rich-editor/viewer.vue +0 -103
  113. package/packages/scan-code-input/index.js +0 -6
  114. package/packages/scan-code-input/src/events.js +0 -33
  115. package/packages/scan-code-input/src/scan-code-input-colse.vue +0 -131
  116. package/packages/scan-code-input/src/scan-code-input.vue +0 -116
  117. package/packages/secret-info/index.js +0 -7
  118. package/packages/secret-info/index.vue +0 -90
  119. package/packages/super-grid/index.js +0 -7
  120. package/packages/super-grid/src/apis.js +0 -808
  121. package/packages/super-grid/src/columns-config.vue +0 -335
  122. package/packages/super-grid/src/custom-formatter.js +0 -250
  123. package/packages/super-grid/src/dynamic-input.vue +0 -1279
  124. package/packages/super-grid/src/eventBus.js +0 -2
  125. package/packages/super-grid/src/events.js +0 -55
  126. package/packages/super-grid/src/formValidatorUtil.js +0 -226
  127. package/packages/super-grid/src/formatter.js +0 -181
  128. package/packages/super-grid/src/group-column.vue +0 -100
  129. package/packages/super-grid/src/header-context-menu.vue +0 -87
  130. package/packages/super-grid/src/index-column.vue +0 -51
  131. package/packages/super-grid/src/normal-column.vue +0 -769
  132. package/packages/super-grid/src/public-methods.js +0 -31
  133. package/packages/super-grid/src/row-operation.vue +0 -161
  134. package/packages/super-grid/src/search-button.vue +0 -66
  135. package/packages/super-grid/src/search-condition-input.vue +0 -61
  136. package/packages/super-grid/src/search-condition-list.vue +0 -59
  137. package/packages/super-grid/src/search-form-advancedQuery.vue +0 -653
  138. package/packages/super-grid/src/search-form-dialog.vue +0 -79
  139. package/packages/super-grid/src/search-form-item.vue +0 -400
  140. package/packages/super-grid/src/search-form-number.vue +0 -38
  141. package/packages/super-grid/src/search-form-open.vue +0 -165
  142. package/packages/super-grid/src/search-form-ordinarySearch.vue +0 -191
  143. package/packages/super-grid/src/search-form.vue +0 -637
  144. package/packages/super-grid/src/search-methods.js +0 -454
  145. package/packages/super-grid/src/selection-column.vue +0 -43
  146. package/packages/super-grid/src/store.js +0 -3
  147. package/packages/super-grid/src/super-grid-service.js +0 -562
  148. package/packages/super-grid/src/super-grid.vue +0 -2850
  149. package/packages/super-grid/src/utils.js +0 -762
  150. package/packages/super-grid/src/view-image-dialog.vue +0 -130
  151. package/packages/super-nine-grid/index.js +0 -7
  152. package/packages/super-nine-grid/src/apis.js +0 -103
  153. package/packages/super-nine-grid/src/custom-formatter.js +0 -66
  154. package/packages/super-nine-grid/src/formatter.js +0 -132
  155. package/packages/super-nine-grid/src/search-form-number.vue +0 -38
  156. package/packages/super-nine-grid/src/search-form.vue +0 -430
  157. package/packages/super-nine-grid/src/search-methods.js +0 -134
  158. package/packages/super-nine-grid/src/store.js +0 -3
  159. package/packages/super-nine-grid/src/super-grid-service.js +0 -91
  160. package/packages/super-nine-grid/src/super-nine-grid.vue +0 -872
  161. package/packages/super-nine-grid/src/utils.js +0 -261
  162. package/packages/svg-icon/index.js +0 -6
  163. package/packages/svg-icon/src/svg-icon.vue +0 -43
  164. package/packages/utils/utils.js +0 -152
  165. package/packages/utils/value-set.js +0 -86
  166. package/packages/valid-code/index.js +0 -7
  167. package/packages/valid-code/src/valid-code.vue +0 -95
  168. package/packages/workflow-button/index.js +0 -6
  169. package/packages/workflow-button/src/workflow-button.vue +0 -325
  170. package/packages/workflow-history-list/index.js +0 -6
  171. package/packages/workflow-history-list/src/api.js +0 -7
  172. package/packages/workflow-history-list/src/workflow-history-list.vue +0 -185
  173. package/packages/workgroup-tree/index.js +0 -6
  174. package/packages/workgroup-tree/src/workgroup-tree.vue +0 -76
  175. package/packages/workgroup-tree-inline/index.js +0 -6
  176. package/packages/workgroup-tree-inline/src/workgroup-tree-inline.vue +0 -317
  177. package/packages/workgroup-tree-inline/src/workgroup-tree-service.js +0 -43
  178. package/packages/workgroup-user-tree/index.js +0 -6
  179. package/packages/workgroup-user-tree/src/workgroup-user-tree.vue +0 -100
  180. package/packages/workgroup-user-tree-inline/index.js +0 -6
  181. package/packages/workgroup-user-tree-inline/src/workgroup-tree-inline-service.js +0 -163
  182. package/packages/workgroup-user-tree-inline/src/workgroup-user-tree-inline.vue +0 -436
  183. package/packages/year-range-picker/index.js +0 -6
  184. package/packages/year-range-picker/src/year-range-picker.vue +0 -51
  185. package/src/index.js +0 -93
  186. package/src/styles/theme/gray/form-style.scss +0 -41
@@ -1,808 +0,0 @@
1
- import store from './store'
2
- import {
3
- setCurrentRow,
4
- isEditOptionFunction,
5
- isLastEditRowSave,
6
- isHasEditOption,
7
- scrollYToBottom
8
- } from './utils'
9
- import formValidatorService from './formValidatorUtil'
10
- import Vue from 'vue'
11
- import {
12
- getEntityFieldValue,
13
- getI18n,
14
- setEntityFieldValue,
15
- getPropValue
16
- } from '../../../src/utils/util'
17
- import eventBus from './eventBus'
18
- const apis = {
19
- // 刷新列表数据
20
- refresh(parentRowIds, isLineEdit, toolbarFieldParam, isDeleteSubTableData) {
21
- return new Promise((resolve, reject) => {
22
- if (isDeleteSubTableData) {
23
- // 清空options.subTableData
24
- const gridParams = store.get(this.code)
25
- this.$set(gridParams.options, 'subTableData', null)
26
- }
27
- if (toolbarFieldParam && toolbarFieldParam.length > 0) {
28
- this.toolbarFieldParam = toolbarFieldParam
29
- }
30
- if (this.$refs) {
31
- if (typeof (parentRowIds) !== 'undefined' && parentRowIds !== null && parentRowIds instanceof Array && parentRowIds.length > 0) {
32
- // 树形数据时,刷新父记录对应的子记录集合时
33
- if (this.$refs.sf) {
34
- let param = this.$refs.sf.packageSearchParam()
35
- if (param && param.length > 0) {
36
- if (toolbarFieldParam && toolbarFieldParam.length > 0) {
37
- if (param.length === 1) {
38
- param[0].leftBracket = '('
39
- param[0].rightBracket = ')'
40
- }
41
- if (param[param.length - 1].joinSign === 'or') {
42
- param[param.length - 1].joinSign = 'and'
43
- }
44
- // 拼接
45
- Array.prototype.push.apply(param, toolbarFieldParam)
46
- }
47
- } else {
48
- if (toolbarFieldParam) {
49
- param = []
50
- param = toolbarFieldParam
51
- }
52
- }
53
- this.search(param, false, parentRowIds).then(() => resolve()).catch(error => reject(error))
54
- } else {
55
- this.search(toolbarFieldParam, false, parentRowIds).then(() => resolve()).catch(error => reject(error))
56
- }
57
- } else {
58
- // 刷新列表数据
59
- if (this.$refs.sf) {
60
- let param = this.$refs.sf.packageSearchParam()
61
- if (param && param.length > 0) {
62
- if (toolbarFieldParam && toolbarFieldParam.length > 0) {
63
- if (param.length === 1) {
64
- param[0].leftBracket = '('
65
- param[0].rightBracket = ')'
66
- }
67
- if (param[param.length - 1].joinSign === 'or') {
68
- param[param.length - 1].joinSign = 'and'
69
- }
70
- // 拼接
71
- // param.concat(toolbarFieldParam)
72
- Array.prototype.push.apply(param, toolbarFieldParam)
73
- }
74
- } else {
75
- if (toolbarFieldParam) {
76
- param = []
77
- param = toolbarFieldParam
78
- }
79
- }
80
- this.search(param, false).then(() => resolve()).catch(error => reject(error))
81
- } else {
82
- this.search(toolbarFieldParam, false).then(() => resolve()).catch(error => reject(error))
83
- }
84
- }
85
- } else {
86
- resolve()
87
- }
88
- })
89
- },
90
- // 显示查询
91
- showSearchForm() {
92
- this.showSearch = true
93
- this.$emit('showSearch')
94
- },
95
- // 取消查询
96
- cancelSearch() {
97
- this.showSearch = false
98
- this.$emit('cancelSearch')
99
- },
100
- // 获得查询条件
101
- getSearchForm() {
102
- const gridParams = store.get(this.code)
103
- if (gridParams.searchForm) {
104
- return gridParams.searchForm
105
- } else {
106
- return []
107
- }
108
- },
109
- // 新建行
110
- createRow(listCode, row) {
111
- return new Promise((resolve, reject) => {
112
- if (!listCode) {
113
- listCode = store.get('_list_code')
114
- }
115
- const gridParams = store.get(listCode)
116
- const gridData = gridParams.gridData
117
- gridParams.superGrid.clearSort()
118
- // console.log('创建行记录的条件1', gridParams.lineEdit)
119
- // console.log('创建行记录的条件2', gridParams.lineEdit.editable)
120
- // console.log('创建行记录的条件3', gridParams.loaded)
121
- if (gridParams.lineEdit && gridParams.lineEdit.editable &&
122
- (typeof (gridParams.loaded) !== 'undefined' && gridParams.loaded === true)) {
123
- // gridParams.loaded表示列表数据是否已加载成功,加载成功才允许新建记录
124
- // 插入行前的回调
125
- let canCreate = true
126
- if (isEditOptionFunction('beforeInsertRow', listCode)) {
127
- const isSubTableShowPage = gridParams.isSubTableShowPage
128
- // 每页显示多少条
129
- const pageSize = gridParams.pagination && gridParams.pagination.pageSize
130
- const isMobile = false
131
- canCreate = gridParams.options.lineEditOptions.beforeInsertRow.call(this, isSubTableShowPage ? gridParams.subTableData : gridParams.gridData, gridParams.$rowIndex, isMobile, this.baseURL, isSubTableShowPage ? gridParams.gridData : null, pageSize)
132
- }
133
- // console.log('创建行记录执行前判断', canCreate)
134
- // console.log('创建行记录gridParams.options.isFormSubTable=', gridParams.options.isFormSubTable)
135
- if (canCreate === undefined || canCreate === true) {
136
- if (gridParams.options && gridParams.options.isFormSubTable) {
137
- // 如果是表单子表模式,则不需要判断上一行是否是编辑状态
138
- // 取消上一行的编辑状态
139
- let myGridData = gridParams.gridData
140
- if (gridParams.isSubTableShowPage !== undefined && gridParams.isSubTableShowPage === true) {
141
- // 子表集合
142
- myGridData = gridParams.subTableData
143
- }
144
- const editRows = myGridData.filter((row) => (row.$editing !== undefined && row.$editing === true))
145
- if (editRows && editRows.length > 0) {
146
- editRows.forEach(editRow => {
147
- setEntityFieldValue(editRow, '$editing', false)
148
- // 取消上一行选中状态时,触发un-edit事件,处理下拉多选选项组问题
149
- eventBus.$emit('un-edit', { row: editRow })
150
- // Vue.set(editRow, '$editing', false)
151
- })
152
- }
153
- gridParams.isEditRow = false
154
- } else {
155
- if ((!isLastEditRowSave(listCode)) || (typeof (gridParams.isCreateRow) !== 'undefined' && gridParams.isCreateRow === true)) {
156
- // 最后编辑的一行没有保存 或(说明刚刚新建的行还没有保存 或 撤销编辑),则提示
157
- Vue.prototype.$message({
158
- showClose: true,
159
- message: getI18n().t('superGrid.pleaseSaveLine', {
160
- row: (gridParams.$rowIndex + 1)
161
- }),
162
- type: 'warning'
163
- })
164
- reject(new Error('please save line'))
165
- return
166
- }
167
- // 取消上一行的编辑状态
168
- if (typeof (gridParams.$rowIndex) !== 'undefined' && gridParams.$rowIndex !== null &&
169
- gridParams.$rowIndex < gridParams.gridData.length) {
170
- // 表示是有效行
171
- const lastEditRow = gridParams.gridData[gridParams.$rowIndex]
172
- setEntityFieldValue(lastEditRow, '$editing', false)
173
- // Vue.set(lastEditRow, '$editing', false)
174
- gridParams.isEditRow = false
175
- }
176
- }
177
- // 新建行
178
- row = this.getNewRow(gridParams.defaultValueColumns, gridParams.additionalParamMap, gridParams.contextParameter, row)
179
-
180
- // console.log('创建行记录要添加的新行1', row)
181
- setEntityFieldValue(row, '$editing', true)
182
- // Vue.set(row, '$editing', true)
183
- gridParams.isEditRow = true
184
- // console.log('创建行记录要添加的新行2', row)
185
- // console.log('创建行所属的list1', gridData)
186
- if (gridParams.options && gridParams.options.isFormSubTable) {
187
- // 表单的子表行编辑时显示是添加到最后面
188
- if (gridParams.isSubTableShowPage !== undefined && gridParams.isSubTableShowPage === true) {
189
- // 子表集合添加该新建的行。会触发watch subTableData的监控
190
- gridParams.isChangePage = true
191
- gridParams.subTableData.splice(gridParams.subTableData.length, 0, row)
192
- } else {
193
- // 子表不分页
194
- gridData.splice(gridData.length, 0, row)
195
- if (gridParams.lineEdit.editingCell) {
196
- gridParams.lineEdit.editingCell.row = gridData.length
197
- }
198
- }
199
-
200
- gridParams.$rowIndex = gridData.length
201
- // 滚动条滚到最后
202
- this.$nextTick(() => {
203
- scrollYToBottom(listCode)
204
- })
205
- } else {
206
- // 表格行编辑新建时是添加到最前面
207
- gridData.splice(0, 0, row)
208
- if (gridParams.lineEdit.editingCell) {
209
- gridParams.lineEdit.editingCell.row = 0
210
- }
211
-
212
- gridParams.$rowIndex = 0
213
- }
214
-
215
- // console.log('创建行所属的list2', gridData)
216
- // console.log('创建行所属的打印gridParams.gridData', gridParams.gridData)
217
- const orgRow = Object.assign({}, row)
218
- gridParams.orgGridData.splice(0, 0, orgRow)
219
- if (!gridParams.lineEdit.editingCell) {
220
- gridParams.lineEdit.editingCell = {}
221
- gridParams.lineEdit.validateErrorField = ''
222
- }
223
- // 插入行后的回调
224
- if (isEditOptionFunction('afterInsertRow', listCode)) {
225
- const isSubTableShowPage = gridParams.isSubTableShowPage
226
- // 每页显示多少条
227
- const pageSize = gridParams.pagination && gridParams.pagination.pageSize
228
- const isMobile = false
229
- gridParams.options.lineEditOptions.afterInsertRow.call(this, isSubTableShowPage ? gridParams.subTableData : gridParams.gridData, gridParams.$rowIndex, isMobile, this.baseURL, isSubTableShowPage ? gridParams.gridData : null, pageSize)
230
- }
231
-
232
- gridParams.isCreateRow = true
233
- resolve(row)
234
- } else {
235
- reject(new Error('can not create'))
236
- }
237
- } else {
238
- reject(new Error('list not editable or data not loaded completely'))
239
- }
240
- })
241
- },
242
- // 获取一个新的对象,已经解析完默认值
243
- getNewRow(defaultValueColumns, additionalParamMap, contextParameter, row, listCode) {
244
- if (!row) {
245
- row = {}
246
- }
247
- if (!listCode) {
248
- listCode = store.get('_list_code')
249
- }
250
- const gridParams = store.get(listCode)
251
- if (gridParams && gridParams.allColumns) {
252
- this.setColumnsDefaultValue(gridParams.allColumns, row)
253
- }
254
- if (defaultValueColumns && defaultValueColumns.length > 0) {
255
- for (var i = 0; i < defaultValueColumns.length; i++) {
256
- const col = defaultValueColumns[i]
257
- if (col && col.prop) {
258
- const propValue = getEntityFieldValue(row, col.prop)
259
- if (col.prop !== '$selection' && col.prop !== '$index') {
260
- if (col.defaultValue && col.defaultValue !== '' && (propValue === undefined || propValue === '' || propValue === null)) {
261
- const value = getPropValue(col.defaultValue, row, additionalParamMap, contextParameter)
262
- setEntityFieldValue(row, col.prop, value)
263
- }
264
- }
265
- }
266
- }
267
- }
268
- return row
269
- },
270
- // 设置默认值null
271
- setColumnsDefaultValue(allColumns, row) {
272
- for (let i = 0; i < allColumns.length; i++) {
273
- const column = allColumns[i]
274
- const prop = column.prop
275
- if (prop === '$index' || prop === '$selection' || prop === 'operation') {
276
- continue
277
- }
278
- if (column.hasOwnProperty('children')) {
279
- // 表示是组合表头,需要判断子表头是否显示
280
- this.setChildrenColumnsDefaultValue(column.children, row)
281
- } else {
282
- if (row[prop] === undefined) {
283
- // 不是操作列,才需要设值
284
- setEntityFieldValue(row, prop, null)
285
- }
286
- }
287
- }
288
- setEntityFieldValue(row, '$editing', false)
289
- },
290
- setChildrenColumnsDefaultValue(children, row) {
291
- for (let i = 0; i < children.length; i++) {
292
- const column = children[i]
293
- const prop = column.prop
294
- if (column.hasOwnProperty('children')) {
295
- // 表示是组合表头,需要判断子表头是否显示
296
- this.setChildrenColumnsDefaultValue(column.children, row)
297
- } else {
298
- if (row[prop] === undefined) {
299
- if (prop !== 'operation') {
300
- // 不是操作列,才需要设值
301
- setEntityFieldValue(row, prop, null)
302
- }
303
- }
304
- }
305
- }
306
- },
307
- // 编辑行
308
- editRow(rowIndex, listCode, isSaveCallback) {
309
- if (!listCode) {
310
- listCode = store.get('_list_code')
311
- }
312
- const gridParams = store.get(listCode)
313
- if (gridParams && gridParams.lineEdit && gridParams.lineEdit.editable) {
314
- if (typeof (gridParams.$rowIndex) !== 'undefined' && gridParams.$rowIndex !== null && gridParams.$rowIndex !== rowIndex) {
315
- // 不是当前编辑行时
316
- if (typeof (gridParams.options.lineEditOptions.autoSave) === 'undefined' ||
317
- (isHasEditOption('autoSave', listCode) && gridParams.options.lineEditOptions.autoSave === true)) {
318
- // 自动保存行数据
319
- if (!isSaveCallback) {
320
- // 点击了“编辑”按钮时需要走,不是自动保存行数据后回调方法中调用的editRow时
321
- this.saveRow(gridParams.$rowIndex, listCode)
322
- .then((res) => {
323
- this.editRow(rowIndex, listCode, true)
324
- })
325
- return
326
- }
327
- } else {
328
- // 如果不自动保存,则提示数据没有保存,让用户自己保存
329
- if (!isLastEditRowSave(listCode)) {
330
- // 最后编辑的一行没有保存,则提示
331
- Vue.prototype.$message({
332
- showClose: true,
333
- message: getI18n().t('superGrid.pleaseSaveLine', {
334
- row: (gridParams.$rowIndex + 1)
335
- }),
336
- type: 'warning'
337
- })
338
- return
339
- }
340
- }
341
- }
342
-
343
- let canEdit = true
344
- if (isEditOptionFunction('beforeEdit', listCode)) {
345
- const isSubTableShowPage = gridParams.isSubTableShowPage
346
- // 每页显示多少条
347
- const pageSize = gridParams.pagination && gridParams.pagination.pageSize
348
- canEdit = gridParams.options.lineEditOptions.beforeEdit.call(this, {
349
- gridData: isSubTableShowPage ? gridParams.subTableData : gridParams.gridData,
350
- listCode: listCode,
351
- entity: gridParams.gridData[rowIndex],
352
- rowIndex: rowIndex,
353
- columns: gridParams.columns,
354
- isMobile: false,
355
- pageGridData: isSubTableShowPage ? gridParams.gridData : null,
356
- pageSize
357
- })
358
- }
359
- if (canEdit === undefined || canEdit === true) {
360
- // 取消上一行的编辑状态
361
- if (typeof (gridParams.$rowIndex) !== 'undefined' && gridParams.$rowIndex !== null &&
362
- gridParams.$rowIndex < gridParams.gridData.length) {
363
- const lastEditRow = gridParams.gridData[gridParams.$rowIndex]
364
- setEntityFieldValue(lastEditRow, '$editing', false)
365
- // Vue.set(lastEditRow, '$editing', false)
366
- gridParams.isEditRow = false
367
- }
368
- // 使指定行变为编辑状态
369
- const row = gridParams.gridData[rowIndex]
370
- setEntityFieldValue(row, '$editing', true)
371
- // Vue.set(row, '$editing', true)
372
- gridParams.$lastSaveRowIndex = null
373
- gridParams.$rowIndex = rowIndex
374
- gridParams.isEditRow = true
375
- // 使指定行变为编辑状态,触发获得焦点
376
- if (gridParams.lineEdit.editingCell) {
377
- gridParams.lineEdit.editingCell.row = rowIndex
378
- }
379
- }
380
- }
381
- },
382
- saveRow(rowIndex, listCode) {
383
- return new Promise((resolve, reject) => {
384
- const vm = this
385
- // 添加setTimeout是因为保存时事件和input等组件的@blur冲突,导致保存需要保存两次
386
- setTimeout(function() {
387
- vm.saveCurrentRow(rowIndex, listCode).then(data => {
388
- resolve(data)
389
- })
390
- }, 100)
391
- })
392
- },
393
- saveCurrentRow(rowIndex, listCode) {
394
- return new Promise((resolve, reject) => {
395
- if (!listCode) {
396
- listCode = store.get('_list_code')
397
- }
398
- const gridParams = store.get(listCode)
399
- if (gridParams.lineEdit && gridParams.lineEdit.editable) {
400
- if (typeof (gridParams.gridData[rowIndex].$editing) === 'undefined' || gridParams.gridData[rowIndex].$editing === false) {
401
- Vue.prototype.$message({
402
- showClose: true,
403
- message: getI18n().t('superGrid.noNeedToSaveRow', {
404
- row: (rowIndex + 1)
405
- }),
406
- type: 'warning'
407
- })
408
- return
409
- }
410
- // console.log('gridParams', gridParams)
411
- if (gridParams.$rowIndex !== rowIndex && !isLastEditRowSave(listCode)) {
412
- // 最后编辑的一行没有保存,则提示
413
- Vue.prototype.$message({
414
- showClose: true,
415
- message: getI18n().t('superGrid.pleaseSaveLine', {
416
- row: (gridParams.$rowIndex + 1)
417
- }),
418
- type: 'warning'
419
- })
420
- return
421
- }
422
- gridParams.$lastSaveRowIndex = null
423
- if ((gridParams.isHasDynamic !== undefined && gridParams.isHasDynamic === false) && !gridParams.lineEdit.urlToSaveRow && !isHasEditOption('urlToSaveRow', listCode) && !isEditOptionFunction('saveRow', listCode)) {
424
- Vue.prototype.$message({
425
- showClose: true,
426
- message: getI18n().t('superGrid.pleaseSetURLToSaveRowInformation'),
427
- type: 'warning'
428
- })
429
- return
430
- }
431
- if (!gridParams.canSaveRow) {
432
- // 防止重复保存
433
- return
434
- }
435
- gridParams.canSaveRow = false
436
- const row = gridParams.gridData[rowIndex]
437
- let needValidate = true
438
- if (isHasEditOption('isEnableValidate', listCode)) {
439
- // 表示配置了是否启用必填验证
440
- needValidate = gridParams.options.lineEditOptions['isEnableValidate']
441
- }
442
- let validateResult = true
443
- if (needValidate === true) {
444
- validateResult = formValidatorService.validator(row, listCode, rowIndex)
445
- }
446
- if (validateResult === true) {
447
- let canSave = true
448
- if (isEditOptionFunction('beforeSave', listCode)) {
449
- canSave = gridParams.options.lineEditOptions['beforeSave'].call(this, row, gridParams.columns)
450
- }
451
- if (canSave === undefined || canSave === true) {
452
- // 触发点击保存时的事件线,在 normal-column 监听处对字段控件是选项组的字段的值进行处理
453
- eventBus.$emit('un-edit', { row })
454
- let additionalParamMap = null
455
- if (gridParams.additionalParamMap && typeof (gridParams.additionalParamMap) === 'object') {
456
- additionalParamMap = gridParams.additionalParamMap
457
- } else if (gridParams.additionalParamMap && gridParams.additionalParamMap !== '') {
458
- additionalParamMap = JSON.parse(gridParams.additionalParamMap)
459
- }
460
- let saveRowRequest
461
- if (isEditOptionFunction('saveRow', listCode)) {
462
- // 表示保存方法,用户自己重写了
463
- saveRowRequest = gridParams.options.lineEditOptions['saveRow'].call(this, row, gridParams.columns, gridParams.$dataTypeMap, gridParams.dynamicColumnInfo, additionalParamMap, gridParams.mainDefaultValueColumns)
464
- }
465
- if (!saveRowRequest && gridParams.lineEdit && gridParams.lineEdit.urlToSaveRow) {
466
- // 使用默认的保存实现
467
- let urlToSaveRow = gridParams.lineEdit.urlToSaveRow
468
- if (isHasEditOption('urlToSaveRow', listCode)) {
469
- // 表示手动配置了保存行记录的url
470
- urlToSaveRow = gridParams.options.lineEditOptions['urlToSaveRow']
471
- }
472
- saveRowRequest = Vue.prototype.$http.post(Vue.prototype.baseURL + urlToSaveRow, row)
473
- }
474
- if (gridParams.isHasDynamic !== undefined && gridParams.isHasDynamic === true && !saveRowRequest) {
475
- // 表示有动态列,保存时使用平台封装好的请求
476
- const urlToSaveRow = '/common/dynamic-values'
477
- const dynamicValueDTO = {
478
- mainTableName: gridParams.basicInfo && gridParams.basicInfo.tableName ? gridParams.basicInfo.tableName : '',
479
- row: row,
480
- dynamicColumnInfo: gridParams.dynamicColumnInfo,
481
- additionalParamMap: additionalParamMap,
482
- dataTypeMap: gridParams.$dataTypeMap,
483
- dynamicServiceName: gridParams.dynamicServiceName,
484
- mainDefaultValueColumns: gridParams.mainDefaultValueColumns
485
- }
486
- saveRowRequest = Vue.prototype.$http.post(Vue.prototype.baseURL + urlToSaveRow, dynamicValueDTO)
487
- }
488
- if (saveRowRequest) {
489
- saveRowRequest.then(data => {
490
- this.afterSave(gridParams, rowIndex, listCode, data, row).then(data => {
491
- resolve(data)
492
- }).catch(error => {
493
- reject(error)
494
- })
495
- }).catch(error => {
496
- gridParams.canSaveRow = true
497
- if (isEditOptionFunction('saveError', listCode)) {
498
- gridParams.options.lineEditOptions['saveError'].call(this, row, gridParams.columns, rowIndex, error)
499
- }
500
- reject(error)
501
- })
502
- } else {
503
- gridParams.canSaveRow = true
504
- reject(getI18n().t('saveRowRequest is undefined'))
505
- }
506
- } else {
507
- gridParams.canSaveRow = true
508
- reject(getI18n().t('superGrid.theReturnValueOfTheBeforesaveCallbackMethodIsFalse'))
509
- }
510
- } else {
511
- gridParams.canSaveRow = true
512
- reject(getI18n().t('imatrixUIMessage.validationFailed'))
513
- }
514
- }
515
- })
516
- },
517
- afterSave(gridParams, rowIndex, listCode, data, row) {
518
- return new Promise((resolve, reject) => {
519
- gridParams.isCreateRow = false
520
- gridParams.canSaveRow = true
521
- gridParams.$rowIndex = null
522
- // 当前是否有正在编辑的行
523
- gridParams.isEditRow = false
524
- gridParams.$lastSaveRowIndex = rowIndex
525
- Vue.prototype.$message({
526
- showClose: true,
527
- message: getI18n().t('superGrid.lineSavedSuccessfully', {
528
- row: (rowIndex + 1)
529
- }),
530
- type: 'success'
531
- })
532
- if (typeof (gridParams.options.lineEditOptions.aftersaveIsCancelEditState) === 'undefined' ||
533
- (isHasEditOption('aftersaveIsCancelEditState', listCode) &&
534
- gridParams.options.lineEditOptions.aftersaveIsCancelEditState === true)) {
535
- // 取消编辑状态
536
- setEntityFieldValue(row, '$editing', false)
537
- // Vue.set(row, '$editing', false)
538
- gridParams.isEditRow = false
539
- }
540
-
541
- if (isEditOptionFunction('saveSuccess', listCode)) {
542
- gridParams.options.lineEditOptions['saveSuccess'].call(this, data, gridParams.columns, rowIndex, row)
543
- }
544
- Object.assign(gridParams.orgGridData[rowIndex], data)
545
- // 必须加这句,否则连续保存时报事务异常
546
- Object.assign(gridParams.gridData[rowIndex], data)
547
- // 必须调用这句话,刷新一下列表,否则当前页总条数和记录总条数都会显示错误
548
- this.refresh(false, true)
549
- .then(() => {
550
- if (typeof (gridParams.options.lineEditOptions.aftersaveIsCreateRow) === 'undefined' || gridParams.options.lineEditOptions.aftersaveIsCreateRow) {
551
- this.createRow(listCode)
552
- }
553
- resolve({
554
- rowIndex,
555
- listCode
556
- })
557
- })
558
- .catch((error) => reject(error))
559
- })
560
- },
561
- restoreRow(rowIndex, listCode) {
562
- // 撤销当前行的编辑的信息
563
- return new Promise((resolve, reject) => {
564
- this.restoreCurrentRow(rowIndex, listCode)
565
- resolve()
566
- })
567
- },
568
- /**
569
- * 撤销当前指定编辑行的信息
570
- */
571
- restoreCurrentRow(rowIndex, listCode) {
572
- if (!listCode) {
573
- listCode = store.get('_list_code')
574
- }
575
- const gridParams = store.get(listCode)
576
- // console.log('restoreCurrentRow-gridParams.$rowIndex,rowIndex', gridParams.$rowIndex, rowIndex)
577
- if (gridParams.lineEdit && gridParams.lineEdit.editable) {
578
- if (gridParams.$rowIndex !== null && gridParams.$rowIndex !== rowIndex && !isLastEditRowSave(listCode)) {
579
- // 最后编辑的一行没有保存,则提示
580
- Vue.prototype.$message({
581
- showClose: true,
582
- message: getI18n().t('superGrid.pleaseSaveLine', {
583
- row: (gridParams.$rowIndex + 1)
584
- }),
585
- type: 'warning'
586
- })
587
- return
588
- }
589
- // true表示没有编辑任何字段,false表示当前行有编辑的字段
590
- const isUnEditing = gridParams.$lastSaveRowIndex !== null && gridParams.$lastSaveRowIndex === rowIndex && typeof (gridParams.gridData[rowIndex].id) !== 'undefined'
591
- let isValidate = true
592
- // 撤销编辑前的回调
593
- if (isEditOptionFunction('beforeRestoreValidate', listCode)) {
594
- const isSubTableShowPage = gridParams.isSubTableShowPage
595
- // 每页显示多少条
596
- const pageSize = gridParams.pagination && gridParams.pagination.pageSize
597
- const isMobile = false
598
- isValidate = gridParams.options.lineEditOptions.beforeRestoreValidate.call(this, { rowIndex, gridData: isSubTableShowPage ? gridParams.subTableData : gridParams.gridData, entity: gridParams.gridData[rowIndex], isMobile, baseURL: this.baseURL, isEditing: !isUnEditing, pageGridData: isSubTableShowPage ? gridParams.gridData : null, pageSize })
599
- }
600
- if (isValidate === undefined || isValidate === true) {
601
- // 例如:自定义验证成功,再继续平台的验证
602
- if (isUnEditing === true) {
603
- // 当前行已保存,已是最新数据,无需再撤销编辑
604
- // console.log('gridParams.gridData[rowIndex].id=', gridParams.gridData[rowIndex].id)
605
- Vue.prototype.$message({
606
- showClose: true,
607
- message: getI18n().t('superGrid.lineNoNeedToUndoEdit', {
608
- row: (rowIndex + 1)
609
- }),
610
- type: 'warning'
611
- })
612
- return
613
- }
614
- } else {
615
- return
616
- }
617
- let canRestore = true
618
- // 撤销编辑前的回调
619
- if (isEditOptionFunction('beforeRestore', listCode)) {
620
- const isSubTableShowPage = gridParams.isSubTableShowPage
621
- // 每页显示多少条
622
- const pageSize = gridParams.pagination && gridParams.pagination.pageSize
623
- const isMobile = false
624
- canRestore = gridParams.options.lineEditOptions.beforeRestore.call(this, { rowIndex, gridData: isSubTableShowPage ? gridParams.subTableData : gridParams.gridData, entity: gridParams.gridData[rowIndex], isMobile, baseURL: Vue.prototype.baseURL, isEditing: !isUnEditing, pageGridData: isSubTableShowPage ? gridParams.gridData : null, pageSize })
625
- }
626
- if (canRestore === undefined || canRestore === true) {
627
- // 如果没有编辑过任何行
628
- if (!gridParams.orgGridData[rowIndex].id && !gridParams.orgGridData[rowIndex].ID) {
629
- // 表示没有保存行数据,需要删除该行记录
630
- this.deleteRow(rowIndex, listCode, true)
631
- } else {
632
- // 这样写会导致“如果字段值原来是空的,输入了内容后,取消编辑没法把输入的值清空”问题
633
- // Object.assign(gridParams.gridData[rowIndex], gridParams.orgGridData[rowIndex])
634
- // 所以改成如下写法
635
- Vue.set(gridParams.gridData, rowIndex, JSON.parse(JSON.stringify(gridParams.orgGridData[rowIndex])))
636
- if (gridParams.isSubTableShowPage !== undefined && gridParams.isSubTableShowPage === true) {
637
- // 子表集合移除该行。会触发watch subTableData的监控
638
- const lastPageRowIndex = (this.currentPage - 1) * this.pageSize
639
- const subTableRowIndex = lastPageRowIndex + rowIndex
640
- Vue.set(gridParams.subTableData, subTableRowIndex, gridParams.gridData[rowIndex])
641
- }
642
- Vue.prototype.$message({
643
- showClose: true,
644
- message: getI18n().t('superGrid.lineCancelledSuccessfully', {
645
- row: (rowIndex + 1)
646
- }),
647
- type: 'success'
648
- })
649
-
650
- if (typeof (gridParams.options.lineEditOptions.afterRestoreIsCancelEditState) === 'undefined' ||
651
- (isHasEditOption('afterRestoreIsCancelEditState', listCode) &&
652
- gridParams.options.lineEditOptions.afterRestoreIsCancelEditState === true)) {
653
- // 取消编辑状态
654
- setEntityFieldValue(gridParams.gridData[rowIndex], '$editing', false)
655
- // Vue.set(gridParams.gridData[rowIndex], '$editing', false)
656
- gridParams.isEditRow = false
657
- }
658
- }
659
- gridParams.$rowIndex = null
660
- gridParams.isCreateRow = false
661
- // 撤销编辑后回调
662
- if (isEditOptionFunction('afterRestore', listCode)) {
663
- gridParams.options.lineEditOptions.afterRestore.call(this, rowIndex, gridParams.orgGridData[rowIndex])
664
- }
665
- }
666
- }
667
- },
668
- deleteRow(rowIndex, listCode, isRestore) {
669
- return new Promise((resolve, reject) => {
670
- if (!listCode) {
671
- listCode = store.get('_list_code')
672
- }
673
- const gridParams = store.get(listCode)
674
- let canDelete = true
675
- // 删除行记录前的回调
676
- if (isEditOptionFunction('beforeDelete', listCode)) {
677
- const isSubTableShowPage = gridParams.isSubTableShowPage
678
- // 每页显示多少条
679
- const pageSize = gridParams.pagination && gridParams.pagination.pageSize
680
- const gridData = isSubTableShowPage ? gridParams.subTableData : gridParams.gridData
681
- const isMobile = false
682
- canDelete = gridParams.options.lineEditOptions.beforeDelete.call(this, rowIndex, gridParams.gridData[rowIndex], gridData, isMobile, this.baseURL, isSubTableShowPage ? gridParams.gridData : null, pageSize)
683
- }
684
- if (canDelete === undefined || canDelete === true) {
685
- if (gridParams.isSubTableShowPage !== undefined && gridParams.isSubTableShowPage === true) {
686
- // 子表集合添加该新建的行。会触发watch subTableData的监控
687
- gridParams.isChangePage = true
688
- const lastPageRowIndex = (this.currentPage - 1) * this.pageSize
689
- const subTableRowIndex = lastPageRowIndex + rowIndex
690
-
691
- gridParams.subTableData.splice(subTableRowIndex, 1)
692
- } else {
693
- gridParams.gridData.splice(rowIndex, 1)
694
- gridParams.orgGridData.splice(rowIndex, 1)
695
- }
696
- // TODO 注释下面的代码,是因为表单子表删除记录时会造成未保存新增的记录的字段被清空的问题,不知道当时为什么要加这个代码
697
- // Object.assign(gridParams.gridData, gridParams.orgGridData)
698
- gridParams.$lastSaveRowIndex = null
699
- gridParams.$rowIndex = null
700
- gridParams.isEditRow = false
701
- Vue.prototype.$message({
702
- showClose: true,
703
- message: getI18n().t('superGrid.deleteSuccessful'),
704
- type: 'success'
705
- })
706
- if (gridParams.gridData.length === 0) {
707
- if (gridParams.options && gridParams.options.isDefaultShowEdit !== null &&
708
- gridParams.options.isDefaultShowEdit !== undefined && gridParams.options.isDefaultShowEdit === true) {
709
- // 表示没有记录时,需要创建新行
710
- this.createRow(listCode)
711
- }
712
- }
713
- if (gridParams.isMulitiSelect) {
714
- gridParams.superGrid.clearSelection()
715
- }
716
- gridParams.isCreateRow = false
717
- if (isRestore !== undefined && isRestore === true) {
718
- // 表示是删除操作,执行删除记录后回调
719
- if (isEditOptionFunction('afterDelete', listCode)) {
720
- const isSubTableShowPage = gridParams.isSubTableShowPage
721
- // 每页显示多少条
722
- const pageSize = gridParams.pagination && gridParams.pagination.pageSize
723
- const isMobile = false
724
- gridParams.options.lineEditOptions.afterDelete.call(this, rowIndex, gridParams.orgGridData[rowIndex], isSubTableShowPage ? gridParams.subTableData : gridParams.gridData, isMobile, this.baseURL, isSubTableShowPage ? gridParams.gridData : null, pageSize)
725
- }
726
- }
727
- }
728
-
729
- resolve()
730
- })
731
- },
732
- // 行编辑时,点击自定义组件时,使当前行获得焦点
733
- focus(rowIndex, listCode) {
734
- setCurrentRow(rowIndex, listCode)
735
- },
736
- // 获得列表所有数据
737
- getGridData(listCode) {
738
- if (!listCode) {
739
- listCode = store.get('_list_code')
740
- }
741
- const gridParams = store.get(listCode)
742
- const isSubTableShowPage = gridParams.isSubTableShowPage
743
- if (isSubTableShowPage) {
744
- return gridParams.subTableData
745
- } else {
746
- return gridParams.gridData
747
- }
748
- },
749
- // 获得字段配置
750
- getColumns(listCode) {
751
- if (!listCode) {
752
- listCode = store.get('_list_code')
753
- }
754
- const gridParams = store.get(listCode)
755
- return gridParams.columns
756
- },
757
- getPagination(listCode) {
758
- if (!listCode) {
759
- listCode = store.get('_list_code')
760
- }
761
- const gridParams = store.get(listCode)
762
- return gridParams.pagination
763
- },
764
- // 获得该列表中,下拉选是选项组的字段信息,返回的key是属性名,value是选项集合
765
- getOptionsValueSet(listCode) {
766
- const result = {}
767
- if (!listCode) {
768
- listCode = store.get('_list_code')
769
- }
770
- const gridParams = store.get(listCode)
771
- const columns = gridParams.columns
772
- columns.forEach(col => {
773
- if (col.valueSet && col.valueSet.length > 0) {
774
- result[col.prop] = col.valueSet
775
- }
776
- })
777
- return result
778
- },
779
- // 取消列表的编辑状态
780
- restoreGridEdit(listCode) {
781
- if (!listCode) {
782
- listCode = store.get('_list_code')
783
- }
784
- const gridParams = store.get(listCode)
785
- if (gridParams.options && gridParams.options.isFormSubTable) {
786
- const isSubTableShowPage = gridParams.isSubTableShowPage
787
- let gridData = []
788
- if (isSubTableShowPage) {
789
- gridData = gridParams.subTableData
790
- } else {
791
- gridData = gridParams.gridData
792
- }
793
- if (gridData && gridData.length > 0) {
794
- for (let i = 0; i < gridData.length; i++) {
795
- const row = gridData[i]
796
- // 取消最后一个编辑行的状态
797
- if (row.$editing !== undefined && row.$editing === true) {
798
- setEntityFieldValue(row, '$editing', false)
799
- // 取消上一行选中状态时,触发un-edit事件,处理下拉多选选项组问题
800
- eventBus.$emit('un-edit', { row: row })
801
- break
802
- }
803
- }
804
- }
805
- }
806
- }
807
- }
808
- export default apis