You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
66 lines
1.3 KiB
66 lines
1.3 KiB
function itemStatus(status) {
|
|
if(status == -1){
|
|
return '待设计工序'
|
|
} else if(status == 0){
|
|
return '生产中'
|
|
} else if(status == 1){
|
|
return '待生产'
|
|
} else if(status == 3){
|
|
return '已完成'
|
|
} else if(status == 4){
|
|
return '待分配'
|
|
}
|
|
return ''
|
|
}
|
|
|
|
// 已完成:3;已发货:5;生成中:0
|
|
function orderStatus(status, type) {
|
|
if(status == -1){
|
|
return '待提交'
|
|
} else if(status == 0 || status == 4){
|
|
if(type == 1){
|
|
return '采购中'
|
|
} else {
|
|
return '进行中'
|
|
}
|
|
} else if(status == 3){
|
|
return '已完成'
|
|
} else if(status == 5){
|
|
return ''
|
|
} else if(status == 6){
|
|
return '已终止'
|
|
}
|
|
return ''
|
|
}
|
|
|
|
// 生产单状态:待生产:1;已完成:3;生产中:0;已终止:6
|
|
function prodStatus(status) {
|
|
if(status == 1){
|
|
return '待生产'
|
|
} else if(status == 0){
|
|
return '生产中'
|
|
} else if(status == 3){
|
|
return '已完成'
|
|
} else if(status == 6){
|
|
return '已终止'
|
|
}
|
|
return ''
|
|
}
|
|
|
|
function orderType(type) {
|
|
if(type == 0){
|
|
return '加工件'
|
|
} else if(type == 1){
|
|
return '物料'
|
|
} else if(type == 2){
|
|
return '成品'
|
|
}
|
|
return ''
|
|
}
|
|
|
|
module.exports = {
|
|
itemStatus: itemStatus,
|
|
orderStatus: orderStatus,
|
|
prodStatus: prodStatus,
|
|
orderType: orderType
|
|
}
|