|
@@ -64,10 +64,10 @@ public class JyWorkContractService {
|
|
|
}
|
|
|
if (contractAmounts != null) {
|
|
|
if (StringUtils.isNotEmpty(contractAmounts[0])) {
|
|
|
- queryWrapper.ge("a.contract_amount", contractAmounts[0]);
|
|
|
+ queryWrapper.ge("a.contract_amount", Double.parseDouble(contractAmounts[0]));
|
|
|
}
|
|
|
- if (StringUtils.isNotEmpty(contractAmounts[1])) {
|
|
|
- queryWrapper.le("a.contract_amount", contractAmounts[1]);
|
|
|
+ if (contractAmounts.length>1 && StringUtils.isNotEmpty(contractAmounts[1])) {
|
|
|
+ queryWrapper.le("a.contract_amount", Double.parseDouble(contractAmounts[1]));
|
|
|
}
|
|
|
}
|
|
|
if (StringUtils.isNotEmpty(no)){
|
|
@@ -192,7 +192,7 @@ public class JyWorkContractService {
|
|
|
participant.setId(parId);
|
|
|
participant.setContractInfoId(id);
|
|
|
participant.setCustomerName(cw.getName());
|
|
|
- participant.setCustomerNo(cw.getNo());
|
|
|
+ participant.setCustomerNo(cw.getNumber());
|
|
|
participant.setCreateById(userDTO.getId());
|
|
|
participant.setCreateTime(workContractInfoDto.getCreateTime());
|
|
|
participant.setUpdateById(userDTO.getId());
|
|
@@ -277,7 +277,7 @@ public class JyWorkContractService {
|
|
|
byInfoId.forEach(cw->{
|
|
|
JyContractParticipant jyContractParticipant = new JyContractParticipant();
|
|
|
jyContractParticipant.setName(cw.getCustomerName());
|
|
|
- jyContractParticipant.setNo(cw.getCustomerNo());
|
|
|
+ jyContractParticipant.setNumber(cw.getCustomerNo());
|
|
|
list.add(jyContractParticipant);
|
|
|
});
|
|
|
dto.setCwWorkClientContactDTOList(list);
|
|
@@ -286,24 +286,37 @@ public class JyWorkContractService {
|
|
|
StringBuffer stringBuffer = new StringBuffer();
|
|
|
String newType="";
|
|
|
List<String> stringList = new ArrayList<>();
|
|
|
+ ArrayList<List<String>> jyWorkContractInfos = new ArrayList<>();
|
|
|
if (!info.getContractType().contains(",")){
|
|
|
- String type= jyWorkContractInfoMapper.findType(info.getContractType());
|
|
|
- info.setContractType(type);
|
|
|
+// String type= jyWorkContractInfoMapper.findType(info.getContractType());
|
|
|
+// info.setContractType(type);
|
|
|
+ stringList.add(info.getContractTypeFirst());
|
|
|
+ stringList.add(info.getContractType());
|
|
|
+ jyWorkContractInfos.add(stringList);
|
|
|
}else {
|
|
|
String[] split = info.getContractType().split(",");
|
|
|
+ Integer count=0;
|
|
|
+ //将切割好的二级类型进行遍历,与一级类型一起存放到数组中,方便前端级联回显
|
|
|
for (String s : split) {
|
|
|
- String type= jyWorkContractInfoMapper.findType2(s);
|
|
|
- stringBuffer.append(type+",");
|
|
|
- newType=stringBuffer.substring(0,stringBuffer.lastIndexOf(","));
|
|
|
- info.setContractType(newType);
|
|
|
- stringList.add(info.getContractType());
|
|
|
+// String type= jyWorkContractInfoMapper.findType2(s);
|
|
|
+// stringBuffer.append(type+",");
|
|
|
+// newType=stringBuffer.substring(0,stringBuffer.lastIndexOf(","));
|
|
|
+// info.setContractType(newType);
|
|
|
+// stringList.add(info.getContractType());
|
|
|
+ //创建一个集合副本,为了避免每次新增时会在stringList中进行追加,从而造成回显失败
|
|
|
+ List<String> newList = new ArrayList<>(stringList);
|
|
|
+ newList.add(info.getContractTypeFirst());
|
|
|
+ newList.add(s);
|
|
|
+ //将集合副本存入到集合中,在前端取值进行回显
|
|
|
+ jyWorkContractInfos.add(count++,newList);
|
|
|
}
|
|
|
+
|
|
|
}
|
|
|
|
|
|
List<String> result = Arrays.asList(dto.getContractType().split(","));
|
|
|
dto.setContractTypeList(result);
|
|
|
- ArrayList<List<String>> jyWorkContractInfos = new ArrayList<>();
|
|
|
- jyWorkContractInfos.add(stringList);
|
|
|
+
|
|
|
+// jyWorkContractInfos.add(stringList);
|
|
|
dto.setContractTypes(jyWorkContractInfos);
|
|
|
}
|
|
|
|