组装参数方法

2024年8月15日 11:43:41
This commit is contained in:
xiang2lin 2024-08-15 11:43:46 +08:00
parent 4612125c75
commit 3c6cd595ca
1 changed files with 40 additions and 37 deletions

View File

@ -23,10 +23,9 @@ import com.hzya.frame.grpU8.nxproof.pubauditlog.dao.IPubAuditLogDao;
import com.hzya.frame.grpU8.nxproof.pubauditlog.entity.PubAuditLogEntity; import com.hzya.frame.grpU8.nxproof.pubauditlog.entity.PubAuditLogEntity;
import com.hzya.frame.grpU8.nxproof.pubobjflow.dao.IPubObjFlowDao; import com.hzya.frame.grpU8.nxproof.pubobjflow.dao.IPubObjFlowDao;
import com.hzya.frame.grpU8.nxproof.pubobjflow.entity.PubObjFlowEntity; import com.hzya.frame.grpU8.nxproof.pubobjflow.entity.PubObjFlowEntity;
import com.hzya.frame.seeyon.enums.ColEventTypeEnum;
import com.hzya.frame.sysnew.application.entity.SysExtensionApiEntity;
import com.hzya.frame.mdm.entity.MdmDto; import com.hzya.frame.mdm.entity.MdmDto;
import com.hzya.frame.seeyon.enums.ColEventTypeEnum; import com.hzya.frame.seeyon.enums.ColEventTypeEnum;
import com.hzya.frame.sysnew.application.entity.SysExtensionApiEntity;
import com.hzya.frame.web.entity.BaseResult; import com.hzya.frame.web.entity.BaseResult;
import com.hzya.frame.web.exception.BaseSystemException; import com.hzya.frame.web.exception.BaseSystemException;
import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.LogManager;
@ -672,6 +671,31 @@ public class OerDjmlServiceImpl implements IOerDjmlService {
gbiZbsyrecAllEntity.setKjnd(oerDjmlAllEntities.get(0).getKjnd()); gbiZbsyrecAllEntity.setKjnd(oerDjmlAllEntities.get(0).getKjnd());
gbiZbsyrecAllEntity.setDjflmx(Integer.valueOf(oerDjmlAllEntities.get(0).getMlId())); gbiZbsyrecAllEntity.setDjflmx(Integer.valueOf(oerDjmlAllEntities.get(0).getMlId()));
gbiZbsyrecAllEntity.setModule("'OER'"); gbiZbsyrecAllEntity.setModule("'OER'");
gbiZbsyrecAllEntity.setDjzt("0");
iOerDjmlDao.updateGbiZbsyrecByDjid(gbiZbsyrecAllEntity);
}else {
return BaseResult.getFailureMessageEntity("根据单据编号存在多条报销单");
}
}else if(ColEventTypeEnum.ONPROCESSFINISHED.getType().equals(entity.getLclb())){//流程结束
OerDjmlEntity oerDjmlAllEntity = new OerDjmlEntity();
oerDjmlAllEntity.setDjbh(entity.getDjbh());
List<OerDjmlEntity> oerDjmlAllEntities = iOerDjmlDao.queryOerDjml(oerDjmlAllEntity);
if(oerDjmlAllEntities != null && oerDjmlAllEntities.size() == 1){
//修改状态
oerDjmlAllEntity.setMlId(oerDjmlAllEntities.get(0).getMlId());
oerDjmlAllEntity.setZt(entity.getZt());
iOerDjmlDao.updateOerDjmlZt(oerDjmlAllEntity);
}else {
return BaseResult.getFailureMessageEntity("根据单据编号存在多条报销单");
}
}else {
return BaseResult.getFailureMessageEntity("流程类别错误");
}
return null;
}
/** /**
* 保存方法前先调这个方法 组装参数 * 保存方法前先调这个方法 组装参数
* *
@ -819,7 +843,7 @@ public class OerDjmlServiceImpl implements IOerDjmlService {
//支付方式为个人公务卡时 可以选择 经办人负责人其他 //支付方式为个人公务卡时 可以选择 经办人负责人其他
jsfs.setRytype(""); jsfs.setRytype("");
//oa没有 //oa没有
jsfs.setYt(forson.getString("field0030")); jsfs.setYt(forson.getString(""));
jsfsList.add(jsfs); jsfsList.add(jsfs);
xh++; xh++;
} }
@ -833,40 +857,9 @@ public class OerDjmlServiceImpl implements IOerDjmlService {
logger.error("保存报销单之前组装参数出错",ex); logger.error("保存报销单之前组装参数出错",ex);
} }
return null; return null;
}
gbiZbsyrecAllEntity.setDjzt("0");
iOerDjmlDao.updateGbiZbsyrecByDjid(gbiZbsyrecAllEntity);
}else {
return BaseResult.getFailureMessageEntity("根据单据编号存在多条报销单");
}
}else if(ColEventTypeEnum.ONPROCESSFINISHED.getType().equals(entity.getLclb())){//流程结束
OerDjmlEntity oerDjmlAllEntity = new OerDjmlEntity();
oerDjmlAllEntity.setDjbh(entity.getDjbh());
List<OerDjmlEntity> oerDjmlAllEntities = iOerDjmlDao.queryOerDjml(oerDjmlAllEntity);
if(oerDjmlAllEntities != null && oerDjmlAllEntities.size() == 1){
//修改状态
oerDjmlAllEntity.setMlId(oerDjmlAllEntities.get(0).getMlId());
oerDjmlAllEntity.setZt(entity.getZt());
iOerDjmlDao.updateOerDjmlZt(oerDjmlAllEntity);
}else {
return BaseResult.getFailureMessageEntity("根据单据编号存在多条报销单");
}
}else {
return BaseResult.getFailureMessageEntity("流程类别错误");
} }
/**
* code和name拼接[]
* @param code
* @param name
* @return 格式03[公务卡]
*/
private String spliceStr(String code,String name){
String template = "{}[{}]";
return StrUtil.format(template,code,name);
}
return null;
}
/** /**
* @Author lvleigang * @Author lvleigang
@ -894,4 +887,14 @@ public class OerDjmlServiceImpl implements IOerDjmlService {
} }
return flag; return flag;
} }
/**
* code和name拼接[]
* @param code
* @param name
* @return 格式03[公务卡]
*/
private String spliceStr(String code,String name){
String template = "{}[{}]";
return StrUtil.format(template,code,name);
}
} }