|
@ -933,7 +933,7 @@ public class VtbVerificationServiceImpl extends ServiceImpl<VtbVerificationMappe |
|
|
|
|
|
|
|
|
//保存
|
|
|
//保存
|
|
|
this.saveOrUpdate(verification); |
|
|
this.saveOrUpdate(verification); |
|
|
this.commitSy(activity,sysUser,verification,saleBizNames,bizBizNames,supplier); |
|
|
this.commitSy(activity,sysUser,verification,saleBizNames,bizBizNames,supplier,verificationBo.getDirectPayFlag()); |
|
|
this.updateById(verification); |
|
|
this.updateById(verification); |
|
|
if(!StringUtils.hasText(verification.getSyFormId())||!StringUtils.hasText(verification.getSyFlowId())){ |
|
|
if(!StringUtils.hasText(verification.getSyFormId())||!StringUtils.hasText(verification.getSyFlowId())){ |
|
|
Assert.throwEx("远程调用失败"); |
|
|
Assert.throwEx("远程调用失败"); |
|
@ -1118,12 +1118,17 @@ public class VtbVerificationServiceImpl extends ServiceImpl<VtbVerificationMappe |
|
|
* @param saleRegionNames |
|
|
* @param saleRegionNames |
|
|
* @param bizRegionNames |
|
|
* @param bizRegionNames |
|
|
*/ |
|
|
*/ |
|
|
private void commitSy(TbsActivity activity,SysUser sysUser,VtbVerification verification,String saleRegionNames,String bizRegionNames,BmsSupplier supplier){ |
|
|
private void commitSy(TbsActivity activity,SysUser sysUser,VtbVerification verification, |
|
|
Map<String, Object> data = buildSeeYonVerificationData(activity, sysUser, verification, saleRegionNames, bizRegionNames,supplier); |
|
|
String saleRegionNames,String bizRegionNames,BmsSupplier supplier,Integer isDirectPayFlag){ |
|
|
|
|
|
String templateCode = TbsSeeYonConst.CostCheckConf.Code(); |
|
|
|
|
|
if(isDirectPayFlag!=null&&isDirectPayFlag.equals(1)){ |
|
|
|
|
|
templateCode = TbsSeeYonConst.PayBillConf.Code(); |
|
|
|
|
|
} |
|
|
|
|
|
Map<String, Object> data = buildSeeYonVerificationData(activity, sysUser, verification, saleRegionNames, bizRegionNames,supplier,templateCode); |
|
|
String dataJson = JsonUtil.objectToJson(data); |
|
|
String dataJson = JsonUtil.objectToJson(data); |
|
|
log.warn("核销请求JSON,核销号:{}:{}",verification.getVerificationCode(),dataJson); |
|
|
log.warn("核销请求JSON,核销号:{}:{}",verification.getVerificationCode(),dataJson); |
|
|
BaseCreateProcessBo createProcess = new BaseCreateProcessBo(); |
|
|
BaseCreateProcessBo createProcess = new BaseCreateProcessBo(); |
|
|
createProcess.setTemplateCode(TbsSeeYonConst.CostCheckConf.Code()); |
|
|
createProcess.setTemplateCode(templateCode); |
|
|
createProcess.setMemberLoginName(sysUser.getSyAccount()); |
|
|
createProcess.setMemberLoginName(sysUser.getSyAccount()); |
|
|
createProcess.setSubjectTitle(TbsSeeYonConst.PRE_TITLE_VERIFICATION + verification.getRemark()); |
|
|
createProcess.setSubjectTitle(TbsSeeYonConst.PRE_TITLE_VERIFICATION + verification.getRemark()); |
|
|
createProcess.setTargetId(verification.getId()+""); |
|
|
createProcess.setTargetId(verification.getId()+""); |
|
@ -1134,14 +1139,14 @@ public class VtbVerificationServiceImpl extends ServiceImpl<VtbVerificationMappe |
|
|
} |
|
|
} |
|
|
String flowId = flowIdResult.getData(); |
|
|
String flowId = flowIdResult.getData(); |
|
|
String formId = null; |
|
|
String formId = null; |
|
|
R<String> formIdResult = seeYonService.getFormId(TbsSeeYonConst.CostCheckConf.Code(),verification.getId()); |
|
|
R<String> formIdResult = seeYonService.getFormId(templateCode,verification.getId()); |
|
|
if(formIdResult.getStatus()==200){ |
|
|
if(formIdResult.getStatus()==200){ |
|
|
formId = formIdResult.getData(); |
|
|
formId = formIdResult.getData(); |
|
|
} |
|
|
} |
|
|
verification.setSyFlowId(flowId); |
|
|
verification.setSyFlowId(flowId); |
|
|
verification.setSyFormId(formId); |
|
|
verification.setSyFormId(formId); |
|
|
//创建流程后回调
|
|
|
//创建流程后回调
|
|
|
BaseCreateCallbackBo callbackBo = new BaseCreateCallbackBo(TbsSeeYonConst.CostCheckConf.Code(),verification.getId()+""); |
|
|
BaseCreateCallbackBo callbackBo = new BaseCreateCallbackBo(templateCode,verification.getId()+""); |
|
|
seeYonService.createCallbackStatus(callbackBo); |
|
|
seeYonService.createCallbackStatus(callbackBo); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
@ -1165,12 +1170,13 @@ public class VtbVerificationServiceImpl extends ServiceImpl<VtbVerificationMappe |
|
|
temp.setSupplierName(supplier.getSupplierName()); |
|
|
temp.setSupplierName(supplier.getSupplierName()); |
|
|
temp.setSupplierCode(supplier.getSupplierCode()); |
|
|
temp.setSupplierCode(supplier.getSupplierCode()); |
|
|
temp.setAmount(activity.getTotalAmount().subtract(activity.getUsedAmount())); |
|
|
temp.setAmount(activity.getTotalAmount().subtract(activity.getUsedAmount())); |
|
|
return buildSeeYonVerificationData(activity,sysUser,temp,saleBizNames,bizBizNames,supplier); |
|
|
String templateCode = TbsSeeYonConst.CostCheckConf.Code(); |
|
|
|
|
|
return buildSeeYonVerificationData(activity,sysUser,temp,saleBizNames,bizBizNames,supplier,templateCode); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@NotNull |
|
|
@NotNull |
|
|
@Override |
|
|
@Override |
|
|
public Map<String, Object> buildSeeYonVerificationData(TbsActivity activity, SysUser sysUser, VtbVerification verification, String saleRegionNames, String bizRegionNames,BmsSupplier supplier) { |
|
|
public Map<String, Object> buildSeeYonVerificationData(TbsActivity activity, SysUser sysUser, VtbVerification verification, String saleRegionNames, String bizRegionNames,BmsSupplier supplier,String templateCode) { |
|
|
Map<String, Object> data = new HashMap<>(20); |
|
|
Map<String, Object> data = new HashMap<>(20); |
|
|
data.put("costApplyCode", verification.getVerificationCode()); |
|
|
data.put("costApplyCode", verification.getVerificationCode()); |
|
|
data.put("applyUserCode", sysUser.getCode()); |
|
|
data.put("applyUserCode", sysUser.getCode()); |
|
@ -1183,7 +1189,7 @@ public class VtbVerificationServiceImpl extends ServiceImpl<VtbVerificationMappe |
|
|
data.put("orgId", verification.getId()); |
|
|
data.put("orgId", verification.getId()); |
|
|
data.put("targetId", verification.getId()); |
|
|
data.put("targetId", verification.getId()); |
|
|
data.put("targetCode", verification.getVerificationCode()); |
|
|
data.put("targetCode", verification.getVerificationCode()); |
|
|
data.put("exsp1",TbsSeeYonConst.CostCheckConf.Code()); |
|
|
data.put("exsp1",templateCode); |
|
|
data.put("jinE", verification.getAmount().toString()); |
|
|
data.put("jinE", verification.getAmount().toString()); |
|
|
data.put("money", verification.getAmount().toString()); |
|
|
data.put("money", verification.getAmount().toString()); |
|
|
data.put("auto_check", VerificationUtil.getAutoFlag()); |
|
|
data.put("auto_check", VerificationUtil.getAutoFlag()); |
|
|