要货计划优化,新增要货计划的解锁锁定
This commit is contained in:
parent
83c577731a
commit
ce0a8121a9
@ -358,6 +358,21 @@ public class GoodsPlanController {
|
||||
backReqMap.put("response_info__c", trackingNumReason.getString("reason"));
|
||||
|
||||
//开始回写
|
||||
JSONObject unlockReq = crmRequestUtil.unlockCRM(goodsPlanId, "purchase_plan__c");
|
||||
//解锁
|
||||
if ("1".equals(goodsPlanData.getString("lock_status"))) {
|
||||
log.info("解锁");
|
||||
|
||||
JSONObject unlockRes = new JSONObject();
|
||||
|
||||
try {
|
||||
unlockRes = restTemplate.postForObject(URLConstant.UNLOCK_CRM_URL, unlockReq, JSONObject.class);
|
||||
} catch (RestClientException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
System.out.println("解锁" + unlockRes);
|
||||
}
|
||||
|
||||
JSONObject backReq = crmRequestUtil.updateCRM(backReqMap);
|
||||
|
||||
JSONObject backRes = new JSONObject();
|
||||
@ -369,6 +384,18 @@ public class GoodsPlanController {
|
||||
}
|
||||
|
||||
System.out.println("回写结果为:" + backRes);
|
||||
|
||||
log.info("上锁");
|
||||
JSONObject lockRes = new JSONObject();
|
||||
|
||||
try {
|
||||
lockRes = restTemplate.postForObject(URLConstant.LOCK_CRM_URL, unlockReq, JSONObject.class);
|
||||
} catch (RestClientException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
System.out.println("上锁" + lockRes);
|
||||
|
||||
continue;
|
||||
}
|
||||
|
||||
@ -449,6 +476,21 @@ public class GoodsPlanController {
|
||||
}
|
||||
|
||||
//开始回写
|
||||
JSONObject unlockReq = crmRequestUtil.unlockCRM(goodsPlanId, "purchase_plan__c");
|
||||
//解锁
|
||||
if ("1".equals(goodsPlanData.getString("lock_status"))) {
|
||||
log.info("解锁");
|
||||
|
||||
JSONObject unlockRes = new JSONObject();
|
||||
|
||||
try {
|
||||
unlockRes = restTemplate.postForObject(URLConstant.UNLOCK_CRM_URL, unlockReq, JSONObject.class);
|
||||
} catch (RestClientException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
System.out.println("解锁" + unlockRes);
|
||||
}
|
||||
|
||||
JSONObject backReq = crmRequestUtil.updateCRM(backReqMap);
|
||||
|
||||
System.out.println("回写请求为:" + JSON.parseObject(JSON.toJSONString(backReq)));
|
||||
@ -463,6 +505,17 @@ public class GoodsPlanController {
|
||||
|
||||
System.out.println("回写结果为:" + backRes);
|
||||
|
||||
log.info("上锁");
|
||||
JSONObject lockRes = new JSONObject();
|
||||
|
||||
try {
|
||||
lockRes = restTemplate.postForObject(URLConstant.LOCK_CRM_URL, unlockReq, JSONObject.class);
|
||||
} catch (RestClientException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
System.out.println("上锁" + lockRes);
|
||||
|
||||
//开始记录日志
|
||||
JSONObject logResMap = new JSONObject();
|
||||
try {
|
||||
|
Loading…
x
Reference in New Issue
Block a user