|
@@ -48,11 +48,13 @@ import java.math.BigInteger;
|
|
|
import java.net.URL;
|
|
|
|
|
|
import javax.servlet.http.HttpServletResponse;
|
|
|
+import javax.swing.text.html.parser.Entity;
|
|
|
import java.text.DecimalFormat;
|
|
|
import java.text.SimpleDateFormat;
|
|
|
import java.util.*;
|
|
|
import java.io.*;
|
|
|
import java.net.URLDecoder;
|
|
|
+import java.util.stream.Collectors;
|
|
|
|
|
|
/**
|
|
|
* <p>
|
|
@@ -263,6 +265,8 @@ public class ContractManagementInfoServiceImpl extends ServiceImpl<ContractManag
|
|
|
contractProcessInfo.setId(IdGenerator.generateUUID());
|
|
|
contractProcessInfo.setContractId(contractManagementInfo.getId());
|
|
|
boolean one = this.insert(contractManagementInfo);
|
|
|
+ boolean two = contractGoodsInfoService.insert(contractGoodsInfo);
|
|
|
+ boolean three = contractProcessInfoService.insert(contractProcessInfo);
|
|
|
// 根据类型进入审核
|
|
|
if ("1".equals(contractManagementInfo.getGoodsType())) {
|
|
|
//销售合同
|
|
@@ -462,8 +466,7 @@ public class ContractManagementInfoServiceImpl extends ServiceImpl<ContractManag
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- boolean two = contractGoodsInfoService.insert(contractGoodsInfo);
|
|
|
- boolean three = contractProcessInfoService.insert(contractProcessInfo);
|
|
|
+
|
|
|
cacheComponent.delPrefixKey(Const.ADMIN_CONTRACTINFO, contractManagementInfo.getCompId());
|
|
|
// 假如 都成功返回ok
|
|
|
if (one && two && three) {
|
|
@@ -2996,8 +2999,17 @@ public class ContractManagementInfoServiceImpl extends ServiceImpl<ContractManag
|
|
|
//查合同下的车牌号,出库只能查到未出库的
|
|
|
List<TranCarInfo> tranCarInfoList = tranCarInfoService.selectList(new EntityWrapper<TranCarInfo>()
|
|
|
.eq("info_id", tranTaskInfo.getId()).eq("fleet_flag", "0").eq("tran_type", "1").eq("submit", "0")
|
|
|
- .last("ORDER BY CONVERT ( car_no USING gbk ) ASC"));
|
|
|
+// .last("ORDER BY CONVERT ( car_no USING gbk ) ASC")
|
|
|
+ .orderBy("tran_car_no",true));
|
|
|
if (!CollectionUtils.isEmpty(tranCarInfoList)) {
|
|
|
+ List<String> carList = new ArrayList<>();
|
|
|
+ List<TranCarInfo> newCarList = new ArrayList<>();
|
|
|
+ for(int i = 0; i < tranCarInfoList.size(); i++){
|
|
|
+ if(!carList.contains(tranCarInfoList.get(i).getCarNo())){
|
|
|
+ carList.add(tranCarInfoList.get(i).getCarNo());
|
|
|
+ newCarList.add(tranCarInfoList.get(i));
|
|
|
+ }
|
|
|
+ }
|
|
|
contractManagementInfo.setTranCarInfoList(tranCarInfoList);
|
|
|
}
|
|
|
List<TranCarInfo> tranCarInfoList1 = tranCarInfoService.selectList(new EntityWrapper<TranCarInfo>()
|
|
@@ -3054,9 +3066,18 @@ public class ContractManagementInfoServiceImpl extends ServiceImpl<ContractManag
|
|
|
//查移库任务编号下的车牌号,移库出库只能查到未出库的
|
|
|
List<TranCarInfo> tranCarInfoList = tranCarInfoService.selectList(new EntityWrapper<TranCarInfo>()
|
|
|
.eq("info_id", tranTaskInfo.getId()).eq("fleet_flag", "0").eq("tran_type", "1").eq("submit", "0")
|
|
|
- .last("ORDER BY CONVERT ( car_no USING gbk ) ASC"));
|
|
|
+// .last("ORDER BY CONVERT ( car_no USING gbk ) ASC")
|
|
|
+ .orderBy("tran_car_no",true));
|
|
|
if (!CollectionUtils.isEmpty(tranCarInfoList)) {
|
|
|
- contractManagementInfo1.setTranCarInfoList(tranCarInfoList);
|
|
|
+ List<String> carList = new ArrayList<>();
|
|
|
+ List<TranCarInfo> newCarList = new ArrayList<>();
|
|
|
+ for(int i = 0; i < tranCarInfoList.size(); i++){
|
|
|
+ if(!carList.contains(tranCarInfoList.get(i).getCarNo())){
|
|
|
+ carList.add(tranCarInfoList.get(i).getCarNo());
|
|
|
+ newCarList.add(tranCarInfoList.get(i));
|
|
|
+ }
|
|
|
+ }
|
|
|
+ contractManagementInfo1.setTranCarInfoList(newCarList);
|
|
|
}
|
|
|
List<TranCarInfo> tranCarInfoList1 = tranCarInfoService.selectList(new EntityWrapper<TranCarInfo>()
|
|
|
.eq("info_id", tranTaskInfo.getId())
|