Commit 975f804a by 庄冰

receiveIcpStatusNotify

parent 0796be4e
...@@ -563,6 +563,12 @@ class AliyunQcService{ ...@@ -563,6 +563,12 @@ class AliyunQcService{
// return system.getResultFail(-103, "该方案状态为" + ns.statusName + ",不能执行此操作"); // return system.getResultFail(-103, "该方案状态为" + ns.statusName + ",不能执行此操作");
// } // }
var solutionContent = ns.solutionContent; var solutionContent = ns.solutionContent;
var checkStatus = {ACCOUNT_REGISTERED: "完成账户注册", MATERIAL_SUBMITTED: "完成资料递交",
GXB_ACCEPT: "⼯信部已受理", GXB_REFUSE: "⼯信部不予受理", GXB_FAIL: "⼯信部未通过", GXB_SUCCESS: "工信部通过"
, CLOSE: "方案关闭"};
if(solutionContent.status && checkStatus[solutionContent.status]){
return system.getResultFail(-111, "方案已进入"+solutionContent.statusName+"流程,不能执行此操作");
}
//方案流程列表 //方案流程列表
var solutionFlowList = solutionContent.solutionFlowList || []; var solutionFlowList = solutionContent.solutionFlowList || [];
if (ab.status == "2") {//⽤户已上传 if (ab.status == "2") {//⽤户已上传
...@@ -573,6 +579,9 @@ class AliyunQcService{ ...@@ -573,6 +579,9 @@ class AliyunQcService{
solutionContent.statusName = this.icpSolutionStatusReference.USER_UPLOADED; solutionContent.statusName = this.icpSolutionStatusReference.USER_UPLOADED;
} }
if (ab.status == "4") {//⽤户已确认 if (ab.status == "4") {//⽤户已确认
if(solutionContent.status !="MATERIAL_UNCONFIRM"){
return system.getResultFail(-112, "操作失败,服务商递交⽂件后才能执行此操作");
}
solutionFlowList.push({ solutionFlowList.push({
status: "USER_CONFIRMED", statusName: this.icpSolutionStatusReference.USER_CONFIRMED, updated_at: new Date() status: "USER_CONFIRMED", statusName: this.icpSolutionStatusReference.USER_CONFIRMED, updated_at: new Date()
}); });
...@@ -585,6 +594,8 @@ class AliyunQcService{ ...@@ -585,6 +594,8 @@ class AliyunQcService{
}); });
solutionContent.status = "CLOSE"; solutionContent.status = "CLOSE";
solutionContent.statusName = this.icpSolutionStatusReference.CLOSE; solutionContent.statusName = this.icpSolutionStatusReference.CLOSE;
}else{
return system.getResultFail(-110, "状态错误");
} }
solutionContent.solutionFlowList = solutionFlowList; solutionContent.solutionFlowList = solutionFlowList;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment