jit.js
3.07 KB
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
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
/**
* Created by TaoHuang on 2017/6/20.
*/
export default function() {
return {
tableCols: [{
title: 'SKN',
key: 'productSkn',
align: 'center'
},
{
title: '图片',
key: 'image',
align: 'center',
render: (h, params) => {
return (
<img v-prod-img={params.row.productSkn}/>
);
}
},
{
title: '商品名称',
key: 'productName',
align: 'center',
},
{
title: '品牌',
key: 'brandName',
align: 'center',
},
{
title: '设置总库存',
key: 'virtualNum',
align: 'center',
render: (h, params) => {
return (
<span>{params.row.virtualNum || 0}</span>
);
}
},
{
title: '可售库存',
key: 'storage',
align: 'center',
render: (h, params) => {
return (
<span>{params.row.storage || 0}</span>
);
}
},
{
title: '销售价',
key: 'salePrice',
align: 'center',
render: (h, params) => {
return (
<span>{params.row.salePrice || 0}</span>
);
}
},
{
title: '更新时间',
key: 'editTime',
align: 'center',
render: (h, params) => {
return (
<span>{params.row.editTime || '-'}</span>
);
}
},
{
title: '操作',
key: 'action',
align: 'center',
render: (h, params) => {
return (
<action-group>
<i-button type="primary" size="small" onClick={() => this.editStore(params.row)}>库存编辑</i-button>
<i-button type="success" size="small" onClick={() => this.$router.push({
name: 'repository.inventory',
query: {
productSkn: params.row.productSkn
}
})}>库存分布</i-button>
</action-group>
);
}
}],
tableData: [],
pageData: {
total: 0,
current: 1,
pageSize: 20
},
shopData: {},
categoryValue: [],
filters: {
sknCode: {
label: 'SKN编码',
labelSpan: 6,
model: '',
holder: '',
fieldSpan: 18
},
brand: {
label: '选择品牌',
model: -1
},
maxSortId: null,
middleSortId: null,
smallSortId: null,
storageType: null,
}
};
}