|
|
@@ -316,4 +316,28 @@ public class KwOrderService {
|
|
|
query.addCriteria(criteria);
|
|
|
return getResult(query, params.getPage(), params.getPageSize());
|
|
|
}
|
|
|
+
|
|
|
+ /**
|
|
|
+ * @desc: 合同关联订单列表
|
|
|
+ * @author: yzc
|
|
|
+ * @date: 2023-07-27 17:05
|
|
|
+ * @Param params:
|
|
|
+ * @return: com.sckw.core.model.page.PageResult
|
|
|
+ */
|
|
|
+ public PageResult tradeOrderContractList(TradeOrderContractParam params) {
|
|
|
+ Long entId = LoginUserHolder.getEntId();
|
|
|
+ Query query = new Query();
|
|
|
+ Criteria criteria = new Criteria();
|
|
|
+ if (Objects.equals(params.getOrderType(), 1)) {
|
|
|
+ //采购订单
|
|
|
+ criteria.and("procureTopEntId").is(entId);
|
|
|
+ } else {
|
|
|
+ //销售订单
|
|
|
+ criteria.and("supplyTopEntId").is(entId);
|
|
|
+ }
|
|
|
+ List<Long> ids = StringUtils.splitStrToList(params.getContractIds(), ",", Long.class);
|
|
|
+ criteria.and("contractId").in(ids).and("delFlag").is(0);
|
|
|
+ query.addCriteria(criteria);
|
|
|
+ return getResult(query, params.getPage(), params.getPageSize());
|
|
|
+ }
|
|
|
}
|