|
@@ -425,29 +425,28 @@ public class MQTask implements InitializingBean {
|
|
|
|
|
|
|
|
|
|
|
|
-
|
|
|
- @Scheduled(cron = "0 0/3 * * * ?")
|
|
|
+ @Scheduled(cron = "0 0/30 * * * ?")
|
|
|
public void syncSendBackCustomer()throws Exception{
|
|
|
CustomerCommon customerCommon = new CustomerCommon();
|
|
|
customerCommon.setRelationBackStatus(2);
|
|
|
List<CustomerCommon> customerCommonList = customerCommonService.listCustomerCommon(customerCommon);
|
|
|
for(int i=0;i<customerCommonList.size();i++){
|
|
|
CustomerCommon cc = customerCommonList.get(i);
|
|
|
- if(!StringUtils.isEmpty(cc.getRelationBackLogisticsCompany()) && StringUtils.isEmpty(cc.getRelationBackLogisticsNo())){
|
|
|
+ if(!StringUtils.isEmpty(cc.getRelationBackLogisticsCompany()) && !StringUtils.isEmpty(cc.getRelationBackLogisticsNo())){
|
|
|
JSONObject rst = kuaidi100.getExpressInfo(cc.getRelationBackLogisticsCompany(),cc.getRelationBackLogisticsNo());
|
|
|
if(rst.has("state") && rst.getInt("state") == 3){
|
|
|
+ CustomerCommon newCc = new CustomerCommon();
|
|
|
+ newCc.setRelationId(cc.getRelationId());
|
|
|
+ newCc.setRelationBackStatus(4);
|
|
|
+ newCc.setCustomerIsSolve(cc.getCustomerIsSolve());
|
|
|
+ Integer flag = customerCommonService.updateCustomerCommon(newCc);
|
|
|
+ if(flag < 1){
|
|
|
+ logger.info("====== 客诉寄回签收失败 :客诉id:"+cc.getCustomerId()+" ======");
|
|
|
+ }else{
|
|
|
+ logger.info("====== 客诉寄回签收成功 :客诉id:"+cc.getCustomerId()+" ======");
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
}
|
|
|
-
|
|
|
-
|
|
|
- public static void main(String[] args) {
|
|
|
- KuaiDi100 kuaiDi100 = new KuaiDi100();
|
|
|
- JSONObject rst = kuaiDi100.getExpressInfo("sto","3347947142695");
|
|
|
-
|
|
|
- }
|
|
|
-
|
|
|
-
|
|
|
}
|