diff --git a/src/main/java/com/zcloud/service/xgf/impl/XgfUserServiceImpl.java b/src/main/java/com/zcloud/service/xgf/impl/XgfUserServiceImpl.java index b7968877..9ba052a7 100644 --- a/src/main/java/com/zcloud/service/xgf/impl/XgfUserServiceImpl.java +++ b/src/main/java/com/zcloud/service/xgf/impl/XgfUserServiceImpl.java @@ -1030,8 +1030,26 @@ public class XgfUserServiceImpl implements XgfUserService { PageData entity = xgfUserMapper.findById(condition); entity.put("CHECK_STEP",info.getBACK_STEP()); xgfUserMapper.edit(entity); + + // 判断要不要清理委托书 + if (clearWeiTuo(flowEntity, info.getBACK_STEP())) { + condition.clear(); + condition.put("XGF_USER_DETAILS_ID", flows.getString("FLOWS_ID")); + PageData infoEntity = xgfUserDetailsMapper.findById(condition); + infoEntity.put("ATTORNEY", null); + xgfUserDetailsMapper.edit(infoEntity); + } } } + private boolean clearWeiTuo(PageData flowEntity,String backStep) throws Exception{ + if ("1".equals(flowEntity.getString("FLOWS_TYPE"))){ + return 1 <= Integer.parseInt(backStep); + } + if ("2".equals(flowEntity.getString("FLOWS_TYPE"))){ + return 0 <= Integer.parseInt(backStep); + } + return false; + } private void clearsInfo(PageData entity,String step) throws Exception { if ("0".equals(step)){ entity.put("APPOINT_ONE_USER_ID", "");