Commit 1ddaf0e563cdd92ff34bcaccdf17b0af3fe8a78b

Authored by 房远帅
1 parent 7f9e40ca

楚江ERP:问题修改

@@ -128,7 +128,6 @@ public class CustomerCreditServiceImpl extends BaseMpServiceImpl<CustomerCreditM @@ -128,7 +128,6 @@ public class CustomerCreditServiceImpl extends BaseMpServiceImpl<CustomerCreditM
128 return getBaseMapper().query(vo); 128 return getBaseMapper().query(vo);
129 } 129 }
130 130
131 - @Cacheable(value = CustomerCredit.CACHE_NAME, key = "@cacheVariables.tenantId() + #id", unless = "#result == null")  
132 @Override 131 @Override
133 public CustomerCredit findById(String id) { 132 public CustomerCredit findById(String id) {
134 133
@@ -1561,7 +1560,6 @@ public class CustomerCreditServiceImpl extends BaseMpServiceImpl<CustomerCreditM @@ -1561,7 +1560,6 @@ public class CustomerCreditServiceImpl extends BaseMpServiceImpl<CustomerCreditM
1561 .orElseThrow(() -> new DefaultClientException("办事处 " + prefix + " 的编号已用尽 (001-999)")); 1560 .orElseThrow(() -> new DefaultClientException("办事处 " + prefix + " 的编号已用尽 (001-999)"));
1562 } 1561 }
1563 1562
1564 - @CacheEvict(value = CustomerCredit.CACHE_NAME, key = "@cacheVariables.tenantId() + #key")  
1565 @Override 1563 @Override
1566 public void cleanCacheByKey(Serializable key) { 1564 public void cleanCacheByKey(Serializable key) {
1567 1565
@@ -373,6 +373,11 @@ public class PurchaseOrderInfoServiceImpl extends BaseMpServiceImpl<PurchaseOrde @@ -373,6 +373,11 @@ public class PurchaseOrderInfoServiceImpl extends BaseMpServiceImpl<PurchaseOrde
373 .set(PurchaseOrderInfo::getStatus, "ISSUED")//已下发 373 .set(PurchaseOrderInfo::getStatus, "ISSUED")//已下发
374 .eq(PurchaseOrderInfo::getId, id); 374 .eq(PurchaseOrderInfo::getId, id);
375 getBaseMapper().update(updateWrapper); 375 getBaseMapper().update(updateWrapper);
  376 + } else if ("WAIT".equals(status)) {
  377 + LambdaUpdateWrapper<PurchaseOrderInfo> updateWrapper = Wrappers.lambdaUpdate(PurchaseOrderInfo.class)
  378 + .set(PurchaseOrderInfo::getStatus, status)
  379 + .eq(PurchaseOrderInfo::getId, id);
  380 + getBaseMapper().update(updateWrapper);
376 } else { 381 } else {
377 LambdaUpdateWrapper<PurchaseOrderInfo> updateWrapper = Wrappers.lambdaUpdate(PurchaseOrderInfo.class) 382 LambdaUpdateWrapper<PurchaseOrderInfo> updateWrapper = Wrappers.lambdaUpdate(PurchaseOrderInfo.class)
378 .set(PurchaseOrderInfo::getExamineStatus, status) 383 .set(PurchaseOrderInfo::getExamineStatus, status)
@@ -22,6 +22,7 @@ import com.lframework.starter.web.core.utils.PageResultUtil; @@ -22,6 +22,7 @@ import com.lframework.starter.web.core.utils.PageResultUtil;
22 import com.lframework.starter.web.inner.components.oplog.OtherOpLogType; 22 import com.lframework.starter.web.inner.components.oplog.OtherOpLogType;
23 import com.lframework.xingyun.sc.entity.DraftRequestCarTicket; 23 import com.lframework.xingyun.sc.entity.DraftRequestCarTicket;
24 import com.lframework.xingyun.sc.mappers.DraftRequestCarTicketMapper; 24 import com.lframework.xingyun.sc.mappers.DraftRequestCarTicketMapper;
  25 +import com.lframework.xingyun.sc.service.order.PurchaseOrderInfoService;
25 import com.lframework.xingyun.sc.service.shipments.car.DraftRequestCarTicketService; 26 import com.lframework.xingyun.sc.service.shipments.car.DraftRequestCarTicketService;
26 import com.lframework.xingyun.sc.vo.shipments.car.*; 27 import com.lframework.xingyun.sc.vo.shipments.car.*;
27 import org.apache.commons.collections.CollectionUtils; 28 import org.apache.commons.collections.CollectionUtils;
@@ -41,6 +42,8 @@ public class DraftRequestCarTicketServiceImpl extends BaseMpServiceImpl<DraftReq @@ -41,6 +42,8 @@ public class DraftRequestCarTicketServiceImpl extends BaseMpServiceImpl<DraftReq
41 private FlowInstanceWrapperService flowInstanceWrapperService; 42 private FlowInstanceWrapperService flowInstanceWrapperService;
42 @Resource 43 @Resource
43 private FlowTaskWrapperMapper flowTaskWrapperMapper; 44 private FlowTaskWrapperMapper flowTaskWrapperMapper;
  45 + @Resource
  46 + private PurchaseOrderInfoService purchaseOrderInfoService;
44 47
45 @Override 48 @Override
46 public PageResult<DraftRequestCarTicket> query(Integer pageIndex, Integer pageSize, QueryDraftRequestCarTicketVo vo) { 49 public PageResult<DraftRequestCarTicket> query(Integer pageIndex, Integer pageSize, QueryDraftRequestCarTicketVo vo) {
@@ -93,6 +96,9 @@ public class DraftRequestCarTicketServiceImpl extends BaseMpServiceImpl<DraftReq @@ -93,6 +96,9 @@ public class DraftRequestCarTicketServiceImpl extends BaseMpServiceImpl<DraftReq
93 if (CollectionUtils.isNotEmpty(query)) { 96 if (CollectionUtils.isNotEmpty(query)) {
94 return query.get(0).getId(); 97 return query.get(0).getId();
95 } 98 }
  99 + if (StringUtils.isNotEmpty(vo.getPurchaseOrderId())) {
  100 + purchaseOrderInfoService.updateStatus(vo.getPurchaseOrderId(), "WAIT");
  101 + }
96 102
97 DraftRequestCarTicket data = new DraftRequestCarTicket(); 103 DraftRequestCarTicket data = new DraftRequestCarTicket();
98 data.setId(IdUtil.getId()); 104 data.setId(IdUtil.getId());
@@ -146,6 +152,8 @@ public class DraftRequestCarTicketServiceImpl extends BaseMpServiceImpl<DraftReq @@ -146,6 +152,8 @@ public class DraftRequestCarTicketServiceImpl extends BaseMpServiceImpl<DraftReq
146 } 152 }
147 if (!StringUtil.isBlank(vo.getStatus())) { 153 if (!StringUtil.isBlank(vo.getStatus())) {
148 data.setStatus(vo.getStatus()); 154 data.setStatus(vo.getStatus());
  155 + } else {
  156 + data.setStatus("AUDIT");
149 } 157 }
150 158
151 getBaseMapper().insert(data); 159 getBaseMapper().insert(data);