@bit-sun/business-component 4.0.11-alpha.1 → 4.0.11-alpha.10
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/.umirc.ts +10 -6
- package/dist/components/Business/SearchSelect/BusinessUtils.d.ts +2 -1
- package/dist/components/Functional/SearchSelect/utils.d.ts +7 -0
- package/dist/index.esm.js +1590 -987
- package/dist/index.js +1589 -986
- package/package.json +1 -1
- package/src/assets/copyImg.svg +16 -0
- package/src/assets/zhankaitiaojian-icon.svg +18 -0
- package/src/components/Business/BsLayouts/index.tsx +17 -0
- package/src/components/Business/BsSulaQueryTable/index.tsx +17 -15
- package/src/components/Business/BsSulaQueryTable/utils.tsx +1 -1
- package/src/components/Business/DetailPageWrapper/index.less +1 -2
- package/src/components/Business/SearchSelect/BusinessUtils.tsx +774 -160
- package/src/components/Business/SearchSelect/index.md +180 -0
- package/src/components/Business/SearchSelect/index.tsx +2 -1
- package/src/components/Business/SearchSelect/utils.ts +4 -1
- package/src/components/Business/StateFlow/index.less +140 -124
- package/src/components/Business/StateFlow/index.tsx +3 -3
- package/src/components/Business/columnSettingTable/columnSetting.tsx +1 -1
- package/src/components/Business/columnSettingTable/index.tsx +3 -4
- package/src/components/Business/columnSettingTable/sulaSettingTable.tsx +3 -5
- package/src/components/Common/ParagraphCopier/index.tsx +2 -6
- package/src/components/Functional/QueryMutipleInput/index.less +51 -19
- package/src/components/Functional/QueryMutipleInput/index.tsx +26 -22
- package/src/components/Functional/SearchSelect/index.less +220 -74
- package/src/components/Functional/SearchSelect/index.tsx +264 -217
- package/src/components/Functional/SearchSelect/utils.ts +24 -0
- package/src/components/Solution/RuleComponent/index.js +4 -3
- package/src/components/Solution/RuleSetter/function.ts +2 -1
- package/src/styles/bsDefault.less +2 -13
- package/src/utils/TableUtils.tsx +1 -1
|
@@ -10,7 +10,9 @@ import { Image } from 'antd';
|
|
|
10
10
|
const hasDictSharingType = getDictionarySource('UC000013')?.length;
|
|
11
11
|
const sharingTypeDataList = hasDictSharingType && getDictionarySource('UC000013') || sharingType
|
|
12
12
|
|
|
13
|
-
export function commonFun (type?: string, prefixUrl: any,
|
|
13
|
+
export function commonFun (type?: string, prefixUrl: any, parentProps?:any) {
|
|
14
|
+
const { requestConfig:requestConfigProp={}, selectProps:selectConfigProps={}, modalTableProps:modalTableBusProps={}, hiddenFields=[]} = parentProps || {};
|
|
15
|
+
|
|
14
16
|
// 默认type === 'supplier' 供应商选择器
|
|
15
17
|
let requestConfig = {
|
|
16
18
|
url: `${prefixUrl.selectPrefix}/supplier`,
|
|
@@ -20,6 +22,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
20
22
|
}, // 默认参数
|
|
21
23
|
...requestConfigProp
|
|
22
24
|
}
|
|
25
|
+
let selectProps = selectConfigProps;
|
|
23
26
|
|
|
24
27
|
/*
|
|
25
28
|
* 处理 格式化下拉框数据源
|
|
@@ -52,7 +55,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
52
55
|
const formatTreeDataSource = (reData: any, position: number, changePosition: number,changeSearchForm: any,resKeyValue=['id', 'name']) => {
|
|
53
56
|
let data = reData && reData[position]?.data;
|
|
54
57
|
let disabledJudge;
|
|
55
|
-
if(Object.keys(data).length) {
|
|
58
|
+
if(data && typeof data === 'object' && !Array.isArray(data) && Object.keys(data).length > 0) {
|
|
56
59
|
data = [data];
|
|
57
60
|
disabledJudge=false
|
|
58
61
|
}
|
|
@@ -64,7 +67,6 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
64
67
|
changeSearchForm[changePosition].field.props.treeData = formatData;
|
|
65
68
|
}
|
|
66
69
|
|
|
67
|
-
|
|
68
70
|
let tableSearchForm: any [] = [];
|
|
69
71
|
let modalTableProps = {
|
|
70
72
|
modalTableTitle: '',
|
|
@@ -76,6 +78,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
76
78
|
|
|
77
79
|
// 供应商选择器
|
|
78
80
|
if(type === 'supplier') {
|
|
81
|
+
selectProps = {
|
|
82
|
+
placeholder: '输入供应商编码或名称',
|
|
83
|
+
renderTableColumns: [
|
|
84
|
+
{
|
|
85
|
+
title: '供应商编码',
|
|
86
|
+
dataIndex: 'code',
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
title: '供应商名称',
|
|
90
|
+
dataIndex: 'name',
|
|
91
|
+
},
|
|
92
|
+
],
|
|
93
|
+
...selectConfigProps,
|
|
94
|
+
}
|
|
79
95
|
tableSearchForm = [
|
|
80
96
|
{ name: 'qp-name-like', label: '供应商名称' }, // field: { type: 'input', props: { placeholder: '请输入'}}
|
|
81
97
|
{ name: 'qp-code-like', label: '供应商编码' },
|
|
@@ -147,13 +163,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
147
163
|
modalTableTitle: '选择供应商',
|
|
148
164
|
tableSearchForm,
|
|
149
165
|
tableColumns: [
|
|
166
|
+
{
|
|
167
|
+
title: '序号',
|
|
168
|
+
dataIndex: 'keyIndex',
|
|
169
|
+
defaultSort: 0,
|
|
170
|
+
},
|
|
150
171
|
{
|
|
151
172
|
title: '供应商编码',
|
|
152
173
|
dataIndex: 'code',
|
|
174
|
+
defaultSort: 1,
|
|
153
175
|
},
|
|
154
176
|
{
|
|
155
177
|
title: '供应商名称',
|
|
156
178
|
dataIndex: 'name',
|
|
179
|
+
defaultSort: 2,
|
|
157
180
|
},
|
|
158
181
|
{
|
|
159
182
|
title: '归属集团',
|
|
@@ -162,6 +185,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
162
185
|
{
|
|
163
186
|
title: '归属法人公司',
|
|
164
187
|
dataIndex: 'legalCompanyName',
|
|
188
|
+
defaultSort: 3,
|
|
165
189
|
},
|
|
166
190
|
{
|
|
167
191
|
title: '归属核算主体',
|
|
@@ -170,6 +194,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
170
194
|
{
|
|
171
195
|
title: '共享类型',
|
|
172
196
|
dataIndex: 'sharingType',
|
|
197
|
+
defaultSort: 4,
|
|
173
198
|
render: (text: number) => hasDictSharingType ? getDictionaryTextByValue('UC000013', text) : sharingType.find((i: any) => i.value === text)?.text
|
|
174
199
|
},
|
|
175
200
|
],
|
|
@@ -178,6 +203,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
178
203
|
}
|
|
179
204
|
if(type === 'supplier2') {
|
|
180
205
|
// 版本2
|
|
206
|
+
selectProps = {
|
|
207
|
+
placeholder: '输入供应商编码或名称',
|
|
208
|
+
renderTableColumns: [
|
|
209
|
+
{
|
|
210
|
+
title: '供应商编码',
|
|
211
|
+
dataIndex: 'code',
|
|
212
|
+
},
|
|
213
|
+
{
|
|
214
|
+
title: '供应商名称',
|
|
215
|
+
dataIndex: 'name',
|
|
216
|
+
},
|
|
217
|
+
],
|
|
218
|
+
...selectConfigProps,
|
|
219
|
+
}
|
|
181
220
|
tableSearchForm = [
|
|
182
221
|
{ name: 'qp-name-like', label: '供应商名称' }, // field: { type: 'input', props: { placeholder: '请输入'}}
|
|
183
222
|
{ name: 'qp-code-like', label: '供应商编码' },
|
|
@@ -222,21 +261,30 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
222
261
|
modalTableTitle: '选择供应商',
|
|
223
262
|
tableSearchForm,
|
|
224
263
|
tableColumns: [
|
|
264
|
+
{
|
|
265
|
+
title: '序号',
|
|
266
|
+
dataIndex: 'keyIndex',
|
|
267
|
+
defaultSort: 0,
|
|
268
|
+
},
|
|
225
269
|
{
|
|
226
270
|
title: '供应商编码',
|
|
227
271
|
dataIndex: 'code',
|
|
272
|
+
defaultSort: 1,
|
|
228
273
|
},
|
|
229
274
|
{
|
|
230
275
|
title: '供应商名称',
|
|
231
276
|
dataIndex: 'name',
|
|
277
|
+
defaultSort: 2,
|
|
232
278
|
},
|
|
233
279
|
{
|
|
234
280
|
title: '创建组织',
|
|
235
281
|
dataIndex: 'createOrgName',
|
|
282
|
+
defaultSort: 3,
|
|
236
283
|
},
|
|
237
284
|
{
|
|
238
285
|
title: '使用组织',
|
|
239
286
|
dataIndex: 'salesOrgName',
|
|
287
|
+
defaultSort: 4,
|
|
240
288
|
},
|
|
241
289
|
],
|
|
242
290
|
...modalTableBusProps
|
|
@@ -246,102 +294,41 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
246
294
|
// 商品选择器sku
|
|
247
295
|
if(type === 'skuCommodity') {
|
|
248
296
|
requestConfig = {
|
|
249
|
-
url: `${prefixUrl.selectPrefix}/sku/
|
|
297
|
+
url: `${prefixUrl.selectPrefix}/sku/doPageBySelect/v3`,
|
|
250
298
|
filter: 'skuCodeAndSkuName', // 过滤参数
|
|
251
299
|
mappingTextField: 'name',
|
|
252
300
|
mappingValueField: 'skuCode',
|
|
253
301
|
mappingTextShowTextField: ['name', 'propertyNameAndValue'],
|
|
254
302
|
otherParams: {
|
|
255
|
-
'qp-combination-eq': false,
|
|
256
|
-
'qp-approveStatus-eq': 1,
|
|
257
|
-
'qp-status-eq': 1,
|
|
258
303
|
// 'qp-type-eq': 10, // 查唯一国际条码【有些项目不需要必须要有国际条码,故注释,需要的项目自己定义otherParams补充上这个条件】
|
|
259
|
-
sorter: 'desc-id'
|
|
260
304
|
}, // 默认参数
|
|
261
305
|
sourceName: 'skuCode',
|
|
262
306
|
...requestConfigProp,
|
|
263
307
|
}
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
},
|
|
286
|
-
}
|
|
287
|
-
}
|
|
288
|
-
{ name: 'qp-brandId-in', type: 'select', label: '品牌', field: {
|
|
289
|
-
type: 'select',
|
|
290
|
-
props: {
|
|
291
|
-
mode: 'multiple',
|
|
292
|
-
notFoundContent: '暂无数据',
|
|
293
|
-
allowClear: true,
|
|
294
|
-
showSearch: true,
|
|
295
|
-
showArrow: true,
|
|
296
|
-
maxTagCount: 1,
|
|
297
|
-
optionFilterProp: 'children',
|
|
298
|
-
filterOption: (input: string, option: { props: { children: string } }) =>
|
|
299
|
-
option.props.children.toLowerCase().indexOf(input.toLowerCase()) >= 0,
|
|
300
|
-
},
|
|
301
|
-
} },
|
|
302
|
-
{ name: 'qp-categoryId-in', type: 'treeSelect', label: '类目', field: {
|
|
303
|
-
type: 'treeSelect',
|
|
304
|
-
props: {
|
|
305
|
-
treeData: [],
|
|
306
|
-
treeCheckable: true,
|
|
307
|
-
showSearch: true,
|
|
308
|
-
allowClear: true,
|
|
309
|
-
showArrow: true,
|
|
310
|
-
treeNodeFilterProp: 'title',
|
|
311
|
-
treeDefaultExpandAll: true,
|
|
312
|
-
maxTagCount: 1,
|
|
313
|
-
placeholder: '请选择',
|
|
314
|
-
style: {
|
|
315
|
-
width: '100%',
|
|
316
|
-
},
|
|
317
|
-
dropdownStyle: { maxHeight: 400, maxWidth: 100, overflow: 'auto' }
|
|
318
|
-
},
|
|
319
|
-
} },
|
|
320
|
-
{ name: 'qp-classId-in', type: 'select', label: '品类', field: {
|
|
321
|
-
type: 'select',
|
|
322
|
-
props: {
|
|
323
|
-
mode: 'multiple',
|
|
324
|
-
notFoundContent: '暂无数据',
|
|
325
|
-
allowClear: true,
|
|
326
|
-
showSearch: true,
|
|
327
|
-
showArrow: true,
|
|
328
|
-
maxTagCount: 1,
|
|
329
|
-
optionFilterProp: 'children',
|
|
330
|
-
filterOption: (input: string, option: { props: { children: string } }) =>
|
|
331
|
-
option.props.children.toLowerCase().indexOf(input.toLowerCase()) >= 0,
|
|
332
|
-
},
|
|
333
|
-
} },
|
|
334
|
-
] : [
|
|
335
|
-
{ name: 'qp-name-like', label: 'SKU名称' },
|
|
336
|
-
{ name: 'qp-skuCode-in', label: 'SKU编码', field: {
|
|
337
|
-
type: 'multipleQueryInput',
|
|
338
|
-
props: {
|
|
339
|
-
...(requestConfigProp?.skuCodeValueRequestConfig || {}),
|
|
340
|
-
},
|
|
341
|
-
}},
|
|
342
|
-
{ name: 'qp-barCode-like', label: '国际条码'},
|
|
343
|
-
{ name: 'qp-itemName-like', label: '所属SPU名称' },
|
|
344
|
-
{ name: 'qp-itemCode-like', label: '所属SPU编码' },
|
|
308
|
+
selectProps = {
|
|
309
|
+
placeholder: '输入sku编码或名称',
|
|
310
|
+
renderTableColumns: [
|
|
311
|
+
{
|
|
312
|
+
title: 'SKU编码',
|
|
313
|
+
dataIndex: 'skuCode',
|
|
314
|
+
},
|
|
315
|
+
{
|
|
316
|
+
title: '商品名称',
|
|
317
|
+
dataIndex: 'skuName',
|
|
318
|
+
},
|
|
319
|
+
],
|
|
320
|
+
...selectConfigProps,
|
|
321
|
+
}
|
|
322
|
+
tableSearchForm = [
|
|
323
|
+
{ name: 'qp-skuCode-in', label: 'SKU编码',type:'multipleQueryInput' },
|
|
324
|
+
{ name: 'qp-skuName-like', label: 'SKU名称' },
|
|
325
|
+
{ name: 'qp-spuCode-like', label: '外部SPU编码' },
|
|
326
|
+
{ name: 'qp-eancode-in', label: '商品条码', field: {
|
|
327
|
+
type: 'multipleQueryInput',
|
|
328
|
+
props: {
|
|
329
|
+
...(requestConfigProp?.itemEancodeValueRequestConfig || {}),
|
|
330
|
+
},
|
|
331
|
+
}},
|
|
345
332
|
{ name: 'qp-brandId-in', type: 'select', label: '品牌', field: {
|
|
346
333
|
type: 'select',
|
|
347
334
|
props: {
|
|
@@ -374,20 +361,6 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
374
361
|
dropdownStyle: { maxHeight: 400, maxWidth: 100, overflow: 'auto' }
|
|
375
362
|
},
|
|
376
363
|
} },
|
|
377
|
-
{ name: 'qp-classId-in', type: 'select', label: '品类', field: {
|
|
378
|
-
type: 'select',
|
|
379
|
-
props: {
|
|
380
|
-
mode: 'multiple',
|
|
381
|
-
notFoundContent: '暂无数据',
|
|
382
|
-
allowClear: true,
|
|
383
|
-
showSearch: true,
|
|
384
|
-
showArrow: true,
|
|
385
|
-
maxTagCount: 1,
|
|
386
|
-
optionFilterProp: 'children',
|
|
387
|
-
filterOption: (input: string, option: { props: { children: string } }) =>
|
|
388
|
-
option.props.children.toLowerCase().indexOf(input.toLowerCase()) >= 0,
|
|
389
|
-
},
|
|
390
|
-
} },
|
|
391
364
|
]
|
|
392
365
|
Promise.all([
|
|
393
366
|
loadSelectSource(`${prefixUrl.formSelectFix}/brand/queryBrandList`, {
|
|
@@ -399,35 +372,44 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
399
372
|
pageSize: 5000,
|
|
400
373
|
currentPage: 1,
|
|
401
374
|
}),
|
|
402
|
-
loadSelectSource(`${prefixUrl.formSelectFix}/class/withProperty`, {
|
|
403
|
-
pageSize: 5000,
|
|
404
|
-
currentPage: 1,
|
|
405
|
-
}),
|
|
406
375
|
]).then((x: any)=>{
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
requestConfig.url.includes('v2') ? formatSource(x,2, 9, tableSearchForm,['id','name']) : formatSource(x,2, 7, tableSearchForm,['id','name'])
|
|
376
|
+
formatSource(x,0, 4, tableSearchForm,['id','name'])
|
|
377
|
+
formatTreeDataSource(x,1, 5, tableSearchForm)
|
|
410
378
|
})
|
|
411
379
|
modalTableProps = {
|
|
412
380
|
modalTableTitle: '选择SKU',
|
|
413
381
|
tableSearchForm,
|
|
414
|
-
|
|
382
|
+
isHorizontally: true,
|
|
383
|
+
modalRadioNeedFooter: true,
|
|
384
|
+
tableColumns: [
|
|
385
|
+
{
|
|
386
|
+
title: '序号',
|
|
387
|
+
dataIndex: 'keyIndex',
|
|
388
|
+
defaultSort: 0,
|
|
389
|
+
},
|
|
415
390
|
{
|
|
416
391
|
title: 'SKU编码',
|
|
417
392
|
dataIndex: 'skuCode',
|
|
393
|
+
defaultSort: 2,
|
|
418
394
|
},
|
|
419
395
|
{
|
|
420
396
|
title: 'SKU名称',
|
|
421
|
-
dataIndex: '
|
|
397
|
+
dataIndex: 'skuName',
|
|
398
|
+
defaultSort: 3,
|
|
422
399
|
},
|
|
423
400
|
{
|
|
424
401
|
title: '图片',
|
|
425
402
|
dataIndex: 'itemUrl',
|
|
426
|
-
|
|
403
|
+
defaultSort: 1,
|
|
404
|
+
render: (text: any,record: any) => tableColumnsImage(getSkuImg(record), { width: 16, height: 16 }),
|
|
405
|
+
},
|
|
406
|
+
{
|
|
407
|
+
title: '商品条码',
|
|
408
|
+
dataIndex: 'eancode',
|
|
427
409
|
},
|
|
428
410
|
{
|
|
429
|
-
title: '
|
|
430
|
-
dataIndex: '
|
|
411
|
+
title: 'SKC编码',
|
|
412
|
+
dataIndex: 'skcCode',
|
|
431
413
|
},
|
|
432
414
|
{
|
|
433
415
|
title: '所属SPU名称',
|
|
@@ -437,50 +419,13 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
437
419
|
title: '所属SPU编码',
|
|
438
420
|
dataIndex: 'itemCode',
|
|
439
421
|
},
|
|
440
|
-
|
|
422
|
+
{
|
|
441
423
|
title: '外部编码',
|
|
442
424
|
dataIndex: 'externalCode',
|
|
443
|
-
} : false,
|
|
444
|
-
{
|
|
445
|
-
title: '规格',
|
|
446
|
-
dataIndex: requestConfig.url.includes('v2') ? 'propertyNameAndValue' : 'skuSpec',
|
|
447
|
-
},
|
|
448
|
-
{
|
|
449
|
-
title: '类目',
|
|
450
|
-
dataIndex: 'categoryName',
|
|
451
|
-
},
|
|
452
|
-
{
|
|
453
|
-
title: '品类',
|
|
454
|
-
dataIndex: 'className',
|
|
455
|
-
},
|
|
456
|
-
{
|
|
457
|
-
title: '品牌',
|
|
458
|
-
dataIndex: 'brandName',
|
|
459
|
-
},
|
|
460
|
-
] : [
|
|
461
|
-
{
|
|
462
|
-
title: 'SKU编码',
|
|
463
|
-
dataIndex: 'skuCode',
|
|
464
|
-
},
|
|
465
|
-
{
|
|
466
|
-
title: 'SKU名称',
|
|
467
|
-
dataIndex: 'name',
|
|
468
|
-
},
|
|
469
|
-
{
|
|
470
|
-
title: '国际条码',
|
|
471
|
-
dataIndex: 'barCode',
|
|
472
|
-
},
|
|
473
|
-
{
|
|
474
|
-
title: '所属SPU名称',
|
|
475
|
-
dataIndex: 'itemName',
|
|
476
|
-
},
|
|
477
|
-
{
|
|
478
|
-
title: '所属SPU编码',
|
|
479
|
-
dataIndex: 'itemCode',
|
|
480
425
|
},
|
|
481
426
|
{
|
|
482
427
|
title: '规格',
|
|
483
|
-
dataIndex: '
|
|
428
|
+
dataIndex: 'propertyNameAndValue',
|
|
484
429
|
},
|
|
485
430
|
{
|
|
486
431
|
title: '类目',
|
|
@@ -493,6 +438,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
493
438
|
{
|
|
494
439
|
title: '品牌',
|
|
495
440
|
dataIndex: 'brandName',
|
|
441
|
+
defaultSort: 4,
|
|
496
442
|
},
|
|
497
443
|
],
|
|
498
444
|
...modalTableBusProps
|
|
@@ -501,6 +447,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
501
447
|
|
|
502
448
|
// 商品选择器spu
|
|
503
449
|
if(type === 'spuCommodity') {
|
|
450
|
+
selectProps = {
|
|
451
|
+
placeholder: '输入spu编码或名称',
|
|
452
|
+
renderTableColumns: [
|
|
453
|
+
{
|
|
454
|
+
title: 'spu编码',
|
|
455
|
+
dataIndex: 'itemCode',
|
|
456
|
+
},
|
|
457
|
+
{
|
|
458
|
+
title: 'spu名称',
|
|
459
|
+
dataIndex: 'name',
|
|
460
|
+
},
|
|
461
|
+
],
|
|
462
|
+
...selectConfigProps,
|
|
463
|
+
}
|
|
504
464
|
requestConfig = {
|
|
505
465
|
url: `${prefixUrl.selectPrefix}/item`,
|
|
506
466
|
filter: 'qp-itemCode,name-orGroup,like', // 过滤参数
|
|
@@ -586,21 +546,30 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
586
546
|
modalTableTitle: '选择SPU',
|
|
587
547
|
tableSearchForm,
|
|
588
548
|
tableColumns: [
|
|
549
|
+
{
|
|
550
|
+
title: '序号',
|
|
551
|
+
dataIndex: 'keyIndex',
|
|
552
|
+
defaultSort: 0,
|
|
553
|
+
},
|
|
589
554
|
{
|
|
590
555
|
title: 'SPU编码',
|
|
591
556
|
dataIndex: 'itemCode',
|
|
557
|
+
defaultSort: 1,
|
|
592
558
|
},
|
|
593
559
|
{
|
|
594
560
|
title: 'SPU名称',
|
|
595
561
|
dataIndex: 'name',
|
|
562
|
+
defaultSort: 2,
|
|
596
563
|
},
|
|
597
564
|
{
|
|
598
565
|
title: '品牌',
|
|
599
566
|
dataIndex: 'brandName',
|
|
567
|
+
defaultSort: 3,
|
|
600
568
|
},
|
|
601
569
|
{
|
|
602
570
|
title: '类目',
|
|
603
571
|
dataIndex: 'categoryText',
|
|
572
|
+
defaultSort: 4,
|
|
604
573
|
},
|
|
605
574
|
{
|
|
606
575
|
title: '品类',
|
|
@@ -613,6 +582,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
613
582
|
|
|
614
583
|
// 商品选择器skc
|
|
615
584
|
if(type === 'skcCommodity') {
|
|
585
|
+
selectProps = {
|
|
586
|
+
placeholder: '输入SKC编码或名称',
|
|
587
|
+
renderTableColumns: [
|
|
588
|
+
{
|
|
589
|
+
title: 'SKC编码',
|
|
590
|
+
dataIndex: 'code',
|
|
591
|
+
},
|
|
592
|
+
{
|
|
593
|
+
title: 'SKC名称',
|
|
594
|
+
dataIndex: 'name',
|
|
595
|
+
},
|
|
596
|
+
],
|
|
597
|
+
...selectConfigProps,
|
|
598
|
+
}
|
|
616
599
|
const tableSearchForm = handleHiddenFields([
|
|
617
600
|
{ name: 'qp-code-like', label: 'SKC编码' },
|
|
618
601
|
{ name: 'qp-skcName-like', label: 'SKC名称' },
|
|
@@ -737,13 +720,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
737
720
|
modalTableTitle: '选择SKC',
|
|
738
721
|
tableSearchForm,
|
|
739
722
|
tableColumns: handleHiddenFields([
|
|
723
|
+
{
|
|
724
|
+
title: '序号',
|
|
725
|
+
dataIndex: 'keyIndex',
|
|
726
|
+
defaultSort: 0,
|
|
727
|
+
},
|
|
740
728
|
{
|
|
741
729
|
title: 'SKC编码',
|
|
742
730
|
dataIndex: 'code',
|
|
731
|
+
defaultSort: 1,
|
|
743
732
|
},
|
|
744
733
|
{
|
|
745
734
|
title: 'SKC名称',
|
|
746
735
|
dataIndex: 'name',
|
|
736
|
+
defaultSort: 2,
|
|
747
737
|
},
|
|
748
738
|
{
|
|
749
739
|
title: '商品名称',
|
|
@@ -752,6 +742,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
752
742
|
{
|
|
753
743
|
title: '颜色',
|
|
754
744
|
dataIndex: 'colorName',
|
|
745
|
+
defaultSort: 3,
|
|
755
746
|
},
|
|
756
747
|
{
|
|
757
748
|
title: '类目',
|
|
@@ -764,6 +755,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
764
755
|
{
|
|
765
756
|
title: '品牌',
|
|
766
757
|
dataIndex: 'brandName',
|
|
758
|
+
defaultSort: 4,
|
|
767
759
|
},
|
|
768
760
|
], hiddenFields),
|
|
769
761
|
...modalTableBusProps
|
|
@@ -772,6 +764,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
772
764
|
|
|
773
765
|
// 商品规格选择器(无弹窗)
|
|
774
766
|
if(type === 'skuPropertyValue') {
|
|
767
|
+
selectProps = {
|
|
768
|
+
placeholder: '输入规格编码或名称',
|
|
769
|
+
renderTableColumns: [
|
|
770
|
+
{
|
|
771
|
+
title: '规格编码',
|
|
772
|
+
dataIndex: 'propertyValueCode',
|
|
773
|
+
},
|
|
774
|
+
{
|
|
775
|
+
title: '规格名称',
|
|
776
|
+
dataIndex: 'propertyValueName',
|
|
777
|
+
},
|
|
778
|
+
],
|
|
779
|
+
...selectConfigProps,
|
|
780
|
+
}
|
|
775
781
|
requestConfig = {
|
|
776
782
|
url: `${prefixUrl.selectPrefix}/skuPropertyValue/list`,
|
|
777
783
|
filter: 'qp-value-like', // 过滤参数
|
|
@@ -789,6 +795,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
789
795
|
|
|
790
796
|
// 仓库选择器(物理、逻辑仓、运营仓)
|
|
791
797
|
if(type === 'physicalWarehouse') {
|
|
798
|
+
selectProps = {
|
|
799
|
+
placeholder: '输入物理仓编码或名称',
|
|
800
|
+
renderTableColumns: [
|
|
801
|
+
{
|
|
802
|
+
title: '物理仓编码',
|
|
803
|
+
dataIndex: 'physicalWarehouseCode',
|
|
804
|
+
},
|
|
805
|
+
{
|
|
806
|
+
title: '物理仓名称',
|
|
807
|
+
dataIndex: 'physicalWarehouseName',
|
|
808
|
+
},
|
|
809
|
+
],
|
|
810
|
+
...selectConfigProps,
|
|
811
|
+
}
|
|
792
812
|
requestConfig = {
|
|
793
813
|
url: `${prefixUrl.selectPrefix}/physicalWarehouse`,
|
|
794
814
|
filter: 'qp-physicalWarehouseName,physicalWarehouseCode-orGroup,like', // 过滤参数
|
|
@@ -835,17 +855,25 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
835
855
|
modalTableTitle: '选择物理仓',
|
|
836
856
|
tableSearchForm,
|
|
837
857
|
tableColumns: [
|
|
858
|
+
{
|
|
859
|
+
title: '序号',
|
|
860
|
+
dataIndex: 'keyIndex',
|
|
861
|
+
defaultSort: 0,
|
|
862
|
+
},
|
|
838
863
|
{
|
|
839
864
|
title: '物理仓编码',
|
|
840
865
|
dataIndex: 'physicalWarehouseCode',
|
|
866
|
+
defaultSort: 1,
|
|
841
867
|
},
|
|
842
868
|
{
|
|
843
869
|
title: '物理仓名称',
|
|
844
870
|
dataIndex: 'physicalWarehouseName',
|
|
871
|
+
defaultSort: 2,
|
|
845
872
|
},
|
|
846
873
|
{
|
|
847
874
|
title: '物理仓类型',
|
|
848
875
|
dataIndex: 'physicalWarehouseType',
|
|
876
|
+
defaultSort: 3,
|
|
849
877
|
render: (text: number) => getDictionaryTextByValue('SC00002', text),
|
|
850
878
|
},
|
|
851
879
|
...(modalTableBusProps?.needStatusSearch?[{
|
|
@@ -856,12 +884,27 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
856
884
|
{
|
|
857
885
|
title: '所属公司',
|
|
858
886
|
dataIndex: 'companyName',
|
|
887
|
+
defaultSort: 4,
|
|
859
888
|
},
|
|
860
889
|
],
|
|
861
890
|
...modalTableBusProps
|
|
862
891
|
}
|
|
863
892
|
}
|
|
864
893
|
if(type === 'realWarehouse') {
|
|
894
|
+
selectProps = {
|
|
895
|
+
placeholder: '输入逻辑仓编码或名称',
|
|
896
|
+
renderTableColumns: [
|
|
897
|
+
{
|
|
898
|
+
title: '逻辑仓编码',
|
|
899
|
+
dataIndex: 'realWarehouseCode',
|
|
900
|
+
},
|
|
901
|
+
{
|
|
902
|
+
title: '逻辑仓名称',
|
|
903
|
+
dataIndex: 'realWarehouseName',
|
|
904
|
+
},
|
|
905
|
+
],
|
|
906
|
+
...selectConfigProps,
|
|
907
|
+
}
|
|
865
908
|
requestConfig = {
|
|
866
909
|
url: `${prefixUrl.selectPrefix}/realWarehouse`,
|
|
867
910
|
filter: 'qp-realWarehouseName,realWarehouseCode-orGroup,like', // 过滤参数
|
|
@@ -885,22 +928,31 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
885
928
|
modalTableTitle: '选择逻辑仓',
|
|
886
929
|
tableSearchForm,
|
|
887
930
|
tableColumns: [
|
|
931
|
+
{
|
|
932
|
+
title: '序号',
|
|
933
|
+
dataIndex: 'keyIndex',
|
|
934
|
+
defaultSort: 0,
|
|
935
|
+
},
|
|
888
936
|
{
|
|
889
937
|
title: '逻辑仓编码',
|
|
890
938
|
dataIndex: 'realWarehouseCode',
|
|
939
|
+
defaultSort: 1,
|
|
891
940
|
},
|
|
892
941
|
{
|
|
893
942
|
title: '逻辑仓名称',
|
|
894
943
|
dataIndex: 'realWarehouseName',
|
|
944
|
+
defaultSort: 2,
|
|
895
945
|
},
|
|
896
946
|
{
|
|
897
947
|
title: '逻辑仓类型',
|
|
898
948
|
dataIndex: 'realWarehouseType',
|
|
949
|
+
defaultSort: 3,
|
|
899
950
|
render: (text: number) => getDictionaryTextByValue('SC00004', text),
|
|
900
951
|
},
|
|
901
952
|
...(modalTableBusProps?.needStatusSearch?[{
|
|
902
953
|
title: '状态',
|
|
903
954
|
dataIndex: 'isEnable',
|
|
955
|
+
defaultSort: 4,
|
|
904
956
|
render: (text: number) => getDictionaryTextByValue('SC00001', text),
|
|
905
957
|
}]:[]),
|
|
906
958
|
],
|
|
@@ -908,6 +960,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
908
960
|
}
|
|
909
961
|
}
|
|
910
962
|
if(type === 'ownerWarehouse') {
|
|
963
|
+
selectProps = {
|
|
964
|
+
placeholder: '输入运营仓编码或名称',
|
|
965
|
+
renderTableColumns: [
|
|
966
|
+
{
|
|
967
|
+
title: '运营仓编码',
|
|
968
|
+
dataIndex: 'operationWarehouseCode',
|
|
969
|
+
},
|
|
970
|
+
{
|
|
971
|
+
title: '运营仓名称',
|
|
972
|
+
dataIndex: 'name',
|
|
973
|
+
},
|
|
974
|
+
],
|
|
975
|
+
...selectConfigProps,
|
|
976
|
+
}
|
|
911
977
|
requestConfig = {
|
|
912
978
|
url: `${prefixUrl.selectPrefix}/ownerWarehouse`,
|
|
913
979
|
filter: 'qp-name,operationWarehouseCode-orGroup,like', // 过滤参数
|
|
@@ -949,21 +1015,30 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
949
1015
|
modalTableTitle: '选择运营仓',
|
|
950
1016
|
tableSearchForm,
|
|
951
1017
|
tableColumns: [
|
|
1018
|
+
{
|
|
1019
|
+
title: '序号',
|
|
1020
|
+
dataIndex: 'keyIndex',
|
|
1021
|
+
defaultSort: 0,
|
|
1022
|
+
},
|
|
952
1023
|
{
|
|
953
1024
|
title: '运营仓编码',
|
|
954
1025
|
dataIndex: 'operationWarehouseCode',
|
|
1026
|
+
defaultSort: 1,
|
|
955
1027
|
},
|
|
956
1028
|
{
|
|
957
1029
|
title: '运营仓名称',
|
|
958
1030
|
dataIndex: 'name',
|
|
1031
|
+
defaultSort: 2,
|
|
959
1032
|
},
|
|
960
1033
|
{
|
|
961
1034
|
title: '运营组',
|
|
962
1035
|
dataIndex: 'groupName',
|
|
1036
|
+
defaultSort: 3,
|
|
963
1037
|
},
|
|
964
1038
|
...(modalTableBusProps?.needStatusSearch?[{
|
|
965
1039
|
title: '状态',
|
|
966
1040
|
dataIndex: 'status',
|
|
1041
|
+
defaultSort: 4,
|
|
967
1042
|
render: (text: number) => getDictionaryTextByValue('SC00001', text),
|
|
968
1043
|
}]:[]),
|
|
969
1044
|
],
|
|
@@ -973,6 +1048,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
973
1048
|
|
|
974
1049
|
// 仓库选择器(虚拟、渠道仓)(无弹窗)
|
|
975
1050
|
if(type === 'virtualWarehouse') {
|
|
1051
|
+
selectProps = {
|
|
1052
|
+
placeholder: '输入虚拟仓编码或名称',
|
|
1053
|
+
renderTableColumns: [
|
|
1054
|
+
{
|
|
1055
|
+
title: '虚拟仓编码',
|
|
1056
|
+
dataIndex: 'virtualWarehouseCode',
|
|
1057
|
+
},
|
|
1058
|
+
{
|
|
1059
|
+
title: '虚拟仓名称',
|
|
1060
|
+
dataIndex: 'virtualWarehouseName',
|
|
1061
|
+
},
|
|
1062
|
+
],
|
|
1063
|
+
...selectConfigProps,
|
|
1064
|
+
}
|
|
976
1065
|
requestConfig = {
|
|
977
1066
|
url: `${prefixUrl.selectPrefix}/virtualWarehouse`,
|
|
978
1067
|
filter: 'qp-virtualWarehouseName,virtualWarehouseCode-orGroup,like', // 过滤参数
|
|
@@ -989,6 +1078,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
989
1078
|
needModalTable = false
|
|
990
1079
|
}
|
|
991
1080
|
if(type === 'channelWarehouse') {
|
|
1081
|
+
selectProps = {
|
|
1082
|
+
placeholder: '输入渠道仓编码或名称',
|
|
1083
|
+
renderTableColumns: [
|
|
1084
|
+
{
|
|
1085
|
+
title: '渠道仓编码',
|
|
1086
|
+
dataIndex: 'channelWarehouseCode',
|
|
1087
|
+
},
|
|
1088
|
+
{
|
|
1089
|
+
title: '渠道仓名称',
|
|
1090
|
+
dataIndex: 'channelWarehouseName',
|
|
1091
|
+
},
|
|
1092
|
+
],
|
|
1093
|
+
...selectConfigProps,
|
|
1094
|
+
}
|
|
992
1095
|
requestConfig = {
|
|
993
1096
|
url: `${prefixUrl.selectPrefix}/channelWarehouse`,
|
|
994
1097
|
filter: 'qp-channelWarehouseName,channelWarehouseCode-orGroup,like', // 过滤参数
|
|
@@ -1007,6 +1110,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1007
1110
|
|
|
1008
1111
|
// 客户选择器
|
|
1009
1112
|
if(type === 'customer') {
|
|
1113
|
+
selectProps = {
|
|
1114
|
+
placeholder: '输入客户编码或名称',
|
|
1115
|
+
renderTableColumns: [
|
|
1116
|
+
{
|
|
1117
|
+
title: '客户编码',
|
|
1118
|
+
dataIndex: 'code',
|
|
1119
|
+
},
|
|
1120
|
+
{
|
|
1121
|
+
title: '客户名称',
|
|
1122
|
+
dataIndex: 'name',
|
|
1123
|
+
},
|
|
1124
|
+
],
|
|
1125
|
+
...selectConfigProps,
|
|
1126
|
+
}
|
|
1010
1127
|
requestConfig = {
|
|
1011
1128
|
url: `${prefixUrl.selectPrefix}/uc/customer/v2`,
|
|
1012
1129
|
filter: 'qp-name,code-orGroup,like', // 过滤参数
|
|
@@ -1090,17 +1207,25 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1090
1207
|
modalTableTitle: '选择客户',
|
|
1091
1208
|
tableSearchForm,
|
|
1092
1209
|
tableColumns: [
|
|
1210
|
+
{
|
|
1211
|
+
title: '序号',
|
|
1212
|
+
dataIndex: 'keyIndex',
|
|
1213
|
+
defaultSort: 0,
|
|
1214
|
+
},
|
|
1093
1215
|
{
|
|
1094
1216
|
title: '客户编码',
|
|
1095
1217
|
dataIndex: 'code',
|
|
1218
|
+
defaultSort: 1,
|
|
1096
1219
|
},
|
|
1097
1220
|
{
|
|
1098
1221
|
title: '客户名称',
|
|
1099
1222
|
dataIndex: 'name',
|
|
1223
|
+
defaultSort: 2,
|
|
1100
1224
|
},
|
|
1101
1225
|
{
|
|
1102
1226
|
title: '归属集团',
|
|
1103
1227
|
dataIndex: 'conglomerateName',
|
|
1228
|
+
defaultSort: 3,
|
|
1104
1229
|
},
|
|
1105
1230
|
{
|
|
1106
1231
|
title: '归属法人公司',
|
|
@@ -1113,6 +1238,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1113
1238
|
{
|
|
1114
1239
|
title: '共享类型',
|
|
1115
1240
|
dataIndex: 'sharingType',
|
|
1241
|
+
defaultSort: 4,
|
|
1116
1242
|
render: (text: number) => hasDictSharingType ? getDictionaryTextByValue('UC000013', text) : sharingType.find((i: any) => i.value === text)?.text,
|
|
1117
1243
|
},
|
|
1118
1244
|
],
|
|
@@ -1120,6 +1246,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1120
1246
|
}
|
|
1121
1247
|
}
|
|
1122
1248
|
if(type === 'customer2') {
|
|
1249
|
+
selectProps = {
|
|
1250
|
+
placeholder: '输入客户编码或名称',
|
|
1251
|
+
renderTableColumns: [
|
|
1252
|
+
{
|
|
1253
|
+
title: '客户编码',
|
|
1254
|
+
dataIndex: 'code',
|
|
1255
|
+
},
|
|
1256
|
+
{
|
|
1257
|
+
title: '客户名称',
|
|
1258
|
+
dataIndex: 'name',
|
|
1259
|
+
},
|
|
1260
|
+
],
|
|
1261
|
+
...selectConfigProps,
|
|
1262
|
+
}
|
|
1123
1263
|
// 版本2
|
|
1124
1264
|
requestConfig = {
|
|
1125
1265
|
url: `${prefixUrl.selectPrefix}/customer`,
|
|
@@ -1178,21 +1318,30 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1178
1318
|
modalTableTitle: '选择客户',
|
|
1179
1319
|
tableSearchForm,
|
|
1180
1320
|
tableColumns: [
|
|
1321
|
+
{
|
|
1322
|
+
title: '序号',
|
|
1323
|
+
dataIndex: 'keyIndex',
|
|
1324
|
+
defaultSort: 0,
|
|
1325
|
+
},
|
|
1181
1326
|
{
|
|
1182
1327
|
title: '客户编码',
|
|
1183
1328
|
dataIndex: 'code',
|
|
1329
|
+
defaultSort: 1,
|
|
1184
1330
|
},
|
|
1185
1331
|
{
|
|
1186
1332
|
title: '客户名称',
|
|
1187
1333
|
dataIndex: 'name',
|
|
1334
|
+
defaultSort: 2,
|
|
1188
1335
|
},
|
|
1189
1336
|
{
|
|
1190
1337
|
title: '创建组织',
|
|
1191
1338
|
dataIndex: 'createOrgName',
|
|
1339
|
+
defaultSort: 3,
|
|
1192
1340
|
},
|
|
1193
1341
|
{
|
|
1194
1342
|
title: '使用组织',
|
|
1195
1343
|
dataIndex: 'salesOrgName',
|
|
1344
|
+
defaultSort: 4,
|
|
1196
1345
|
},
|
|
1197
1346
|
],
|
|
1198
1347
|
...modalTableBusProps
|
|
@@ -1201,11 +1350,25 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1201
1350
|
|
|
1202
1351
|
// 店铺选择器
|
|
1203
1352
|
if(type === 'shopFile') {
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1353
|
+
selectProps = {
|
|
1354
|
+
placeholder: '输入店铺编码或名称',
|
|
1355
|
+
renderTableColumns: [
|
|
1356
|
+
{
|
|
1357
|
+
title: '店铺编码',
|
|
1358
|
+
dataIndex: 'code',
|
|
1359
|
+
},
|
|
1360
|
+
{
|
|
1361
|
+
title: '店铺名称',
|
|
1362
|
+
dataIndex: 'name',
|
|
1363
|
+
},
|
|
1364
|
+
],
|
|
1365
|
+
...selectConfigProps,
|
|
1366
|
+
}
|
|
1367
|
+
requestConfig = {
|
|
1368
|
+
url: `${prefixUrl.selectPrefix}/store`,
|
|
1369
|
+
filter: 'qp-name,code-orGroup,like', // 过滤参数
|
|
1370
|
+
mappingTextField: 'name',
|
|
1371
|
+
mappingValueField: 'code',
|
|
1209
1372
|
otherParams: {
|
|
1210
1373
|
sorter: 'desc-id'
|
|
1211
1374
|
}, // 默认参数
|
|
@@ -1322,13 +1485,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1322
1485
|
modalTableTitle: '选择店铺',
|
|
1323
1486
|
tableSearchForm,
|
|
1324
1487
|
tableColumns: [
|
|
1488
|
+
{
|
|
1489
|
+
title: '序号',
|
|
1490
|
+
dataIndex: 'keyIndex',
|
|
1491
|
+
defaultSort: 0,
|
|
1492
|
+
},
|
|
1325
1493
|
{
|
|
1326
1494
|
title: '店铺编码',
|
|
1327
1495
|
dataIndex: 'code',
|
|
1496
|
+
defaultSort: 1,
|
|
1328
1497
|
},
|
|
1329
1498
|
{
|
|
1330
1499
|
title: '店铺名称',
|
|
1331
1500
|
dataIndex: 'name',
|
|
1501
|
+
defaultSort: 2,
|
|
1332
1502
|
},
|
|
1333
1503
|
{
|
|
1334
1504
|
title: '归属集团',
|
|
@@ -1341,11 +1511,13 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1341
1511
|
{
|
|
1342
1512
|
title: '店铺类型',
|
|
1343
1513
|
dataIndex: 'type',
|
|
1514
|
+
defaultSort: 3,
|
|
1344
1515
|
render: (text: number) => shopFileType.find((i: any) => i.value === text)?.text,
|
|
1345
1516
|
},
|
|
1346
1517
|
{
|
|
1347
1518
|
title: '店铺来源',
|
|
1348
1519
|
dataIndex: 'platformName',
|
|
1520
|
+
defaultSort: 4,
|
|
1349
1521
|
},
|
|
1350
1522
|
{
|
|
1351
1523
|
title: '归属核算主体',
|
|
@@ -1356,6 +1528,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1356
1528
|
}
|
|
1357
1529
|
}
|
|
1358
1530
|
if(type === 'shopFile2') {
|
|
1531
|
+
selectProps = {
|
|
1532
|
+
placeholder: '输入商店编码或名称',
|
|
1533
|
+
renderTableColumns: [
|
|
1534
|
+
{
|
|
1535
|
+
title: '商店编码',
|
|
1536
|
+
dataIndex: 'code',
|
|
1537
|
+
},
|
|
1538
|
+
{
|
|
1539
|
+
title: '商店名称',
|
|
1540
|
+
dataIndex: 'name',
|
|
1541
|
+
},
|
|
1542
|
+
],
|
|
1543
|
+
...selectConfigProps,
|
|
1544
|
+
}
|
|
1359
1545
|
requestConfig = {
|
|
1360
1546
|
url: `${prefixUrl.selectPrefix}/store/page`,
|
|
1361
1547
|
filter: 'qp-name,code-orGroup,like', // 过滤参数
|
|
@@ -1400,17 +1586,25 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1400
1586
|
modalTableTitle: '选择商店',
|
|
1401
1587
|
tableSearchForm,
|
|
1402
1588
|
tableColumns: [
|
|
1589
|
+
{
|
|
1590
|
+
title: '序号',
|
|
1591
|
+
dataIndex: 'keyIndex',
|
|
1592
|
+
defaultSort: 0,
|
|
1593
|
+
},
|
|
1403
1594
|
{
|
|
1404
1595
|
title: '商店编码',
|
|
1405
1596
|
dataIndex: 'code',
|
|
1597
|
+
defaultSort: 1,
|
|
1406
1598
|
},
|
|
1407
1599
|
{
|
|
1408
1600
|
title: '商店名称',
|
|
1409
1601
|
dataIndex: 'name',
|
|
1602
|
+
defaultSort: 2,
|
|
1410
1603
|
},
|
|
1411
1604
|
{
|
|
1412
1605
|
title: '商店类型',
|
|
1413
1606
|
dataIndex: 'type',
|
|
1607
|
+
defaultSort: 3,
|
|
1414
1608
|
render: (text: number) => shopFile2Type.find((i: any) => i.value === text)?.text,
|
|
1415
1609
|
},
|
|
1416
1610
|
{
|
|
@@ -1421,6 +1615,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1421
1615
|
{
|
|
1422
1616
|
title: '所属销售组织',
|
|
1423
1617
|
dataIndex: 'orgName',
|
|
1618
|
+
defaultSort: 4,
|
|
1424
1619
|
},
|
|
1425
1620
|
],
|
|
1426
1621
|
...modalTableBusProps
|
|
@@ -1429,6 +1624,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1429
1624
|
|
|
1430
1625
|
// 核算主体选择器(无弹窗)
|
|
1431
1626
|
if(type === 'accountingSubject') {
|
|
1627
|
+
selectProps = {
|
|
1628
|
+
placeholder: '输入核算主体编码或名称',
|
|
1629
|
+
renderTableColumns: [
|
|
1630
|
+
{
|
|
1631
|
+
title: '核算主体编码',
|
|
1632
|
+
dataIndex: 'code',
|
|
1633
|
+
},
|
|
1634
|
+
{
|
|
1635
|
+
title: '核算主体名称',
|
|
1636
|
+
dataIndex: 'name',
|
|
1637
|
+
},
|
|
1638
|
+
],
|
|
1639
|
+
...selectConfigProps,
|
|
1640
|
+
}
|
|
1432
1641
|
requestConfig = {
|
|
1433
1642
|
url: `${prefixUrl.selectPrefix}/accountingSubject`,
|
|
1434
1643
|
filter: 'qp-name,code-orGroup,like', // 过滤参数
|
|
@@ -1445,6 +1654,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1445
1654
|
}
|
|
1446
1655
|
// 库存组织选择器(无弹窗)
|
|
1447
1656
|
if(type === 'inventoryOrg') {
|
|
1657
|
+
selectProps = {
|
|
1658
|
+
placeholder: '输入库存组织编码或名称',
|
|
1659
|
+
renderTableColumns: [
|
|
1660
|
+
{
|
|
1661
|
+
title: '库存组织编码',
|
|
1662
|
+
dataIndex: 'code',
|
|
1663
|
+
},
|
|
1664
|
+
{
|
|
1665
|
+
title: '库存组织名称',
|
|
1666
|
+
dataIndex: 'name',
|
|
1667
|
+
},
|
|
1668
|
+
],
|
|
1669
|
+
...selectConfigProps,
|
|
1670
|
+
}
|
|
1448
1671
|
requestConfig = {
|
|
1449
1672
|
url: `${prefixUrl.selectPrefix}/inventoryOrg`,
|
|
1450
1673
|
filter: 'qp-name,code-orGroup,like', // 过滤参数
|
|
@@ -1462,6 +1685,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1462
1685
|
|
|
1463
1686
|
// 法人公司选择器(无弹窗)
|
|
1464
1687
|
if(type === 'corporationCompany') {
|
|
1688
|
+
selectProps = {
|
|
1689
|
+
placeholder: '输入法人公司编码或名称',
|
|
1690
|
+
renderTableColumns: [
|
|
1691
|
+
{
|
|
1692
|
+
title: '法人公司编码',
|
|
1693
|
+
dataIndex: 'code',
|
|
1694
|
+
},
|
|
1695
|
+
{
|
|
1696
|
+
title: '法人公司名称',
|
|
1697
|
+
dataIndex: 'name',
|
|
1698
|
+
},
|
|
1699
|
+
],
|
|
1700
|
+
...selectConfigProps,
|
|
1701
|
+
}
|
|
1465
1702
|
requestConfig = {
|
|
1466
1703
|
url: `${prefixUrl.selectPrefix}/company`,
|
|
1467
1704
|
filter: 'qp-name,code-orGroup,like', // 过滤参数
|
|
@@ -1479,6 +1716,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1479
1716
|
|
|
1480
1717
|
// 新-法人公司选择器(无弹窗)
|
|
1481
1718
|
if(type === 'platCompany') {
|
|
1719
|
+
selectProps = {
|
|
1720
|
+
placeholder: '输入法人公司编码或名称',
|
|
1721
|
+
renderTableColumns: [
|
|
1722
|
+
{
|
|
1723
|
+
title: '法人公司编码',
|
|
1724
|
+
dataIndex: 'socialCreditCode',
|
|
1725
|
+
},
|
|
1726
|
+
{
|
|
1727
|
+
title: '法人公司名称',
|
|
1728
|
+
dataIndex: 'name',
|
|
1729
|
+
},
|
|
1730
|
+
],
|
|
1731
|
+
...selectConfigProps,
|
|
1732
|
+
}
|
|
1482
1733
|
requestConfig = {
|
|
1483
1734
|
url: `${prefixUrl.selectPrefix}/platCompany`,
|
|
1484
1735
|
filter: 'qp-name,socialCreditCode-orGroup,like', // 过滤参数
|
|
@@ -1496,6 +1747,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1496
1747
|
|
|
1497
1748
|
// 员工选择器
|
|
1498
1749
|
if(type === 'employee') {
|
|
1750
|
+
selectProps = {
|
|
1751
|
+
placeholder: '输入员工编码或名称',
|
|
1752
|
+
renderTableColumns: [
|
|
1753
|
+
{
|
|
1754
|
+
title: '员工编码',
|
|
1755
|
+
dataIndex: 'employeeNumber',
|
|
1756
|
+
},
|
|
1757
|
+
{
|
|
1758
|
+
title: '员工名称',
|
|
1759
|
+
dataIndex: 'name',
|
|
1760
|
+
},
|
|
1761
|
+
],
|
|
1762
|
+
...selectConfigProps,
|
|
1763
|
+
}
|
|
1499
1764
|
requestConfig = {
|
|
1500
1765
|
url: `${prefixUrl.selectPrefix}/employee/v2`,
|
|
1501
1766
|
filter: 'qp-employeeNumber,name-orGroup,like', // 过滤参数
|
|
@@ -1543,17 +1808,25 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1543
1808
|
modalTableTitle: '选择员工',
|
|
1544
1809
|
tableSearchForm,
|
|
1545
1810
|
tableColumns: [
|
|
1811
|
+
{
|
|
1812
|
+
title: '序号',
|
|
1813
|
+
dataIndex: 'keyIndex',
|
|
1814
|
+
defaultSort: 0,
|
|
1815
|
+
},
|
|
1546
1816
|
{
|
|
1547
1817
|
title: '员工编码',
|
|
1548
1818
|
dataIndex: 'employeeNumber',
|
|
1819
|
+
defaultSort: 1,
|
|
1549
1820
|
},
|
|
1550
1821
|
{
|
|
1551
1822
|
title: '员工名称',
|
|
1552
1823
|
dataIndex: 'name',
|
|
1824
|
+
defaultSort: 2,
|
|
1553
1825
|
},
|
|
1554
1826
|
{
|
|
1555
1827
|
title: '所属公司',
|
|
1556
1828
|
dataIndex: 'companyName',
|
|
1829
|
+
defaultSort: 3,
|
|
1557
1830
|
},
|
|
1558
1831
|
{
|
|
1559
1832
|
title: '邮箱',
|
|
@@ -1562,6 +1835,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1562
1835
|
{
|
|
1563
1836
|
title: '手机号',
|
|
1564
1837
|
dataIndex: 'officeTelephone',
|
|
1838
|
+
defaultSort: 4,
|
|
1565
1839
|
},
|
|
1566
1840
|
],
|
|
1567
1841
|
...modalTableBusProps
|
|
@@ -1569,6 +1843,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1569
1843
|
}
|
|
1570
1844
|
if(type === 'employee2') {
|
|
1571
1845
|
// 版本2
|
|
1846
|
+
selectProps = {
|
|
1847
|
+
placeholder: '输入员工编码或名称',
|
|
1848
|
+
renderTableColumns: [
|
|
1849
|
+
{
|
|
1850
|
+
title: '员工编码',
|
|
1851
|
+
dataIndex: 'username',
|
|
1852
|
+
},
|
|
1853
|
+
{
|
|
1854
|
+
title: '员工名称',
|
|
1855
|
+
dataIndex: 'name',
|
|
1856
|
+
},
|
|
1857
|
+
],
|
|
1858
|
+
...selectConfigProps,
|
|
1859
|
+
}
|
|
1572
1860
|
requestConfig = {
|
|
1573
1861
|
url: `${prefixUrl.selectPrefix}/employee/pageList/v2`,
|
|
1574
1862
|
filter: 'qp-username,name-orGroup,like', // 过滤参数
|
|
@@ -1621,14 +1909,21 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1621
1909
|
modalTableTitle: '添加员工',
|
|
1622
1910
|
tableSearchForm,
|
|
1623
1911
|
tableColumns: [
|
|
1912
|
+
{
|
|
1913
|
+
title: '序号',
|
|
1914
|
+
dataIndex: 'keyIndex',
|
|
1915
|
+
defaultSort: 0,
|
|
1916
|
+
},
|
|
1624
1917
|
{
|
|
1625
1918
|
title: '账户名称',
|
|
1626
1919
|
dataIndex: 'username',
|
|
1920
|
+
defaultSort: 1,
|
|
1627
1921
|
render: (text: any) => handleTextOverflow(text),
|
|
1628
1922
|
},
|
|
1629
1923
|
{
|
|
1630
1924
|
title: '显示名称',
|
|
1631
1925
|
dataIndex: 'name',
|
|
1926
|
+
defaultSort: 2,
|
|
1632
1927
|
},
|
|
1633
1928
|
// {
|
|
1634
1929
|
// title: '员工编码',
|
|
@@ -1641,6 +1936,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1641
1936
|
{
|
|
1642
1937
|
title: '所属组织机构',
|
|
1643
1938
|
dataIndex: 'administrativeNames',
|
|
1939
|
+
defaultSort: 3,
|
|
1644
1940
|
render: (text: any) => handleTextOverflow(text),
|
|
1645
1941
|
},
|
|
1646
1942
|
...(modalTableBusProps?.needTypeSearch?[{
|
|
@@ -1655,6 +1951,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1655
1951
|
{
|
|
1656
1952
|
title: '手机号',
|
|
1657
1953
|
dataIndex: 'officeTelephone',
|
|
1954
|
+
defaultSort: 4,
|
|
1658
1955
|
render: (text: any, record: any) => handleTextOverflow(text||record?.phone),
|
|
1659
1956
|
},
|
|
1660
1957
|
],
|
|
@@ -1664,6 +1961,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1664
1961
|
|
|
1665
1962
|
// 配送方式选择器
|
|
1666
1963
|
if(type === 'deliveryMode') {
|
|
1964
|
+
selectProps = {
|
|
1965
|
+
placeholder: '输入配送方式编码或名称',
|
|
1966
|
+
renderTableColumns: [
|
|
1967
|
+
{
|
|
1968
|
+
title: '配送方式编码',
|
|
1969
|
+
dataIndex: 'code',
|
|
1970
|
+
},
|
|
1971
|
+
{
|
|
1972
|
+
title: '配送方式名称',
|
|
1973
|
+
dataIndex: 'name',
|
|
1974
|
+
},
|
|
1975
|
+
],
|
|
1976
|
+
...selectConfigProps,
|
|
1977
|
+
}
|
|
1667
1978
|
const isLogisCompanyCodeSingleSearch = requestConfigProp?.fixedparameter?.some((i: any) => i == 'qp-logisCompanyCode-eq');
|
|
1668
1979
|
const logisCompanyCodeSingleSearchName = isLogisCompanyCodeSingleSearch ? 'qp-logisCompanyCode-eq' : 'qp-logisCompanyCode-in';
|
|
1669
1980
|
requestConfig = {
|
|
@@ -1732,17 +2043,25 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1732
2043
|
modalTableTitle: '选择配送方式',
|
|
1733
2044
|
tableSearchForm,
|
|
1734
2045
|
tableColumns: [
|
|
2046
|
+
{
|
|
2047
|
+
title: '序号',
|
|
2048
|
+
dataIndex: 'keyIndex',
|
|
2049
|
+
defaultSort: 0,
|
|
2050
|
+
},
|
|
1735
2051
|
{
|
|
1736
2052
|
title: '配送方式编码',
|
|
1737
2053
|
dataIndex: 'code',
|
|
2054
|
+
defaultSort: 1,
|
|
1738
2055
|
},
|
|
1739
2056
|
{
|
|
1740
2057
|
title: '配送方式名称',
|
|
1741
2058
|
dataIndex: 'name',
|
|
2059
|
+
defaultSort: 2,
|
|
1742
2060
|
},
|
|
1743
2061
|
{
|
|
1744
2062
|
title: '所属物流商',
|
|
1745
2063
|
dataIndex: 'logisCompanyName',
|
|
2064
|
+
defaultSort: 3,
|
|
1746
2065
|
},
|
|
1747
2066
|
{
|
|
1748
2067
|
dataIndex: 'recordChannnelCode',
|
|
@@ -1761,6 +2080,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1761
2080
|
{
|
|
1762
2081
|
dataIndex: 'remark',
|
|
1763
2082
|
title: '备注',
|
|
2083
|
+
defaultSort: 4,
|
|
1764
2084
|
},
|
|
1765
2085
|
],
|
|
1766
2086
|
...modalTableBusProps
|
|
@@ -1769,6 +2089,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1769
2089
|
|
|
1770
2090
|
// 规则模板选择器
|
|
1771
2091
|
if(type === 'ruleTemplate') {
|
|
2092
|
+
selectProps = {
|
|
2093
|
+
placeholder: '输入规则模板编码或名称',
|
|
2094
|
+
renderTableColumns: [
|
|
2095
|
+
{
|
|
2096
|
+
title: '规则模板编码',
|
|
2097
|
+
dataIndex: 'code',
|
|
2098
|
+
},
|
|
2099
|
+
{
|
|
2100
|
+
title: '规则模板名称',
|
|
2101
|
+
dataIndex: 'name',
|
|
2102
|
+
},
|
|
2103
|
+
],
|
|
2104
|
+
...selectConfigProps,
|
|
2105
|
+
}
|
|
1772
2106
|
requestConfig = {
|
|
1773
2107
|
url: `${prefixUrl.selectPrefix}/ruleTemplate`,
|
|
1774
2108
|
filter: 'qp-name,code-orGroup,like', // 过滤参数
|
|
@@ -1789,18 +2123,26 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1789
2123
|
modalTableTitle: '选择规则模板',
|
|
1790
2124
|
tableSearchForm,
|
|
1791
2125
|
tableColumns: [
|
|
2126
|
+
{
|
|
2127
|
+
title: '序号',
|
|
2128
|
+
dataIndex: 'keyIndex',
|
|
2129
|
+
defaultSort: 0,
|
|
2130
|
+
},
|
|
1792
2131
|
{
|
|
1793
2132
|
title: '规则模板编码',
|
|
1794
2133
|
dataIndex: 'code',
|
|
2134
|
+
defaultSort: 1,
|
|
1795
2135
|
},
|
|
1796
2136
|
{
|
|
1797
2137
|
title: '规则模板名称',
|
|
1798
2138
|
dataIndex: 'name',
|
|
2139
|
+
defaultSort: 2,
|
|
1799
2140
|
render: (text: any) => handleTextOverflow(text),
|
|
1800
2141
|
},
|
|
1801
2142
|
{
|
|
1802
2143
|
title: '条件对象',
|
|
1803
2144
|
dataIndex: 'objectName',
|
|
2145
|
+
defaultSort: 3,
|
|
1804
2146
|
render: (text: any) => handleTextOverflow(text),
|
|
1805
2147
|
},
|
|
1806
2148
|
{
|
|
@@ -1811,6 +2153,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1811
2153
|
{
|
|
1812
2154
|
dataIndex: 'actionName',
|
|
1813
2155
|
title: '执行动作',
|
|
2156
|
+
defaultSort: 4,
|
|
1814
2157
|
render: (text: any) => handleTextOverflow(text),
|
|
1815
2158
|
},
|
|
1816
2159
|
],
|
|
@@ -1820,6 +2163,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1820
2163
|
|
|
1821
2164
|
// 角色选择器
|
|
1822
2165
|
if(type === 'role') {
|
|
2166
|
+
selectProps = {
|
|
2167
|
+
placeholder: '输入角色编码或名称',
|
|
2168
|
+
renderTableColumns: [
|
|
2169
|
+
{
|
|
2170
|
+
title: '角色编码',
|
|
2171
|
+
dataIndex: 'code',
|
|
2172
|
+
},
|
|
2173
|
+
{
|
|
2174
|
+
title: '角色名称',
|
|
2175
|
+
dataIndex: 'name',
|
|
2176
|
+
},
|
|
2177
|
+
],
|
|
2178
|
+
...selectConfigProps,
|
|
2179
|
+
}
|
|
1823
2180
|
requestConfig = {
|
|
1824
2181
|
url: `${prefixUrl.selectPrefix}/role`,
|
|
1825
2182
|
filter: 'qp-name,code-orGroup,like', // 过滤参数
|
|
@@ -1863,18 +2220,26 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1863
2220
|
modalTableTitle: '选择角色',
|
|
1864
2221
|
tableSearchForm,
|
|
1865
2222
|
tableColumns: [
|
|
2223
|
+
{
|
|
2224
|
+
title: '序号',
|
|
2225
|
+
dataIndex: 'keyIndex',
|
|
2226
|
+
defaultSort: 0,
|
|
2227
|
+
},
|
|
1866
2228
|
{
|
|
1867
2229
|
title: '角色编码',
|
|
1868
2230
|
dataIndex: 'code',
|
|
2231
|
+
defaultSort: 1,
|
|
1869
2232
|
},
|
|
1870
2233
|
{
|
|
1871
2234
|
title: '角色名称',
|
|
1872
2235
|
dataIndex: 'name',
|
|
2236
|
+
defaultSort: 2,
|
|
1873
2237
|
render: (text: any) => handleTextOverflow(text),
|
|
1874
2238
|
},
|
|
1875
2239
|
{
|
|
1876
2240
|
title: '角色分类',
|
|
1877
2241
|
dataIndex: 'categoryName',
|
|
2242
|
+
defaultSort: 3,
|
|
1878
2243
|
render: (text: any) => handleTextOverflow(text),
|
|
1879
2244
|
},
|
|
1880
2245
|
{
|
|
@@ -1885,6 +2250,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1885
2250
|
{
|
|
1886
2251
|
dataIndex: 'applicationName',
|
|
1887
2252
|
title: '应用',
|
|
2253
|
+
defaultSort: 4,
|
|
1888
2254
|
render: (text: any) => handleTextOverflow(text),
|
|
1889
2255
|
},
|
|
1890
2256
|
],
|
|
@@ -1894,6 +2260,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1894
2260
|
|
|
1895
2261
|
// 销售渠道选择器
|
|
1896
2262
|
if(type === 'market-channel') {
|
|
2263
|
+
selectProps = {
|
|
2264
|
+
placeholder: '输入销售渠道编码或名称',
|
|
2265
|
+
renderTableColumns: [
|
|
2266
|
+
{
|
|
2267
|
+
title: '销售渠道编码',
|
|
2268
|
+
dataIndex: 'code',
|
|
2269
|
+
},
|
|
2270
|
+
{
|
|
2271
|
+
title: '销售渠道名称',
|
|
2272
|
+
dataIndex: 'name',
|
|
2273
|
+
},
|
|
2274
|
+
],
|
|
2275
|
+
...selectConfigProps,
|
|
2276
|
+
}
|
|
1897
2277
|
requestConfig = {
|
|
1898
2278
|
url: `${prefixUrl.selectPrefix}/channelInfo`,
|
|
1899
2279
|
filter: 'qp-name,code-orGroup,like', // 过滤参数
|
|
@@ -1940,18 +2320,26 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1940
2320
|
modalTableTitle: '选择销售渠道',
|
|
1941
2321
|
tableSearchForm,
|
|
1942
2322
|
tableColumns: [
|
|
2323
|
+
{
|
|
2324
|
+
title: '序号',
|
|
2325
|
+
dataIndex: 'keyIndex',
|
|
2326
|
+
defaultSort: 0,
|
|
2327
|
+
},
|
|
1943
2328
|
{
|
|
1944
2329
|
title: '销售渠道编码',
|
|
1945
2330
|
dataIndex: 'code',
|
|
2331
|
+
defaultSort: 1,
|
|
1946
2332
|
},
|
|
1947
2333
|
{
|
|
1948
2334
|
title: '销售渠道名称',
|
|
1949
2335
|
dataIndex: 'name',
|
|
2336
|
+
defaultSort: 2,
|
|
1950
2337
|
render: (text: any) => handleTextOverflow(text),
|
|
1951
2338
|
},
|
|
1952
2339
|
{
|
|
1953
2340
|
title: '所属销售组织',
|
|
1954
2341
|
dataIndex: 'salesOrgCodeName',
|
|
2342
|
+
defaultSort: 3,
|
|
1955
2343
|
render: (text: any) => handleTextOverflow(text),
|
|
1956
2344
|
},
|
|
1957
2345
|
],
|
|
@@ -1961,6 +2349,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
1961
2349
|
|
|
1962
2350
|
//业务组织选择器(可筛选业务职能/组织类型/组织形态)
|
|
1963
2351
|
if (type === 'business-organization') {
|
|
2352
|
+
selectProps = {
|
|
2353
|
+
placeholder: '输入业务组织编码或名称',
|
|
2354
|
+
renderTableColumns: [
|
|
2355
|
+
{
|
|
2356
|
+
title: '业务组织编码',
|
|
2357
|
+
dataIndex: 'code',
|
|
2358
|
+
},
|
|
2359
|
+
{
|
|
2360
|
+
title: '业务组织名称',
|
|
2361
|
+
dataIndex: 'name',
|
|
2362
|
+
},
|
|
2363
|
+
],
|
|
2364
|
+
...selectConfigProps,
|
|
2365
|
+
}
|
|
1964
2366
|
requestConfig = {
|
|
1965
2367
|
url: `${prefixUrl.selectPrefix}/orgViewNode/common/pageList`,
|
|
1966
2368
|
filter: 'qp-name-like', // 过滤参数
|
|
@@ -2030,18 +2432,26 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
2030
2432
|
modalTableTitle: '选择组织',
|
|
2031
2433
|
tableSearchForm,
|
|
2032
2434
|
tableColumns: [
|
|
2435
|
+
{
|
|
2436
|
+
title: '序号',
|
|
2437
|
+
dataIndex: 'keyIndex',
|
|
2438
|
+
defaultSort: 0,
|
|
2439
|
+
},
|
|
2033
2440
|
{
|
|
2034
2441
|
title: '组织编码',
|
|
2035
2442
|
dataIndex: 'code',
|
|
2443
|
+
defaultSort: 1,
|
|
2036
2444
|
},
|
|
2037
2445
|
{
|
|
2038
2446
|
title: '组织名称',
|
|
2039
2447
|
dataIndex: 'name',
|
|
2448
|
+
defaultSort: 2,
|
|
2040
2449
|
render: (text: any) => handleTextOverflow(text),
|
|
2041
2450
|
},
|
|
2042
2451
|
{
|
|
2043
2452
|
title: '业务职能',
|
|
2044
2453
|
dataIndex: 'orgViewNameList',
|
|
2454
|
+
defaultSort: 3,
|
|
2045
2455
|
render: (text: any, record: any) => {
|
|
2046
2456
|
const { orgViewNameList = [] } = record;
|
|
2047
2457
|
return orgViewNameList.length ? orgViewNameList.join('/') : '--';
|
|
@@ -2050,6 +2460,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
2050
2460
|
{
|
|
2051
2461
|
title: '组织类型',
|
|
2052
2462
|
dataIndex: 'orgType',
|
|
2463
|
+
defaultSort: 4,
|
|
2053
2464
|
render: (text: any) => {
|
|
2054
2465
|
const obj = orgType.find((i: any) => i.value == text);
|
|
2055
2466
|
return obj ? obj.text : '--';
|
|
@@ -2070,6 +2481,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
2070
2481
|
|
|
2071
2482
|
// 人员选择器
|
|
2072
2483
|
if(type === 'person') {
|
|
2484
|
+
selectProps = {
|
|
2485
|
+
placeholder: '输入人员编码或名称',
|
|
2486
|
+
renderTableColumns: [
|
|
2487
|
+
{
|
|
2488
|
+
title: '人员编码',
|
|
2489
|
+
dataIndex: 'code',
|
|
2490
|
+
},
|
|
2491
|
+
{
|
|
2492
|
+
title: '人员名称',
|
|
2493
|
+
dataIndex: 'name',
|
|
2494
|
+
},
|
|
2495
|
+
],
|
|
2496
|
+
...selectConfigProps,
|
|
2497
|
+
}
|
|
2073
2498
|
requestConfig = {
|
|
2074
2499
|
url: `${prefixUrl.selectPrefix}/person`,
|
|
2075
2500
|
filter: 'qp-code,name-orGroup,like', // 过滤参数
|
|
@@ -2091,22 +2516,31 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
2091
2516
|
modalTableTitle: '添加人员',
|
|
2092
2517
|
tableSearchForm,
|
|
2093
2518
|
tableColumns: [
|
|
2519
|
+
{
|
|
2520
|
+
title: '序号',
|
|
2521
|
+
dataIndex: 'keyIndex',
|
|
2522
|
+
defaultSort: 0,
|
|
2523
|
+
},
|
|
2094
2524
|
{
|
|
2095
2525
|
title: '姓名',
|
|
2096
2526
|
dataIndex: 'name',
|
|
2527
|
+
defaultSort: 1,
|
|
2097
2528
|
},
|
|
2098
2529
|
{
|
|
2099
2530
|
title: '员工工号',
|
|
2100
2531
|
dataIndex: 'code',
|
|
2532
|
+
defaultSort: 2,
|
|
2101
2533
|
},
|
|
2102
2534
|
{
|
|
2103
2535
|
title: '员工类型',
|
|
2104
2536
|
dataIndex: 'dataSource',
|
|
2537
|
+
defaultSort: 3,
|
|
2105
2538
|
render: (text: number) => personDataSourceType.find((i: any) => i.value == text)?.text,
|
|
2106
2539
|
},
|
|
2107
2540
|
{
|
|
2108
2541
|
title: '手机号',
|
|
2109
2542
|
dataIndex: 'phone',
|
|
2543
|
+
defaultSort: 4,
|
|
2110
2544
|
},
|
|
2111
2545
|
],
|
|
2112
2546
|
...modalTableBusProps
|
|
@@ -2115,6 +2549,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
2115
2549
|
|
|
2116
2550
|
// 品牌选择器
|
|
2117
2551
|
if(type === 'brand') {
|
|
2552
|
+
selectProps = {
|
|
2553
|
+
placeholder: '输入品牌编码或名称',
|
|
2554
|
+
renderTableColumns: [
|
|
2555
|
+
{
|
|
2556
|
+
title: '品牌编码',
|
|
2557
|
+
dataIndex: 'brandCode',
|
|
2558
|
+
},
|
|
2559
|
+
{
|
|
2560
|
+
title: '品牌名称',
|
|
2561
|
+
dataIndex: 'name',
|
|
2562
|
+
},
|
|
2563
|
+
],
|
|
2564
|
+
...selectConfigProps,
|
|
2565
|
+
}
|
|
2118
2566
|
requestConfig = {
|
|
2119
2567
|
url: `${prefixUrl.selectPrefix}/brand/list`,
|
|
2120
2568
|
filter: 'qp-brandCode,name-orGroup,like', // 过滤参数
|
|
@@ -2137,9 +2585,15 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
2137
2585
|
modalTableTitle: '添加品牌',
|
|
2138
2586
|
tableSearchForm,
|
|
2139
2587
|
tableColumns: [
|
|
2588
|
+
{
|
|
2589
|
+
title: '序号',
|
|
2590
|
+
dataIndex: 'keyIndex',
|
|
2591
|
+
defaultSort: 0,
|
|
2592
|
+
},
|
|
2140
2593
|
{
|
|
2141
2594
|
title: '品牌图片',
|
|
2142
2595
|
dataIndex: 'logoUrl',
|
|
2596
|
+
defaultSort: 1,
|
|
2143
2597
|
render: (text: any) => (
|
|
2144
2598
|
<Image.PreviewGroup>
|
|
2145
2599
|
{(text && Object.prototype.toString.call(JSON.parse(text)) === '[object Array]' &&
|
|
@@ -2153,10 +2607,12 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
2153
2607
|
{
|
|
2154
2608
|
title: '品牌编码',
|
|
2155
2609
|
dataIndex: 'brandCode',
|
|
2610
|
+
defaultSort: 2,
|
|
2156
2611
|
},
|
|
2157
2612
|
{
|
|
2158
2613
|
title: '品牌中文名',
|
|
2159
2614
|
dataIndex: 'name',
|
|
2615
|
+
defaultSort: 3,
|
|
2160
2616
|
},
|
|
2161
2617
|
{
|
|
2162
2618
|
title: '品牌英文名',
|
|
@@ -2165,6 +2621,7 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
2165
2621
|
{
|
|
2166
2622
|
title: '品牌首字母',
|
|
2167
2623
|
dataIndex: 'brandInitial',
|
|
2624
|
+
defaultSort: 4,
|
|
2168
2625
|
},
|
|
2169
2626
|
{
|
|
2170
2627
|
title: '描述',
|
|
@@ -2177,6 +2634,20 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
2177
2634
|
|
|
2178
2635
|
// 价格项选择器
|
|
2179
2636
|
if(type === 'priceItem') {
|
|
2637
|
+
selectProps = {
|
|
2638
|
+
placeholder: '输入价格项编码或名称',
|
|
2639
|
+
renderTableColumns: [
|
|
2640
|
+
{
|
|
2641
|
+
title: '价格项编码',
|
|
2642
|
+
dataIndex: 'code',
|
|
2643
|
+
},
|
|
2644
|
+
{
|
|
2645
|
+
title: '价格项名称',
|
|
2646
|
+
dataIndex: 'name',
|
|
2647
|
+
},
|
|
2648
|
+
],
|
|
2649
|
+
...selectConfigProps,
|
|
2650
|
+
}
|
|
2180
2651
|
requestConfig = {
|
|
2181
2652
|
url: `${prefixUrl.selectPrefix}/priceType`,
|
|
2182
2653
|
filter: 'qp-code,name-orGroup,like', // 过滤参数
|
|
@@ -2198,27 +2669,170 @@ export function commonFun (type?: string, prefixUrl: any, requestConfigProp?: an
|
|
|
2198
2669
|
modalTableTitle: '选择价格项',
|
|
2199
2670
|
tableSearchForm,
|
|
2200
2671
|
tableColumns: [
|
|
2672
|
+
{
|
|
2673
|
+
title: '序号',
|
|
2674
|
+
dataIndex: 'keyIndex',
|
|
2675
|
+
defaultSort: 0,
|
|
2676
|
+
},
|
|
2201
2677
|
{
|
|
2202
2678
|
title: '代码',
|
|
2203
2679
|
dataIndex: 'code',
|
|
2680
|
+
defaultSort: 1,
|
|
2204
2681
|
},
|
|
2205
2682
|
{
|
|
2206
2683
|
title: '名称',
|
|
2207
2684
|
dataIndex: 'name',
|
|
2685
|
+
defaultSort: 2,
|
|
2208
2686
|
},
|
|
2209
2687
|
{
|
|
2210
2688
|
title: '创建时间',
|
|
2211
2689
|
dataIndex: 'createTime',
|
|
2690
|
+
defaultSort: 3,
|
|
2212
2691
|
render: (text: any) => handleTooltip(text, true),
|
|
2213
2692
|
},
|
|
2214
2693
|
{
|
|
2215
2694
|
title: '创建人',
|
|
2216
2695
|
dataIndex: 'createUserName',
|
|
2696
|
+
defaultSort: 4,
|
|
2697
|
+
},
|
|
2698
|
+
],
|
|
2699
|
+
...modalTableBusProps
|
|
2700
|
+
}
|
|
2701
|
+
}
|
|
2702
|
+
|
|
2703
|
+
// 销售组织
|
|
2704
|
+
if (type === 'sales-organization') {
|
|
2705
|
+
selectProps = {
|
|
2706
|
+
placeholder: '输入销售组织编码或名称',
|
|
2707
|
+
renderTableColumns: [
|
|
2708
|
+
{
|
|
2709
|
+
title: '销售组织编码',
|
|
2710
|
+
dataIndex: 'code',
|
|
2711
|
+
},
|
|
2712
|
+
{
|
|
2713
|
+
title: '销售组织名称',
|
|
2714
|
+
dataIndex: 'name',
|
|
2715
|
+
},
|
|
2716
|
+
],
|
|
2717
|
+
...selectConfigProps,
|
|
2718
|
+
}
|
|
2719
|
+
requestConfig = {
|
|
2720
|
+
url: `${prefixUrl.selectPrefix}/orgViewNode/listNoPage`,
|
|
2721
|
+
filter: 'qp-code,name-orGroup,like', // 过滤参数
|
|
2722
|
+
mappingTextField: 'name',
|
|
2723
|
+
mappingTextShowKeyField: 'code',
|
|
2724
|
+
mappingValueField: 'code',
|
|
2725
|
+
otherParams: {
|
|
2726
|
+
'qp-orgViewCode-eq': 'sales-organizational-view',
|
|
2727
|
+
'qp-status-eq': 10,
|
|
2728
|
+
sorter: 'desc-createTime',
|
|
2729
|
+
}, // 默认参数
|
|
2730
|
+
sourceName: 'supplierCode',
|
|
2731
|
+
...requestConfigProp
|
|
2732
|
+
},
|
|
2733
|
+
tableSearchForm = [
|
|
2734
|
+
{ name: 'qp-name-like', label: '组织名称' },
|
|
2735
|
+
{ name: 'qp-code-like', label: '组织编码' },
|
|
2736
|
+
{ name: 'qp-orgViewCode-in', type: 'select', label: '业务职能', field: {
|
|
2737
|
+
type: 'select',
|
|
2738
|
+
props: {
|
|
2739
|
+
mode: 'multiple',
|
|
2740
|
+
notFoundContent: '暂无数据',
|
|
2741
|
+
allowClear: true,
|
|
2742
|
+
showSearch: true,
|
|
2743
|
+
showArrow: true,
|
|
2744
|
+
maxTagCount: 1,
|
|
2745
|
+
optionFilterProp: 'children',
|
|
2746
|
+
filterOption: (input: string, option: { props: { children: string } }) =>
|
|
2747
|
+
option.props.children.toLowerCase().indexOf(input.toLowerCase()) >= 0,
|
|
2748
|
+
},
|
|
2749
|
+
}
|
|
2750
|
+
},
|
|
2751
|
+
{
|
|
2752
|
+
name: 'qp-orgType-in',
|
|
2753
|
+
type: 'select',
|
|
2754
|
+
label: '组织类型',
|
|
2755
|
+
field: {
|
|
2756
|
+
type: 'select',
|
|
2757
|
+
props: {
|
|
2758
|
+
mode: 'multiple',
|
|
2759
|
+
allowClear: true,
|
|
2760
|
+
maxTagCount: 1,
|
|
2761
|
+
},
|
|
2762
|
+
},
|
|
2763
|
+
initialSource: orgType
|
|
2764
|
+
},
|
|
2765
|
+
{
|
|
2766
|
+
name: 'qp-nodeType-in',
|
|
2767
|
+
type: 'select',
|
|
2768
|
+
label: '组织形态',
|
|
2769
|
+
field: {
|
|
2770
|
+
type: 'select',
|
|
2771
|
+
props: {
|
|
2772
|
+
mode: 'multiple',
|
|
2773
|
+
allowClear: true,
|
|
2774
|
+
maxTagCount: 1,
|
|
2775
|
+
},
|
|
2776
|
+
},
|
|
2777
|
+
initialSource: nodeType
|
|
2778
|
+
}]
|
|
2779
|
+
Promise.all([
|
|
2780
|
+
loadSelectSource(`${prefixUrl.formSelectFix}/orgView/getOrgViewListNoPage`, {
|
|
2781
|
+
'qp-status-eq': 10
|
|
2782
|
+
}),
|
|
2783
|
+
]).then((x: any)=>{
|
|
2784
|
+
formatSource(x, 0, 2, tableSearchForm);
|
|
2785
|
+
})
|
|
2786
|
+
modalTableProps = {
|
|
2787
|
+
modalTableTitle: '选择组织',
|
|
2788
|
+
tableSearchForm,
|
|
2789
|
+
tableColumns: [
|
|
2790
|
+
{
|
|
2791
|
+
title: '序号',
|
|
2792
|
+
dataIndex: 'keyIndex',
|
|
2793
|
+
defaultSort: 0,
|
|
2794
|
+
},
|
|
2795
|
+
{
|
|
2796
|
+
title: '组织编码',
|
|
2797
|
+
dataIndex: 'code',
|
|
2798
|
+
defaultSort: 1,
|
|
2799
|
+
},
|
|
2800
|
+
{
|
|
2801
|
+
title: '组织名称',
|
|
2802
|
+
dataIndex: 'name',
|
|
2803
|
+
defaultSort: 2,
|
|
2804
|
+
render: (text: any) => handleTextOverflow(text),
|
|
2805
|
+
},
|
|
2806
|
+
{
|
|
2807
|
+
title: '业务职能',
|
|
2808
|
+
dataIndex: 'orgViewNameList',
|
|
2809
|
+
defaultSort: 3,
|
|
2810
|
+
render: (text: any, record: any) => {
|
|
2811
|
+
const { orgViewNameList = [] } = record;
|
|
2812
|
+
return orgViewNameList.length ? orgViewNameList.join('/') : '--';
|
|
2813
|
+
},
|
|
2814
|
+
},
|
|
2815
|
+
{
|
|
2816
|
+
title: '组织类型',
|
|
2817
|
+
dataIndex: 'orgType',
|
|
2818
|
+
defaultSort: 4,
|
|
2819
|
+
render: (text: any) => {
|
|
2820
|
+
const obj = orgType.find((i: any) => i.value == text);
|
|
2821
|
+
return obj ? obj.text : '--';
|
|
2822
|
+
}
|
|
2823
|
+
},
|
|
2824
|
+
{
|
|
2825
|
+
title: '组织形态',
|
|
2826
|
+
dataIndex: 'nodeType',
|
|
2827
|
+
render: (text: any) => {
|
|
2828
|
+
const obj = nodeType.find((i: any) => i.value == text);
|
|
2829
|
+
return obj ? obj.text : '--';
|
|
2830
|
+
}
|
|
2217
2831
|
},
|
|
2218
2832
|
],
|
|
2219
2833
|
...modalTableBusProps
|
|
2220
2834
|
}
|
|
2221
2835
|
}
|
|
2222
2836
|
|
|
2223
|
-
return { modalTableProps, requestConfig, needModalTable };
|
|
2837
|
+
return { modalTableProps, selectProps, requestConfig, needModalTable };
|
|
2224
2838
|
}
|