@bytenew/bn-bus-ui 1.1.462 → 1.1.463

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 (167) hide show
  1. package/install.js +134 -0
  2. package/package.json +20 -4
  3. package/packages/BnAddress/index.vue +141 -0
  4. package/packages/BnAddressParse/index.vue +75 -0
  5. package/packages/BnAdvancedFilter/BnFilterView.vue +145 -0
  6. package/packages/BnAdvancedFilter/index.vue +345 -0
  7. package/packages/BnAdvancedFilter/util.js +171 -0
  8. package/packages/BnCascader/BnCascader.vue +543 -0
  9. package/packages/BnCascader/BnCascaderPanel.vue +1331 -0
  10. package/packages/BnCascader/cascaderDisplay.js +102 -0
  11. package/packages/BnCheck/BnCheck.vue +253 -0
  12. package/packages/BnColumnConfig/columnConfigDialog.vue +134 -0
  13. package/packages/BnColumnConfig/component/childrenFormSetting/assocTable.vue +143 -0
  14. package/packages/BnColumnConfig/component/childrenFormSetting/assocTableSearch.vue +314 -0
  15. package/packages/BnColumnConfig/component/childrenFormSetting/index.vue +243 -0
  16. package/packages/BnColumnConfig/component/defaultSet/defaultSet.vue +114 -0
  17. package/packages/BnColumnConfig/component/defaultSet/stringDefault.vue +210 -0
  18. package/packages/BnColumnConfig/component/funcExprDialog/funcExprDialog.vue +126 -0
  19. package/packages/BnColumnConfig/component/packageFilter/index.vue +141 -0
  20. package/packages/BnColumnConfig/component/paraExplainSet/index.vue +156 -0
  21. package/packages/BnColumnConfig/component/setOption/setOption.vue +321 -0
  22. package/packages/BnColumnConfig/component/setRelationOption/ConditionList.vue +277 -0
  23. package/packages/BnColumnConfig/component/setRelationOption/LevelHeader.vue +144 -0
  24. package/packages/BnColumnConfig/component/setRelationOption/setRelationOption.vue +642 -0
  25. package/packages/BnColumnConfig/data.js +129 -0
  26. package/packages/BnColumnConfig/index.scss +23 -0
  27. package/packages/BnColumnConfig/index.vue +309 -0
  28. package/packages/BnCondVal/BnCondVal.vue +112 -0
  29. package/packages/BnCondVal/itemVal/dateRegVal.vue +39 -0
  30. package/packages/BnCondVal/itemVal/dateVal.vue +39 -0
  31. package/packages/BnCondVal/itemVal/numRegVal.vue +67 -0
  32. package/packages/BnCondVal/itemVal/numVal.vue +44 -0
  33. package/packages/BnCondVal/itemVal/relationVal.vue +73 -0
  34. package/packages/BnCondVal/itemVal/selectColumnVal.vue +58 -0
  35. package/packages/BnCondVal/itemVal/selectVal.vue +59 -0
  36. package/packages/BnCondVal/itemVal/stringVal.vue +156 -0
  37. package/packages/BnCondition/index.vue +551 -0
  38. package/packages/BnCondition/util.js +232 -0
  39. package/packages/BnDatePicker/BnDatePicker.vue +194 -0
  40. package/packages/BnDrop/BnDrop.vue +917 -0
  41. package/packages/BnEmptyTip/BnEmptyTip.vue +107 -0
  42. package/packages/BnExportOrder/BnExportOrder.vue +241 -0
  43. package/packages/BnExportOrder/validatorCode.vue +94 -0
  44. package/packages/BnFileView/BnFileView.vue +271 -0
  45. package/packages/BnFileView/FileDetail.vue +125 -0
  46. package/packages/BnFileView/videoPreview.vue +70 -0
  47. package/packages/BnFilterOption/BnFilterOption.vue +160 -0
  48. package/packages/BnFunExpr/BnFunExpr.vue +608 -0
  49. package/packages/BnImportOrder/BnImportOrder.vue +323 -0
  50. package/packages/BnImportTemplate/BnImportTemplate.vue +866 -0
  51. package/packages/BnImportTemplate/assets/merge_tip_img.png +0 -0
  52. package/packages/BnImportTemplate/assets/sheet_tip.png +0 -0
  53. package/packages/BnImportTemplate/assets/xls.png +0 -0
  54. package/packages/BnImportTemplate/components/ImportTemplateTrigger.vue +198 -0
  55. package/packages/BnImportTemplate/components/TemplateEditDialog.vue +340 -0
  56. package/packages/BnImportTemplate/components/TemplateFieldsConfig.vue +401 -0
  57. package/packages/BnImportTemplate/components/TemplateListDialog.vue +297 -0
  58. package/packages/BnInpNum/BnInpNum.vue +165 -0
  59. package/packages/BnMenus/BnMenus.vue +502 -0
  60. package/packages/BnMenus/MenuItem.vue +321 -0
  61. package/packages/BnOrderCard/BnOrderCard.vue +389 -0
  62. package/packages/BnOrderCard/orderRemark.vue +178 -0
  63. package/packages/BnOrderCard/util.js +94 -0
  64. package/packages/BnOrderDetail/BnOrderDetail.vue +338 -0
  65. package/packages/BnOrderDetail/filterLogByUser.vue +108 -0
  66. package/packages/BnOrderDetail/orderLogs.vue +53 -0
  67. package/packages/BnOrderDetail/showSubForm/index.vue +41 -0
  68. package/packages/BnOrderDetail/showSubForm/showChildTable.vue +61 -0
  69. package/packages/BnOrderDetail/showSubForm/showTimeLine.vue +131 -0
  70. package/packages/BnOrderDetail/showSubForm/tableCellCopy.vue +84 -0
  71. package/packages/BnOrderShare/index.vue +378 -0
  72. package/packages/BnOrderShare/shareUrlInp.vue +54 -0
  73. package/packages/BnRadio/BnRadio.vue +181 -0
  74. package/packages/BnRelation/BnRelation.vue +120 -0
  75. package/packages/BnSelect/BnSelect.vue +485 -0
  76. package/packages/BnSmartForm/BnBatchForm.vue +334 -0
  77. package/packages/BnSmartForm/BnBatchFormDialog.vue +423 -0
  78. package/packages/BnSmartForm/BnSmartElf/elfLog/index.vue +57 -0
  79. package/packages/BnSmartForm/BnSmartElf/index.vue +95 -0
  80. package/packages/BnSmartForm/BnSmartFormPsychic.js +629 -0
  81. package/packages/BnSmartForm/BnSmartFormUtil.js +524 -0
  82. package/packages/BnSmartForm/addressForm/index.vue +73 -0
  83. package/packages/BnSmartForm/checkboxForm/index.vue +99 -0
  84. package/packages/BnSmartForm/childrenForm/childFormFile.vue +237 -0
  85. package/packages/BnSmartForm/childrenForm/childrenFormBody.vue +260 -0
  86. package/packages/BnSmartForm/childrenForm/index.vue +110 -0
  87. package/packages/BnSmartForm/childrenForm/searchInventory.vue +115 -0
  88. package/packages/BnSmartForm/chooseAssocTable/chooseAssocTable.vue +451 -0
  89. package/packages/BnSmartForm/chooseAssocTable/chooseChildGood.vue +229 -0
  90. package/packages/BnSmartForm/chooseAssocTable/tableCellCopy.vue +84 -0
  91. package/packages/BnSmartForm/chooseChildOrder/chooseChildOrder.vue +158 -0
  92. package/packages/BnSmartForm/chooseIPaasData/chooseIPaasData.vue +307 -0
  93. package/packages/BnSmartForm/chooseIPaasData/tableCellCopy.vue +84 -0
  94. package/packages/BnSmartForm/choosePackage/choosePackage.vue +361 -0
  95. package/packages/BnSmartForm/dateDualForm/index.vue +37 -0
  96. package/packages/BnSmartForm/dateForm/index.vue +38 -0
  97. package/packages/BnSmartForm/fileForm/fileFormData.js +50 -0
  98. package/packages/BnSmartForm/fileForm/index.vue +240 -0
  99. package/packages/BnSmartForm/formItemFooter/formItemFooter.vue +38 -0
  100. package/packages/BnSmartForm/formItemTop/formItemTop.vue +42 -0
  101. package/packages/BnSmartForm/index.vue +1201 -0
  102. package/packages/BnSmartForm/numberForm/index.vue +63 -0
  103. package/packages/BnSmartForm/radioForm/index.vue +72 -0
  104. package/packages/BnSmartForm/receiveForm/index.vue +112 -0
  105. package/packages/BnSmartForm/relationForm/index.vue +82 -0
  106. package/packages/BnSmartForm/scoreForm/index.vue +39 -0
  107. package/packages/BnSmartForm/selectForm/index.vue +55 -0
  108. package/packages/BnSmartForm/showValForm/index.vue +42 -0
  109. package/packages/BnSmartForm/showValForm/showValFormTable.vue +104 -0
  110. package/packages/BnSmartForm/smartFormsCommon.scss +43 -0
  111. package/packages/BnSmartForm/stringForm/index.vue +170 -0
  112. package/packages/BnVirtPopover/index.vue +319 -0
  113. package/packages/BnWebLog/BnWebLog.vue +140 -0
  114. package/packages/BnWorkSettingDrop/advancedOptions.js +112 -0
  115. package/packages/BnWorkSettingDrop/benBenAIUtil.js +89 -0
  116. package/packages/BnWorkSettingDrop/index.vue +292 -0
  117. package/packages/font/iconfont.css +243 -0
  118. package/packages/font/iconfont.ttf +0 -0
  119. package/packages/font/iconfont.woff +0 -0
  120. package/packages/font/iconfont.woff2 +0 -0
  121. package/utils/addressParse-old.js +645 -0
  122. package/utils/addressParse.js +735 -0
  123. package/utils/config.js +68 -0
  124. package/utils/index.js +1171 -0
  125. package/dist/assocTableSearch-CmzOXI5w.js +0 -349
  126. package/dist/assocTableSearch.css +0 -1
  127. package/dist/bn-bus-ui.es.js +0 -65
  128. package/dist/bn-bus-ui.umd.js +0 -49
  129. package/dist/chooseIPaasData-jkTJEMKT.js +0 -391
  130. package/dist/chooseIPaasData.css +0 -1
  131. package/dist/defaultSet-CiYuSOzT.js +0 -297
  132. package/dist/defaultSet.css +0 -1
  133. package/dist/fileFormData-D_Q1vylE.js +0 -53
  134. package/dist/formItemFooter-BpnVUUgV.js +0 -108
  135. package/dist/formItemFooter.css +0 -1
  136. package/dist/funcExprDialog-BMc-n5FL.js +0 -139
  137. package/dist/funcExprDialog.css +0 -1
  138. package/dist/index-8GQJARcF.js +0 -44
  139. package/dist/index-8apT0r8m.js +0 -66
  140. package/dist/index-BOFu3qAH.js +0 -183
  141. package/dist/index-BSKXuSid.js +0 -89
  142. package/dist/index-BhYvDd_Q.js +0 -45
  143. package/dist/index-BhqkeVFc.js +0 -45
  144. package/dist/index-CK7_Ou7F.js +0 -89
  145. package/dist/index-Cfb8D3Fg.js +0 -58
  146. package/dist/index-D1fGD0mX.js +0 -51
  147. package/dist/index-DE_eQGbT.js +0 -746
  148. package/dist/index-DfgiBqzS.js +0 -221
  149. package/dist/index-Dobi0ms9.js +0 -66
  150. package/dist/index-DuyQNxe0.js +0 -118
  151. package/dist/index-DxpJkrN7.js +0 -64
  152. package/dist/index-FGHeG46m.js +0 -109
  153. package/dist/index-P2M7CUTe.js +0 -178
  154. package/dist/index-xCz2zysE.js +0 -135
  155. package/dist/index.css +0 -1
  156. package/dist/index2.css +0 -1
  157. package/dist/index3.css +0 -1
  158. package/dist/index4.css +0 -1
  159. package/dist/index5.css +0 -1
  160. package/dist/index6.css +0 -1
  161. package/dist/index7.css +0 -1
  162. package/dist/install--7IU60oV.js +0 -23103
  163. package/dist/install.css +0 -1
  164. package/dist/setOption-DehYZpZr.js +0 -329
  165. package/dist/setOption.css +0 -1
  166. package/dist/setRelationOption-BL-AFUoF.js +0 -5217
  167. package/dist/setRelationOption.css +0 -1
@@ -1,746 +0,0 @@
1
- import { debounce as V } from "lodash";
2
- import { _ as U, a5 as z, a2 as P } from "./install--7IU60oV.js";
3
- import { f as $ } from "./fileFormData-D_Q1vylE.js";
4
- import { resolveComponent as d, openBlock as i, createElementBlock as p, createElementVNode as r, createVNode as h, withCtx as u, createTextVNode as y, toDisplayString as I, withDirectives as x, vShow as Y, createCommentVNode as f, resolveDirective as M, createBlock as _, Fragment as S, renderList as T } from "vue";
5
- import { a as j, f as H } from "./formItemFooter-BpnVUUgV.js";
6
- const R = {
7
- name: "childFormFile",
8
- props: {
9
- column: {
10
- type: Object,
11
- default: () => ({})
12
- },
13
- value: {
14
- type: Array,
15
- default: () => []
16
- }
17
- },
18
- data() {
19
- return {
20
- fileType: this.column.fileType || $,
21
- pasteValue: "",
22
- pasteImgList: [],
23
- //用来存放粘贴的图片
24
- // 上传进度
25
- uploadProgress: 0,
26
- uploadFileCount: 0,
27
- //记录上传次数,限制最多上传5个
28
- uploadFileNumber: 10,
29
- //可上传附件那个数
30
- showLimit: 15,
31
- //单文件最大M数
32
- uploadAction: "/v2/attachment/upload",
33
- uploadData: { source: "task" }
34
- };
35
- },
36
- methods: {
37
- /**
38
- * 上传成功
39
- * */
40
- fileSuccess(a) {
41
- if (this.column.error = "", this.uploadProgress = 0, a.code)
42
- this.$message({
43
- message: a.msg,
44
- type: "warning"
45
- });
46
- else {
47
- const e = {
48
- title: a.data.fileName,
49
- id: a.data.id,
50
- code: a.data.id,
51
- size: a.data.fileSize,
52
- type: a.data.suffix,
53
- url: a.data.url
54
- };
55
- this.value.length < this.uploadFileNumber ? (this.value.push(e), this.$emit("onChange", this.column)) : this.$message({
56
- message: `上传文件个数不能超过${this.uploadFileNumber}个`,
57
- type: "warning"
58
- }), this.uploadFileCount = this.value.length;
59
- }
60
- },
61
- /**
62
- * 附件上传前
63
- * */
64
- beforeUpload(a) {
65
- if (this.value.length >= this.uploadFileNumber)
66
- return this.$message({
67
- message: `上传文件个数不能超过${this.uploadFileNumber}个`,
68
- type: "warning"
69
- }), !1;
70
- const e = 50, t = 1048576 * e;
71
- if (a.size > t)
72
- return this.$message({
73
- message: `上传文件大小不能超出${e}MB`,
74
- type: "warning"
75
- }), !1;
76
- const m = a.name.split(".").pop().toLowerCase();
77
- return this.fileType.includes(m) ? (this.uploadFileCount++, !0) : (this.$message({
78
- message: "上传的文件格式不支持",
79
- type: "warning"
80
- }), !1);
81
- },
82
- handleUploadProgress(a) {
83
- this.uploadProgress = Math.round(a.percent);
84
- },
85
- //粘贴图片到编辑器,事件处理方法,主要用于事件销毁
86
- pasteEvent(a) {
87
- if (this.value.length >= this.uploadFileNumber)
88
- return this.$message({
89
- message: `上传文件个数不能超过${this.uploadFileNumber}个`,
90
- type: "warning"
91
- }), !1;
92
- this.column.error = "", this.pasteImgList.push(a), z(a, this.column.pathUrl || this.uploadAction).then((e) => {
93
- if (e.code)
94
- this.$message({
95
- message: e.msg,
96
- type: "warning"
97
- });
98
- else {
99
- const t = {
100
- title: e.data.fileName,
101
- id: e.data.id,
102
- code: e.data.id,
103
- size: e.data.fileSize,
104
- type: e.data.suffix,
105
- url: e.data.url
106
- };
107
- this.value.push(t), this.$emit("onChange", this.column), this.value.length >= this.uploadFileNumber && (this.pasteImgList = []);
108
- }
109
- });
110
- }
111
- },
112
- mounted() {
113
- this.$refs.fileUploadInput && this.$refs.fileUploadInput.$el && this.$refs.fileUploadInput.$el.addEventListener("paste", this.pasteEvent);
114
- },
115
- //实例销毁前
116
- beforeDestroy() {
117
- this.$refs.fileUploadInput && this.$refs.fileUploadInput.$el && this.$refs.fileUploadInput.$el.removeEventListener(
118
- "paste",
119
- this.pasteEvent
120
- );
121
- }
122
- }, J = { class: "childFormFile" }, q = { class: "" }, K = { class: "childFormFile-tip" }, W = { key: 0 };
123
- function X(a, e, t, m, c, l) {
124
- const b = d("el-upload"), v = d("el-input"), g = d("el-progress"), w = d("BnFileView");
125
- return i(), p("div", J, [
126
- r("div", q, [
127
- h(b, {
128
- class: "childFormFile-upload",
129
- ref: "uploadInput",
130
- drag: "",
131
- action: t.column.pathUrl || c.uploadAction,
132
- "show-file-list": !1,
133
- "before-upload": l.beforeUpload,
134
- multiple: "",
135
- data: c.uploadData,
136
- "on-progress": l.handleUploadProgress,
137
- "on-success": l.fileSuccess
138
- }, {
139
- default: u(() => [...e[1] || (e[1] = [
140
- r("div", { class: "childFormFile-btn" }, [
141
- r("span", { class: "bnUIcon bnUIcon-upload" }),
142
- y(" 选择或拖拽上传文件 ")
143
- ], -1)
144
- ])]),
145
- _: 1
146
- }, 8, ["action", "before-upload", "data", "on-progress", "on-success"]),
147
- h(v, {
148
- modelValue: c.pasteValue,
149
- "onUpdate:modelValue": e[0] || (e[0] = (F) => c.pasteValue = F),
150
- ref: "fileUploadInput",
151
- placeholder: "复制粘贴上传截图",
152
- class: "childFormFile-input"
153
- }, null, 8, ["modelValue"]),
154
- r("span", K, "最多可上传" + I(c.uploadFileNumber) + "个文件,单个文件不超过" + I(c.showLimit) + "M", 1)
155
- ]),
156
- x(h(g, {
157
- style: { width: "100%", "max-width": "444px" },
158
- percentage: c.uploadProgress,
159
- class: "childFormFile-progress"
160
- }, null, 8, ["percentage"]), [
161
- [Y, c.uploadProgress > 0]
162
- ]),
163
- t.value ? (i(), p("div", W, [
164
- h(w, {
165
- "file-list": t.value,
166
- isDel: !0,
167
- "is-mini": !0
168
- }, null, 8, ["file-list"])
169
- ])) : f("", !0)
170
- ]);
171
- }
172
- const G = /* @__PURE__ */ U(R, [["render", X], ["__scopeId", "data-v-a1b3b6de"]]), Q = {
173
- name: "searchInventory",
174
- props: {
175
- row: {},
176
- column: {},
177
- postFunc: Function
178
- },
179
- data() {
180
- return {
181
- loading: !1,
182
- // 关联查库存的字段的值
183
- stockSearch: "",
184
- headData: [],
185
- inventoryData: []
186
- };
187
- },
188
- beforeCreate() {
189
- this.searchData = V(function(a) {
190
- this.loading || (this.headData = [], this.inventoryData = [], this.loading = !0, this.postFunc("/v2/elcStock/getStockInfoV2", a).then((e) => {
191
- if (this.loading = !1, !e.code && e.data) {
192
- this.headData = e.data.arrayData[0], this.inventoryData = e.data.data;
193
- const t = this.calculateTotalStock(this.inventoryData);
194
- this.row[this.column.columnCode] = t;
195
- } else
196
- this.row[this.column.columnCode] = "";
197
- }));
198
- }, 500);
199
- },
200
- watch: {
201
- // 只监听用于查询的特定字段,避免被自己修改的总库存字段触发
202
- row: {
203
- handler(a) {
204
- var m;
205
- const e = (m = this.column.extraInfo) == null ? void 0 : m.stockSearchColumnCode;
206
- if (!e) return;
207
- const t = a[e];
208
- if (this.stockSearch !== t) {
209
- this.stockSearch = t;
210
- let c = {
211
- [e]: this.stockSearch
212
- };
213
- this.searchData(c);
214
- }
215
- },
216
- deep: !0,
217
- immediate: !0
218
- }
219
- },
220
- methods: {
221
- /**
222
- * 遍历数组并计算可发库存总和的方法
223
- * @param {Array} arr - 要遍历的数组,格式如:[{可发库存:10.0000}, {可发库存:10.00}]
224
- * @returns {Number} 总和
225
- */
226
- calculateTotalStock(a) {
227
- return !a || !Array.isArray(a) || a.length === 0 ? 0 : a.reduce((e, t) => {
228
- const m = parseFloat(t.可发库存 || 0);
229
- return e + (isNaN(m) ? 0 : m);
230
- }, 0);
231
- }
232
- }
233
- }, Z = { class: "inventory" };
234
- function ee(a, e, t, m, c, l) {
235
- const b = d("vxe-column"), v = d("vxe-table"), g = M("loading");
236
- return x((i(), p("div", Z, [
237
- x((i(), _(v, {
238
- ref: "assocTable",
239
- border: "",
240
- size: "small",
241
- data: c.inventoryData,
242
- "row-config": { keyField: "id", isCurrent: !0, isHover: !0 },
243
- "max-height": 360,
244
- "min-height": "50",
245
- "expand-config": { expandAll: !0 },
246
- "column-config": { resizable: !0 },
247
- "scroll-x": { enabled: !0, gt: 8 },
248
- "scroll-y": { enabled: !0, gt: 15 }
249
- }, {
250
- empty: u(() => [...e[0] || (e[0] = [
251
- r("span", null, "未查到库存数据", -1)
252
- ])]),
253
- default: u(() => [
254
- (i(!0), p(S, null, T(c.headData, (w, F) => (i(), _(b, {
255
- title: w,
256
- field: w,
257
- "min-width": "100",
258
- key: F,
259
- "show-header-overflow": "title",
260
- "show-overflow": "title",
261
- "show-footer-overflow": ""
262
- }, null, 8, ["title", "field"]))), 128))
263
- ]),
264
- _: 1
265
- }, 8, ["data"])), [
266
- [g, c.loading]
267
- ])
268
- ])), [
269
- [g, c.loading]
270
- ]);
271
- }
272
- const te = /* @__PURE__ */ U(Q, [["render", ee], ["__scopeId", "data-v-7c5817ba"]]), oe = {
273
- name: "editLabel",
274
- components: { childFormFile: G, searchInventory: te },
275
- props: {
276
- sourceData: {
277
- type: Object,
278
- default: function() {
279
- return {};
280
- }
281
- },
282
- // 默认值映射相关规则
283
- defaultLink: Object,
284
- componentList: Array,
285
- taskId: [String, Number],
286
- disabled: Boolean,
287
- postFunc: Function
288
- },
289
- methods: {
290
- /**
291
- * 根据权限判断是否限制组件
292
- * */
293
- isShow(a) {
294
- let e = !0;
295
- return (!this.taskId && a.extraInfo.isAddable != 1 || this.taskId && a.extraInfo.isEditable != 1) && (e = !1), e;
296
- },
297
- /**
298
- * 根据权限判断是否禁用组件
299
- * */
300
- isDisabled(a) {
301
- let e = !1;
302
- return (!this.taskId && a.extraInfo.valueAddable == 1 || this.taskId && a.extraInfo.valueEditable == 1) && (e = !0), e;
303
- },
304
- /**
305
- * 向表格内插入数据
306
- * */
307
- addDefault(a) {
308
- if (this.sourceData.value.length >= 30)
309
- return this.$message.warning("最多支持30条"), !1;
310
- let e = {};
311
- this.sourceData.moduleDefinition.forEach((m) => {
312
- var c;
313
- m.behaviorType == 1 && ((c = this.defaultLink) != null && c.setColumn[`${this.sourceData.columnCode}.${m.columnCode}`]) ? e[m.columnCode] = P(this.componentList, this.defaultLink.setColumn[`${this.sourceData.columnCode}.${m.columnCode}`]) : e[m.columnCode] = m.value;
314
- });
315
- let t = JSON.parse(JSON.stringify(e));
316
- a ? this.sourceData.value.splice(a, 0, t) : this.sourceData.value.push(t), this.onChange("addRow", { row: t }, null);
317
- },
318
- /**
319
- * 删除数据
320
- * */
321
- delItem(a) {
322
- this.sourceData.value.splice(a, 1), this.onChange("delRow", { delIndx: a }, null);
323
- },
324
- /**
325
- * 输入框Change事件
326
- * @param {String} type 是否是其他事件类型
327
- * @param {Object} params 扩展参数
328
- * */
329
- onChange: V(function(a, e, t) {
330
- this.sourceData.error = "", this.sourceData.warning = "", this.$emit("onChange", this.sourceData, { type: a, tableScope: e, childColumn: t });
331
- }, 500),
332
- /**
333
- * 输入框输入事件
334
- * @param {Object} params 扩展参数
335
- * */
336
- onInput(a, e, t) {
337
- this.$emit("input", this.sourceData, { tableScope: e, childColumn: t }), this.onChange("input", e, t);
338
- },
339
- /**
340
- * 输入框onFocus事件
341
- * @param {Object} params 表格组件行数据
342
- * @param {Object} column 子组件
343
- * */
344
- onFocus(a, e, t) {
345
- this.$emit("focus", this.sourceData, { tableScope: e, childColumn: t });
346
- },
347
- /**
348
- * 输入框失去焦点事件
349
- * @param {Object} params 扩展参数
350
- * */
351
- onBlur(a, e, t) {
352
- this.$emit("blur", this.sourceData, { tableScope: e, childColumn: t });
353
- }
354
- }
355
- }, ae = { class: "w-default-wrap" }, le = { class: "w-flex-center" }, ne = {
356
- key: 0,
357
- class: "w-color-red w-margin-right4"
358
- }, ie = { class: "w-flex-left" }, se = {
359
- key: 0,
360
- class: "childFormBody-td"
361
- }, re = {
362
- key: 1,
363
- class: "childFormBody-td"
364
- }, de = {
365
- key: 2,
366
- class: "childFormBody-td"
367
- }, ue = {
368
- key: 3,
369
- class: "childFormBody-td"
370
- }, ce = {
371
- key: 4,
372
- class: "childFormBody-td"
373
- }, he = {
374
- key: 5,
375
- class: "childFormBody-file"
376
- }, me = {
377
- key: 0,
378
- class: "childFormBody-file-view"
379
- }, pe = { class: "childFormBody-operate" }, fe = { class: "w-flex-center" }, ge = ["onClick"], be = ["onClick"];
380
- function ve(a, e, t, m, c, l) {
381
- const b = d("vxe-column"), v = d("el-input"), g = d("BnInpNum"), w = d("BnSelect"), F = d("BnCascader"), k = d("el-date-picker"), D = d("child-form-file"), C = d("el-popover"), E = d("BnFileView"), A = d("searchInventory"), O = d("vxe-table");
382
- return i(), p("div", ae, [
383
- h(O, {
384
- border: "",
385
- size: "small",
386
- data: t.sourceData.value,
387
- "max-height": 360
388
- }, {
389
- empty: u(() => [
390
- r("span", null, [
391
- e[4] || (e[4] = y("暂无数据 ", -1)),
392
- t.disabled ? f("", !0) : (i(), p("span", {
393
- key: 0,
394
- class: "w-color-blue w-cursor-pointer",
395
- onClick: e[0] || (e[0] = (o) => l.addDefault(0))
396
- }, "点击添加"))
397
- ])
398
- ]),
399
- default: u(() => [
400
- h(b, {
401
- type: "seq",
402
- width: "50"
403
- }),
404
- (i(!0), p(S, null, T(t.sourceData.moduleDefinition, (o, B) => (i(), p(S, { key: B }, [
405
- l.isShow(o) ? (i(), _(b, {
406
- key: 0,
407
- title: o.name,
408
- params: o.extraInfo || {},
409
- "min-width": 240,
410
- "show-header-overflow": "title"
411
- }, {
412
- header: u((n) => [
413
- r("div", le, [
414
- n.column.params.valueEmptyCheck == 1 ? (i(), p("span", ne, "*")) : f("", !0),
415
- r("span", null, I(n.column.title), 1)
416
- ])
417
- ]),
418
- default: u((n) => {
419
- var L, N;
420
- return [
421
- r("div", ie, [
422
- o.behaviorType == 1 ? (i(), p("div", se, [
423
- h(v, {
424
- type: "textarea",
425
- resize: "none",
426
- rows: 1,
427
- placeholder: "请输入",
428
- disabled: t.disabled || l.isDisabled(o),
429
- onInput: (s) => l.onInput(s, n, o),
430
- onFocus: (s) => l.onFocus(s, n, o),
431
- onBlur: (s) => l.onBlur(s, n, o),
432
- maxlength: 2e5,
433
- modelValue: n.row[o.columnCode],
434
- "onUpdate:modelValue": (s) => n.row[o.columnCode] = s,
435
- modelModifiers: { trim: !0 }
436
- }, null, 8, ["disabled", "onInput", "onFocus", "onBlur", "modelValue", "onUpdate:modelValue"])
437
- ])) : f("", !0),
438
- o.behaviorType == 2 ? (i(), p("div", re, [
439
- h(g, {
440
- onInput: (s) => l.onInput(s, n, o),
441
- disabled: t.disabled || l.isDisabled(o),
442
- onFocus: (s) => l.onFocus(s, n, o),
443
- onBlur: (s) => l.onBlur(s, n, o),
444
- precision: (L = o.extraInfo) == null ? void 0 : L.valueType,
445
- modelValue: n.row[o.columnCode],
446
- "onUpdate:modelValue": (s) => n.row[o.columnCode] = s,
447
- placeholder: "请输入有效数值"
448
- }, null, 8, ["onInput", "disabled", "onFocus", "onBlur", "precision", "modelValue", "onUpdate:modelValue"])
449
- ])) : f("", !0),
450
- [3, 4, 5].includes(o.behaviorType) ? (i(), p("div", de, [
451
- h(w, {
452
- modelValue: n.row[o.columnCode],
453
- "onUpdate:modelValue": (s) => n.row[o.columnCode] = s,
454
- clearable: "",
455
- filterable: "",
456
- multiple: o.behaviorType == 5,
457
- optionProps: { value: "code", label: "title" },
458
- options: o.moduleDefinition,
459
- disabled: t.disabled || l.isDisabled(o),
460
- pathUrl: o.pathUrl,
461
- postData: o.postData,
462
- postFunc: t.postFunc,
463
- onChange: (s) => l.onChange("change", n, o)
464
- }, null, 8, ["modelValue", "onUpdate:modelValue", "multiple", "options", "disabled", "pathUrl", "postData", "postFunc", "onChange"])
465
- ])) : f("", !0),
466
- [6, 20].includes(o.behaviorType) ? (i(), p("div", ue, [
467
- h(F, {
468
- onChange: (s) => l.onChange("change", n, o),
469
- modelValue: n.row[o.columnCode],
470
- "onUpdate:modelValue": (s) => n.row[o.columnCode] = s,
471
- postFunc: t.postFunc,
472
- "path-url": o.pathUrl,
473
- "post-data": o.postData,
474
- "remote-mode": "tree",
475
- optionProps: { value: "code", label: "title" },
476
- "label-in-value": !1,
477
- options: o.moduleDefinition.optionList,
478
- "hide-check-to-last": "",
479
- multiple: o.behaviorType == 20,
480
- disabled: t.disabled || l.isDisabled(o),
481
- clearable: ""
482
- }, null, 8, ["onChange", "modelValue", "onUpdate:modelValue", "postFunc", "path-url", "post-data", "options", "multiple", "disabled"])
483
- ])) : f("", !0),
484
- o.behaviorType == 7 ? (i(), p("div", ce, [
485
- h(k, {
486
- onChange: (s) => l.onChange("change", n, o),
487
- disabled: t.disabled || l.isDisabled(o),
488
- modelValue: n.row[o.columnCode],
489
- "onUpdate:modelValue": (s) => n.row[o.columnCode] = s,
490
- type: "datetime",
491
- format: "YYYY-MM-DD HH:mm:ss",
492
- "value-format": "YYYY-MM-DD HH:mm:ss"
493
- }, null, 8, ["onChange", "disabled", "modelValue", "onUpdate:modelValue"])
494
- ])) : f("", !0),
495
- o.behaviorType == 10 ? (i(), p("div", he, [
496
- h(C, {
497
- placement: "top",
498
- title: "附件上传",
499
- width: 400,
500
- trigger: "click"
501
- }, {
502
- reference: u(() => [...e[2] || (e[2] = [
503
- r("span", { class: "bnUIcon bnUIcon-addFile childFormBody-file-icon" }, null, -1)
504
- ])]),
505
- default: u(() => [
506
- h(D, {
507
- column: o,
508
- value: n.row[o.columnCode],
509
- onChange: (s) => l.onChange("change", n, o)
510
- }, null, 8, ["column", "value", "onChange"])
511
- ]),
512
- _: 2
513
- }, 1024),
514
- n.row[o.columnCode] ? (i(), p("div", me, [
515
- h(E, {
516
- "file-list": n.row[o.columnCode],
517
- "is-mini": !0,
518
- isDel: !0,
519
- "no-warp": !0,
520
- onDelFile: (s) => l.onChange("change", n, o)
521
- }, null, 8, ["file-list", "onDelFile"])
522
- ])) : f("", !0)
523
- ])) : f("", !0),
524
- r("div", pe, [
525
- (N = o.extraInfo) != null && N.stockSearchColumnCode ? (i(), _(C, {
526
- key: 0,
527
- placement: "bottom",
528
- width: "480"
529
- }, {
530
- reference: u(() => [...e[3] || (e[3] = [
531
- r("span", {
532
- class: "bnUIcon bnUIcon-inventory w-color-orange w-default-hover w-margin-left4",
533
- title: "点击查库存"
534
- }, null, -1)
535
- ])]),
536
- default: u(() => [
537
- (i(), _(A, {
538
- key: n.row._X_ROW_KEY,
539
- postFunc: t.postFunc,
540
- column: o,
541
- row: n.row
542
- }, null, 8, ["postFunc", "column", "row"]))
543
- ]),
544
- _: 2
545
- }, 1024)) : f("", !0)
546
- ])
547
- ])
548
- ];
549
- }),
550
- _: 2
551
- }, 1032, ["title", "params"])) : f("", !0)
552
- ], 64))), 128)),
553
- t.disabled ? f("", !0) : (i(), _(b, {
554
- key: 0,
555
- fixed: "right",
556
- width: "52"
557
- }, {
558
- header: u(({ column: o }) => [
559
- r("div", fe, [
560
- t.sourceData.value.length > 0 ? (i(), p("span", {
561
- key: 0,
562
- class: "bnUIcon bnUIcon-clear w-color-red w-font-max w-cursor-pointer",
563
- title: "点击清空子表单",
564
- onClick: e[1] || (e[1] = (B) => t.sourceData.value = [])
565
- })) : f("", !0)
566
- ])
567
- ]),
568
- default: u((o) => [
569
- r("span", {
570
- class: "bnUIcon bnUIcon-add w-color-blue w-cursor-pointer w-font-max w-margin-right5",
571
- onClick: (B) => l.addDefault(o.rowIndex + 1)
572
- }, null, 8, ge),
573
- r("span", {
574
- class: "bnUIcon bnUIcon-delete w-color-red w-font-max w-cursor-pointer",
575
- onClick: (B) => l.delItem(o.rowIndex)
576
- }, null, 8, be)
577
- ]),
578
- _: 1
579
- }))
580
- ]),
581
- _: 1
582
- }, 8, ["data"])
583
- ]);
584
- }
585
- const _e = /* @__PURE__ */ U(oe, [["render", ve], ["__scopeId", "data-v-30ec2afe"]]), we = {
586
- name: "childrenForm",
587
- components: { formItemFooter: H, formItemTop: j, childrenFormBody: _e },
588
- props: {
589
- column: {
590
- type: Object,
591
- default() {
592
- return {};
593
- }
594
- },
595
- dataBack: Object,
596
- // 默认值映射相关规则
597
- defaultLink: Object,
598
- componentList: Array,
599
- disabled: Boolean,
600
- taskId: [String, Number],
601
- postFunc: Function
602
- },
603
- methods: {
604
- /**
605
- * Change事件
606
- * params:子表单需要增加更多参数,用来表示是自己那个子组件,发生的什么变化
607
- * */
608
- onChange: V(function(a, e) {
609
- this.$emit("onChange", this.column, e);
610
- }, 500),
611
- /**
612
- * 输入框输入事件
613
- * */
614
- onInput(a, e) {
615
- this.$emit("input", this.column, e);
616
- },
617
- /**
618
- * 输入框onFocus事件
619
- * */
620
- onFocus(a, e) {
621
- this.$emit("focus", this.column, e);
622
- },
623
- /**
624
- * 输入框失去焦点事件
625
- * */
626
- onBlur(a, e) {
627
- this.$emit("blur", this.column, e);
628
- }
629
- }
630
- }, ye = { class: "w-default-wrap childrenForm" }, Fe = { class: "childrenForm-behavior" }, Ce = { class: "w-flex-center w-margin-bottom6" };
631
- function Ie(a, e, t, m, c, l) {
632
- var k, D;
633
- const b = d("formItemTop"), v = d("el-button"), g = d("el-popover"), w = d("childrenFormBody"), F = d("formItemFooter");
634
- return i(), p("div", ye, [
635
- h(b, { column: t.column }, null, 8, ["column"]),
636
- r("div", Fe, [
637
- r("div", Ce, [
638
- t.dataBack && t.dataBack.order == t.column.columnCode ? (i(), _(g, {
639
- key: 0,
640
- placement: "top-start",
641
- width: 400,
642
- trigger: "hover",
643
- "show-arrow": !1
644
- }, {
645
- reference: u(() => [
646
- h(v, {
647
- link: "",
648
- type: "primary",
649
- style: { "padding-left": "0" },
650
- onClick: e[0] || (e[0] = (C) => a.$emit("operate", this.column, "chooseChildOrder"))
651
- }, {
652
- default: u(() => [...e[3] || (e[3] = [
653
- r("span", { class: "bnUIcon bnUIcon-split" }, null, -1),
654
- y(" 请选择 ", -1)
655
- ])]),
656
- _: 1
657
- })
658
- ]),
659
- default: u(() => [
660
- e[4] || (e[4] = r("div", { class: "BnSmartForm-title-tip" }, [
661
- r("span", { class: "w-color-blue" }, "标准ERP子组件"),
662
- y(",会将选中包裹的子表合并然后在这里列举 ")
663
- ], -1))
664
- ]),
665
- _: 1
666
- })) : f("", !0),
667
- (k = t.column.insideDataSourceInfo) != null && k.tableCode ? (i(), _(g, {
668
- key: 1,
669
- placement: "top-start",
670
- width: 440,
671
- trigger: "hover",
672
- "show-arrow": !1
673
- }, {
674
- reference: u(() => [
675
- h(v, {
676
- link: "",
677
- type: "primary",
678
- style: { "padding-left": "0" },
679
- onClick: e[1] || (e[1] = (C) => a.$emit("operate", this.column, "chooseAssocTable"))
680
- }, {
681
- default: u(() => [
682
- e[5] || (e[5] = r("span", { class: "bnUIcon bnUIcon-linkTable" }, null, -1)),
683
- y("筛选" + I(t.column.name), 1)
684
- ]),
685
- _: 1
686
- })
687
- ]),
688
- default: u(() => [
689
- e[6] || (e[6] = r("div", { class: "BnSmartForm-title-tip" }, [
690
- r("span", { class: "w-color-blue" }, "关联表组件"),
691
- y(",可以通过筛选条件,筛选外部表数据进行选择回填 ")
692
- ], -1))
693
- ]),
694
- _: 1
695
- })) : f("", !0),
696
- ((D = t.column.outDataSourceInfo[0]) == null ? void 0 : D.platform) == "relation_ipaas" ? (i(), _(g, {
697
- key: 2,
698
- placement: "top-start",
699
- width: 440,
700
- trigger: "hover",
701
- "show-arrow": !1
702
- }, {
703
- reference: u(() => [
704
- h(v, {
705
- link: "",
706
- type: "primary",
707
- style: { "padding-left": "0" },
708
- onClick: e[2] || (e[2] = (C) => a.$emit("operate", this.column, "chooseIPaasData"))
709
- }, {
710
- default: u(() => [
711
- e[7] || (e[7] = r("span", { class: "bnUIcon bnUIcon-api" }, null, -1)),
712
- y("查询" + I(t.column.name), 1)
713
- ]),
714
- _: 1
715
- })
716
- ]),
717
- default: u(() => [
718
- e[8] || (e[8] = r("div", { class: "BnSmartForm-title-tip" }, [
719
- r("span", { class: "w-color-blue" }, "关联ipaas查询数据"),
720
- y(",可以通过班牛ipaas接口筛选外部数据,进行选择回填 ")
721
- ], -1))
722
- ]),
723
- _: 1
724
- })) : f("", !0)
725
- ]),
726
- h(w, {
727
- sourceData: t.column,
728
- ref: "childrenFormBody",
729
- disabled: t.disabled,
730
- taskId: t.taskId,
731
- defaultLink: t.defaultLink,
732
- componentList: t.componentList,
733
- postFunc: t.postFunc,
734
- onInput: l.onInput,
735
- onOnChange: l.onChange,
736
- onFocus: l.onFocus,
737
- onBlur: l.onBlur
738
- }, null, 8, ["sourceData", "disabled", "taskId", "defaultLink", "componentList", "postFunc", "onInput", "onOnChange", "onFocus", "onBlur"])
739
- ]),
740
- h(F, { column: t.column }, null, 8, ["column"])
741
- ]);
742
- }
743
- const Se = /* @__PURE__ */ U(we, [["render", Ie]]);
744
- export {
745
- Se as default
746
- };