|
@@ -4,6 +4,7 @@ import com.demo.wjj.bo.DisplaceDetailBo;
|
|
|
import com.demo.wjj.bo.DisplaceListBo;
|
|
|
import com.demo.wjj.mapper.DisplaceAuditMapper;
|
|
|
import com.demo.wjj.mapper.ExplainMapper;
|
|
|
+import com.demo.wjj.po.DiggerAgent;
|
|
|
import com.demo.wjj.po.DisplaceAudit;
|
|
|
import com.demo.wjj.po.Explain;
|
|
|
import com.demo.wjj.service.*;
|
|
@@ -40,6 +41,9 @@ public class DisplaceAuditServiceImpl implements DisplaceAuditService {
|
|
|
@Autowired
|
|
|
private ExplainMapper explainMapper;
|
|
|
|
|
|
+ @Autowired
|
|
|
+ private DiggerAgentService diggerAgentService;
|
|
|
+
|
|
|
@CommitTransactional
|
|
|
@Override
|
|
|
public boolean save(DisplaceAudit displaceAudit, boolean updateOperate) {
|
|
@@ -58,7 +62,7 @@ public class DisplaceAuditServiceImpl implements DisplaceAuditService {
|
|
|
|
|
|
@ReadOnlyTransactional
|
|
|
@Override
|
|
|
- public PageInfo<DisplaceListBo> queryUndoDisplaceList(String agentId, String openId, PageBean pageBean) {
|
|
|
+ public PageInfo<DisplaceListBo> queryUndoDisplaceList(String agentId, String openId, PageBean pageBean,String is_good) {
|
|
|
LOG.info("进入查询待审核的置换列表, agentId:{}, openId:{}, pageBean:{}", agentId, openId, pageBean);
|
|
|
if (StringUtils.isBlank(agentId)) {
|
|
|
LOG.info("agentId为空");
|
|
@@ -71,7 +75,7 @@ public class DisplaceAuditServiceImpl implements DisplaceAuditService {
|
|
|
}
|
|
|
|
|
|
PageHelper.startPage(pageBean.getPageNum(), pageBean.getPageSize(), true);
|
|
|
- List<DisplaceListBo> displaceListBos = displaceAuditMapper.selectDisplaceList(agentId, openId, DisplaceAudit.AUDIT_STATUS_UNDO);
|
|
|
+ List<DisplaceListBo> displaceListBos = displaceAuditMapper.selectDisplaceList(agentId, openId, DisplaceAudit.AUDIT_STATUS_UNDO,is_good);
|
|
|
displaceAssemblyService.assembleListAttrContent(displaceListBos);
|
|
|
LOG.info("退出查询待审核的列表");
|
|
|
return new PageInfo<>(displaceListBos);
|
|
@@ -89,11 +93,18 @@ public class DisplaceAuditServiceImpl implements DisplaceAuditService {
|
|
|
if("1".equals(type)){
|
|
|
displaceListBos = displaceAuditMapper.selectDisplaceOnList(agentId, new Date(), DisplaceAudit.AUDIT_STATUS_DONE);
|
|
|
}else if("2".equals(type)){
|
|
|
- displaceListBos = displaceAuditMapper.selectDisplaceSaleList(agentId, new Date(), DisplaceAudit.AUDIT_STATUS_DONE);
|
|
|
- }else if("3".equals(type)){
|
|
|
displaceListBos = displaceAuditMapper.selectDisplaceHaltList(agentId, new Date(), DisplaceAudit.AUDIT_STATUS_DONE);
|
|
|
+ }else if("3".equals(type)){
|
|
|
+ displaceListBos = displaceAuditMapper.selectDisplaceSaleList(agentId, new Date(), DisplaceAudit.AUDIT_STATUS_DONE);
|
|
|
}else{
|
|
|
- displaceListBos = displaceAuditMapper.selectDisplaceMyList(agentId, openId, new Date(), DisplaceAudit.AUDIT_STATUS_DONE);
|
|
|
+ DiggerAgent diggerAgent = diggerAgentService.getDiggerAgent(agentId, openId);
|
|
|
+ if (diggerAgent == null) {
|
|
|
+ LOG.info("未查找到车商信息, agentId:{}, openId:{}", agentId, openId);
|
|
|
+ return null;
|
|
|
+ }
|
|
|
+
|
|
|
+ PageHelper.startPage(pageBean.getPageNum(), pageBean.getPageSize(), true);
|
|
|
+ displaceListBos = displaceAuditMapper.selectMyList(agentId, new Date(), diggerAgent.getDaId());
|
|
|
}
|
|
|
displaceAssemblyService.assembleListAttrContent(displaceListBos);
|
|
|
LOG.info("退出查询置换列表");
|
|
@@ -109,7 +120,7 @@ public class DisplaceAuditServiceImpl implements DisplaceAuditService {
|
|
|
}
|
|
|
List<DisplaceListBo> displaceListBos=null;
|
|
|
PageHelper.startPage(pageBean.getPageNum(), pageBean.getPageSize(), true);
|
|
|
- displaceListBos = displaceAuditMapper.getDisplaceGoodSaleList(agentId, openId, new Date(), DisplaceAudit.AUDIT_STATUS_DONE);
|
|
|
+ displaceListBos = displaceAuditMapper.getDisplaceGoodSaleList(agentId, openId, new Date(), DisplaceAudit.AUDIT_STATUS_UNGROUND);
|
|
|
displaceAssemblyService.assembleListAttrContent(displaceListBos);
|
|
|
LOG.info("退出查询置换列表");
|
|
|
return new PageInfo<>(displaceListBos);
|
|
@@ -142,15 +153,20 @@ public class DisplaceAuditServiceImpl implements DisplaceAuditService {
|
|
|
}
|
|
|
|
|
|
PageHelper.startPage(pageBean.getPageNum(), pageBean.getPageSize(), true);
|
|
|
- List<DisplaceListBo> displaceListBos = displaceAuditMapper.selectDisplaceConfirmList(agentId, openId, DisplaceAudit.AUDIT_STATUS_UNGROUND);
|
|
|
+ List<DisplaceListBo> displaceListBos = displaceAuditMapper.selectDisplaceConfirmList(agentId, openId, DisplaceAudit.AUDIT_STATUS_ROUND);
|
|
|
displaceAssemblyService.assembleListAttrContent(displaceListBos);
|
|
|
LOG.info("退出查询待审核的列表");
|
|
|
return new PageInfo<>(displaceListBos);
|
|
|
}
|
|
|
|
|
|
+ @Override
|
|
|
+ public int updateByDisplaceId(String displaceId, String ifDeposit,String storage) {
|
|
|
+ return displaceAuditMapper.updateByDisplaceId(displaceId,ifDeposit,storage);
|
|
|
+ }
|
|
|
+
|
|
|
@ReadOnlyTransactional
|
|
|
@Override
|
|
|
- public PageInfo<DisplaceListBo> queryDoneDisplaceList(String agentId, String openId, PageBean pageBean) {
|
|
|
+ public PageInfo<DisplaceListBo> queryDoneDisplaceList(String agentId, String openId, PageBean pageBean,String is_good) {
|
|
|
LOG.info("进入查询已审核的置换列表, agentId:{}, openId:{}, pageBean:{}", agentId, openId, pageBean);
|
|
|
if (StringUtils.isBlank(agentId)) {
|
|
|
LOG.info("agentId为空");
|
|
@@ -163,7 +179,7 @@ public class DisplaceAuditServiceImpl implements DisplaceAuditService {
|
|
|
}
|
|
|
|
|
|
PageHelper.startPage(pageBean.getPageNum(), pageBean.getPageSize(), true);
|
|
|
- List<DisplaceListBo> displaceListBos = displaceAuditMapper.selectDisplaceList(agentId, openId, DisplaceAudit.AUDIT_STATUS_DONE);
|
|
|
+ List<DisplaceListBo> displaceListBos = displaceAuditMapper.selectDisplaceList(agentId, openId, DisplaceAudit.AUDIT_STATUS_DONE, is_good);
|
|
|
displaceAssemblyService.assembleListAttrContent(displaceListBos);
|
|
|
LOG.info("退出查询已审核的置换列表");
|
|
|
return new PageInfo<>(displaceListBos);
|
|
@@ -211,6 +227,19 @@ public class DisplaceAuditServiceImpl implements DisplaceAuditService {
|
|
|
}
|
|
|
|
|
|
@Override
|
|
|
+ public DisplaceAudit selectDisplaceAuditByDisplaceId(String displaceId) {
|
|
|
+ LOG.info("调用获取置换审核, displaceId:{}", displaceId);
|
|
|
+ if (StringUtils.isBlank(displaceId)) {
|
|
|
+ LOG.info("displaceId为空");
|
|
|
+ return null;
|
|
|
+ }
|
|
|
+
|
|
|
+ DisplaceAudit displaceAudit = displaceAuditMapper.selectDisplaceAudit(displaceId);
|
|
|
+ LOG.info("退出获取置换审核, displaceAudit:{}", displaceAudit);
|
|
|
+ return displaceAudit;
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
public int getRejectedDisplaceCount(String agentId, String openId) {
|
|
|
LOG.info("进入查询被驳回的置换设备数量, agentId:{}, openId:{}", agentId, openId);
|
|
|
|