|
|
|
|
@ -39,11 +39,17 @@ import org.springframework.transaction.annotation.Transactional;
|
|
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
|
|
|
import org.springframework.context.event.EventListener;
|
|
|
|
|
import org.dromara.workflow.api.event.ProcessEvent;
|
|
|
|
|
import org.dromara.workflow.api.event.ProcessTaskEvent;
|
|
|
|
|
import org.dromara.common.core.utils.StreamUtils;
|
|
|
|
|
import org.dromara.system.api.RemoteUserService;
|
|
|
|
|
import org.dromara.system.api.domain.vo.RemoteUserVo;
|
|
|
|
|
import org.dromara.workflow.api.domain.RemoteFlowCopy;
|
|
|
|
|
|
|
|
|
|
import java.util.HashMap;
|
|
|
|
|
import java.util.List;
|
|
|
|
|
import java.util.Map;
|
|
|
|
|
import java.util.Collection;
|
|
|
|
|
import java.util.Collections;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 项目售后信息Service业务层处理
|
|
|
|
|
@ -64,6 +70,9 @@ public class ErpAfterSalesServiceImpl implements IErpAfterSalesService {
|
|
|
|
|
@DubboReference()
|
|
|
|
|
private RemoteCodeRuleService remoteCodeRuleService;
|
|
|
|
|
|
|
|
|
|
@DubboReference
|
|
|
|
|
private RemoteUserService remoteUserService;
|
|
|
|
|
|
|
|
|
|
private final IErpAfterSalesLaborCostsService laborCostsService;
|
|
|
|
|
private final IErpAfterSalesMaterialCostsService materialCostsService;
|
|
|
|
|
|
|
|
|
|
@ -129,6 +138,10 @@ public class ErpAfterSalesServiceImpl implements IErpAfterSalesService {
|
|
|
|
|
MPJLambdaWrapper<ErpAfterSales> lqw = JoinWrappers.lambda(ErpAfterSales.class)
|
|
|
|
|
.selectAll(ErpAfterSales.class)
|
|
|
|
|
.eq(ErpAfterSales::getDelFlag, "0")
|
|
|
|
|
// 按指定ID列表过滤(用于导出选中数据)
|
|
|
|
|
.in(StringUtils.isNotBlank(bo.getAfterSalesIds()), ErpAfterSales::getAfterSalesId,
|
|
|
|
|
StringUtils.isNotBlank(bo.getAfterSalesIds()) ? List.of(bo.getAfterSalesIds().split(","))
|
|
|
|
|
: null)
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getAfterSalesCode()), ErpAfterSales::getAfterSalesCode,
|
|
|
|
|
bo.getAfterSalesCode())
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getAfterSalesSubject()), ErpAfterSales::getAfterSalesSubject,
|
|
|
|
|
@ -161,7 +174,8 @@ public class ErpAfterSalesServiceImpl implements IErpAfterSalesService {
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getAfterSalesStatus()), ErpAfterSales::getAfterSalesStatus,
|
|
|
|
|
bo.getAfterSalesStatus())
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getFlowStatus()), ErpAfterSales::getFlowStatus, bo.getFlowStatus())
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getActiveFlag()), ErpAfterSales::getActiveFlag, bo.getActiveFlag());
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getActiveFlag()), ErpAfterSales::getActiveFlag, bo.getActiveFlag())
|
|
|
|
|
.orderByDesc(ErpAfterSales::getCreateTime);
|
|
|
|
|
return lqw;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@ -313,6 +327,7 @@ public class ErpAfterSalesServiceImpl implements IErpAfterSalesService {
|
|
|
|
|
bo.setVariables(new HashMap<>());
|
|
|
|
|
}
|
|
|
|
|
bo.getVariables().put("ignore", true);
|
|
|
|
|
|
|
|
|
|
RemoteStartProcess startProcess = new RemoteStartProcess();
|
|
|
|
|
startProcess.setBusinessId(bo.getAfterSalesId().toString());
|
|
|
|
|
startProcess.setFlowCode(bo.getFlowCode());
|
|
|
|
|
|