|
@@ -501,7 +501,11 @@ public class ContractServiceImpl extends ServiceImpl<ContractMapper, Contract>
|
|
|
@Override
|
|
|
public Page<ContractBudgetVo> getProfitBudgetPage(ContractSelectDto dto) {
|
|
|
IWrapper<Contract> wrapper = getProfitBudgetPageWrapper(dto);
|
|
|
+ return getProfitBudgetPage(dto, wrapper);
|
|
|
+ }
|
|
|
|
|
|
+ @Override
|
|
|
+ public Page<ContractBudgetVo> getProfitBudgetPage(ContractSelectDto dto, IWrapper<Contract> wrapper) {
|
|
|
|
|
|
Page<ContractBudgetVo> page = this.baseMapper.getProfitBudgetPage(dto.getPage(), wrapper);
|
|
|
List<ContractBudgetVo> list = page.getRecords();
|
|
@@ -689,7 +693,7 @@ public class ContractServiceImpl extends ServiceImpl<ContractMapper, Contract>
|
|
|
* @return
|
|
|
*/
|
|
|
private List<Contract> recursionOldContract(List<Long> contractIds) {
|
|
|
- List<Contract> contract = this.list(q -> q.in(Contract::getId, contractIds).in(Contract::getStatus, 10, 30, 60, 70, 99));
|
|
|
+ List<Contract> contract = this.list(q -> q.in(Contract::getId, contractIds).in(Contract::getStatus, 10, 30, 60, 70));
|
|
|
List<Long> contractIds1 = contract.stream().map(Contract::getOldContractId).distinct()
|
|
|
.filter(item -> ObjectUtil.isNotEmpty(item)).collect(Collectors.toList());
|
|
|
if (ObjectUtil.isNotEmpty(contractIds1)) {
|
|
@@ -1134,9 +1138,9 @@ public class ContractServiceImpl extends ServiceImpl<ContractMapper, Contract>
|
|
|
result.setBuyCityName(areaMapByIds.get(result.getBuyCityId()));
|
|
|
|
|
|
//赋值历史毛利图信息
|
|
|
- ContractSelectDto contractSelectDto = new ContractSelectDto();
|
|
|
- contractSelectDto.setId(result.getId());
|
|
|
- Page<ContractBudgetVo> profitBudgetPage = getProfitBudgetPage(contractSelectDto);
|
|
|
+ IWrapper<Contract> wrapper = IWrapper.<Contract>getWrapper().eq("t1.contractId", result.getId());
|
|
|
+ Page<ContractBudgetVo> profitBudgetPage = getProfitBudgetPage(new ContractSelectDto(), wrapper);
|
|
|
+
|
|
|
List<ContractBudgetVo> records = profitBudgetPage.getRecords();
|
|
|
if (ObjectUtil.isNotEmpty(records)) {
|
|
|
ContractBudgetVo contractBudgetVo = records.get(0);
|