Commit b2c53392 by jianshuqin

调整需求:广州沃伟科技发展有限公司不由总经办审核

parent 468e3435
...@@ -16,6 +16,7 @@ import com.blt.other.module.sys.model.CostReviewer; ...@@ -16,6 +16,7 @@ import com.blt.other.module.sys.model.CostReviewer;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Scope; import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component; import org.springframework.stereotype.Component;
import org.thymeleaf.util.StringUtils;
import javax.annotation.Resource; import javax.annotation.Resource;
import java.time.LocalDateTime; import java.time.LocalDateTime;
...@@ -33,8 +34,8 @@ import java.util.List; ...@@ -33,8 +34,8 @@ import java.util.List;
@Scope("prototype") @Scope("prototype")
public class HrCheckState extends CostState { public class HrCheckState extends CostState {
//@Autowired @Autowired
//FinancialCheckState financialCheckState; FinancialCheckState financialCheckState;
@Resource @Resource
GeneralManagerCheckState generalManagerCheckState; GeneralManagerCheckState generalManagerCheckState;
@Resource @Resource
...@@ -59,13 +60,13 @@ public class HrCheckState extends CostState { ...@@ -59,13 +60,13 @@ public class HrCheckState extends CostState {
//如果不需要审核 直接通过 //如果不需要审核 直接通过
if (!costTemplate.shouldHrCheck(costDomain)) { if (!costTemplate.shouldHrCheck(costDomain)) {
//2022-02-11后"广州沃伟科技发展有限公司"不用总经办审核,直接转财务审核
costDomain.setCostStatus(CostDomain.STATUS_MANAGER_CHECK); costDomain.setCostStatus(StringUtils.equals(costDomain.getCompanyNo(),"COM2008121838151") ? CostDomain.STATUS_FINANCIAL_CHECK : CostDomain.STATUS_MANAGER_CHECK);
costDomain.setLastModifyDate(LocalDateTime.now()); costDomain.setLastModifyDate(LocalDateTime.now());
costDao.updateById(costDomain); costDao.updateById(costDomain);
//流转状态 //流转状态
nextState(generalManagerCheckState); nextState(StringUtils.equals(costDomain.getCompanyNo(),"COM2008121838151") ? financialCheckState : generalManagerCheckState);
costSubscribe.subscribe(costContext); costSubscribe.subscribe(costContext);
return; return;
...@@ -82,13 +83,14 @@ public class HrCheckState extends CostState { ...@@ -82,13 +83,14 @@ public class HrCheckState extends CostState {
.costNo(costDomain.getCostNo()) .costNo(costDomain.getCostNo())
.isPassed(true) .isPassed(true)
.build(); .build();
costDomain.setCostStatus(CostDomain.STATUS_MANAGER_CHECK); //2022-02-11后"广州沃伟科技发展有限公司"不用总经办审核,直接转财务审核
costDomain.setCostStatus(StringUtils.equals(costDomain.getCompanyNo(),"COM2008121838151") ? CostDomain.STATUS_FINANCIAL_CHECK : CostDomain.STATUS_MANAGER_CHECK);
costDomain.setLastModifyDate(LocalDateTime.now()); costDomain.setLastModifyDate(LocalDateTime.now());
costDao.updateById(costDomain); costDao.updateById(costDomain);
costLogService.save(costDomain.getCostNo(), currentUserId, "行政审核通过", CostLogDomain.HR_PASS); costLogService.save(costDomain.getCostNo(), currentUserId, "行政审核通过", CostLogDomain.HR_PASS);
approvalHistoryService.save(approvalHistoryDomain); approvalHistoryService.save(approvalHistoryDomain);
nextState(generalManagerCheckState); nextState(StringUtils.equals(costDomain.getCompanyNo(),"COM2008121838151") ? financialCheckState: generalManagerCheckState);
//发布到总线尝试下个环节的自动审核 //发布到总线尝试下个环节的自动审核
costSubscribe.subscribe(costContext); costSubscribe.subscribe(costContext);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment