...
|
...
|
@@ -52,11 +52,22 @@ let tableCols = function() { |
|
|
title: '发货进度',
|
|
|
align: 'center',
|
|
|
render: function(h, params) {
|
|
|
let percent = 0;
|
|
|
|
|
|
if (params.row.sendNum && params.row.totalNum) {
|
|
|
percent = params.row.sendNum / params.row.totalNum;
|
|
|
|
|
|
if (percent > 1) {
|
|
|
percent = 100;
|
|
|
} else {
|
|
|
percent *= 100;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
return (
|
|
|
<div>
|
|
|
<div><i-progress percent={ params.row.sendNum / params.row.totalNum}
|
|
|
hide-info={true}></i-progress></div>
|
|
|
<div>{params.row.sendNum} / {params.row.totalNum}</div>
|
|
|
<div><i-progress percent={ percent} hide-info={true} ></i-progress></div>
|
|
|
<div>{params.row.sendNum || 0} / {params.row.totalNum || 0}</div>
|
|
|
</div>
|
|
|
);
|
|
|
},
|
...
|
...
|
@@ -69,11 +80,23 @@ let tableCols = function() { |
|
|
title: '入库进度',
|
|
|
align: 'center',
|
|
|
render: function(h, params) {
|
|
|
let percent = 0;
|
|
|
|
|
|
if (params.row.inStoreNum && params.row.totalNum) {
|
|
|
percent = params.row.inStoreNum / params.row.totalNum;
|
|
|
|
|
|
if (percent > 1) {
|
|
|
percent = 100;
|
|
|
} else {
|
|
|
percent *= 100;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
return (
|
|
|
<div>
|
|
|
<div><i-progress percent={ params.row.inStoreNum / params.row.totalNum}
|
|
|
<div><i-progress percent={ percent }
|
|
|
hide-info={true}></i-progress></div>
|
|
|
<div>{ params.row.inStoreNum } / {params.row.totalNum}</div>
|
|
|
<div>{ params.row.inStoreNum || 0} / {params.row.totalNum || 0}</div>
|
|
|
</div>
|
|
|
);
|
|
|
},
|
...
|
...
|
@@ -95,6 +118,7 @@ let tableCols = function() { |
|
|
{
|
|
|
title: '操作',
|
|
|
key: 'action',
|
|
|
width: 250,
|
|
|
align: 'center',
|
|
|
render: (h, params) => {
|
|
|
let status = params.row.auditStatus;
|
...
|
...
|
@@ -102,10 +126,10 @@ let tableCols = function() { |
|
|
if (status === 10) {
|
|
|
return (
|
|
|
<div class="action-btn-row">
|
|
|
<i-button type="success" size="small" onClick={() => this.onClickInfo(params)}>查看</i-button>
|
|
|
<i-button type="primary" size="small" onClick={() => this.onClickEdit(params)}>编辑</i-button>
|
|
|
<i-button type="primary" size="small" onClick={() => this.onClickInfo(params)}>查看</i-button>
|
|
|
<i-button type="primary" size="small" onClick={() => this.onClickCommit(params)}>提交</i-button>
|
|
|
<i-button type="primary" size="small" onClick={() => this.onClickDelete(params)}>删除</i-button>
|
|
|
<i-button type="warning" size="small" onClick={() => this.onClickCommit(params)}>提交</i-button>
|
|
|
<i-button type="error" size="small" onClick={() => this.onClickDelete(params)}>删除</i-button>
|
|
|
</div>
|
|
|
);
|
|
|
|
...
|
...
|
@@ -113,7 +137,7 @@ let tableCols = function() { |
|
|
|
|
|
return (
|
|
|
<div class="action-btn-row">
|
|
|
<i-button type="primary" size="small" onClick={() => this.onClickInfo(params)}>查看</i-button>
|
|
|
<i-button type="success" size="small" onClick={() => this.onClickInfo(params)}>查看</i-button>
|
|
|
</div>
|
|
|
);
|
|
|
} else if (status === 40) {
|
...
|
...
|
@@ -121,31 +145,31 @@ let tableCols = function() { |
|
|
if (params.row.sendNum < params.row.totalNum) {
|
|
|
return (
|
|
|
<div class="action-btn-row">
|
|
|
<i-button type="primary" size="small" onClick={() => this.onClickInfo(params)}>查看</i-button>
|
|
|
<i-button type="primary" size="small" onClick={() => this.onClickDeliver(params)}>发货</i-button>
|
|
|
<i-button type="success" size="small" onClick={() => this.onClickInfo(params)}>查看</i-button>
|
|
|
<i-button type="info" size="small" onClick={() => this.onClickDeliver(params)}>发货</i-button>
|
|
|
</div>
|
|
|
);
|
|
|
|
|
|
} else {
|
|
|
return (
|
|
|
<div class="action-btn-row">
|
|
|
<i-button type="primary" size="small">查看</i-button>
|
|
|
<i-button type="success" size="small">查看</i-button>
|
|
|
</div>
|
|
|
);
|
|
|
}
|
|
|
} else if (status === 41) {
|
|
|
return (
|
|
|
<div class="action-btn-row">
|
|
|
<i-button type="success" size="small" onClick={() => this.onClickInfo(params)}>查看</i-button>
|
|
|
<i-button type="primary" size="small" onClick={() => this.onClickEdit(params)}>编辑</i-button>
|
|
|
<i-button type="primary" size="small" onClick={() => this.onClickInfo(params)}>查看</i-button>
|
|
|
<i-button type="primary" size="small" onClick={() => this.onClickCommit(params)}>提交</i-button>
|
|
|
<i-button type="primary" size="small" onClick={() => this.onClickDelete(params)}>删除</i-button>
|
|
|
<i-button type="warning" size="small" onClick={() => this.onClickCommit(params)}>提交</i-button>
|
|
|
<i-button type="error" size="small" onClick={() => this.onClickDelete(params)}>删除</i-button>
|
|
|
</div>
|
|
|
);
|
|
|
} else {
|
|
|
return (
|
|
|
<div class="action-btn-row">
|
|
|
<i-button type="primary" size="small">查看</i-button>
|
|
|
<i-button type="success" size="small">查看</i-button>
|
|
|
</div>
|
|
|
);
|
|
|
}
|
...
|
...
|
|