1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
function getcolumns(ifs) {
return [
{ title: '产线代码', dataIndex: 'productionLineCode', key: 'productionLineCode', width: 180 },
{
title: '产线名称',
dataIndex: 'productionLineName',
key: 'productionLineName',
width: 180,
formItemProps: { rules: [{ required: true, message: '此项为必填项' }] },
},
{
title: '所属工厂',
dataIndex: 'factoryName',
fieldProps: {
showSearch: true,
},
hideInForm: true,
key: 'factoryId',
width: 180,
formItemProps: { rules: [{ required: true, message: '此项为必填项' }] },
valueType: 'select',
options: { path: '/auth/sysFactory/getAllFactorySelection', params: {} },
},
{
title: '所属车间',
dataIndex: 'shopName',
key: 'shopId',
hideInForm: true,
fieldProps: {
showSearch: true,
},
width: 180,
formItemProps: { rules: [{ required: true, message: '此项为必填项' }] },
valueType: 'select',
options: {
path: '/auth/sysShop/getAllShopSelection',
},
},
{
title: '所属工厂',
dataIndex: 'factoryName',
key: 'factoryId',
width: 180,
hideInTable: true,
search: false,
fieldProps: {
disabled: ifs,
},
formItemProps: { rules: [{ required: true, message: '此项为必填项' }] },
valueType: 'select',
options: { path: '/auth/sysFactory/getAllFactorySelection', params: {} },
},
{
title: '所属车间',
dataIndex: 'shopName',
key: 'shopId',
hideInTable: true,
search: false,
fieldProps: {
disabled: ifs,
},
width: 180,
formItemProps: { rules: [{ required: true, message: '此项为必填项' }] },
valueType: 'select',
options: {
path: '/auth/sysShop/getShopSelectionByFactory',
linkParams: {
factoryId: '', //key 后面如果存在value 则该value会在调用接口时format
},
},
},
];
}
export default getcolumns;