| | |
| | | private String title; |
| | | @ApiModelProperty(value = "账单编号") |
| | | private String code; |
| | | @ApiModelProperty(value = "类型 0合同账单 1自建账单", example = "1") |
| | | @ExcelColumn(name="账单来源",index = 12,width = 6,valueMapping = "0=合同账单;1=自建账单;") |
| | | @ApiModelProperty(value = "类型 0合同账单 1自建账单 2退款账单", example = "1") |
| | | @ExcelColumn(name="账单来源",index = 12,width = 6,valueMapping = "0=合同账单;1=自建账单;2=退款账单") |
| | | private Integer type; |
| | | |
| | | @ApiModelProperty(value = "状态 0开始;1关闭;", example = "1") |
| | |
| | | ); |
| | | |
| | | //房源数据 |
| | | ywContractBill.setYwContractRoomList(ywContractRoomMapper.selectJoinList(YwContractRoom.class,new MPJLambdaWrapper<YwContractRoom>() |
| | | ywContractBill.setYwContractRoomList( |
| | | ywContractRoomMapper.selectJoinList(YwContractRoom.class,new MPJLambdaWrapper<YwContractRoom>() |
| | | .selectAll(YwContractRoom.class) |
| | | .selectAs(YwProject::getName,YwRoom::getProjectName) |
| | | .selectAs(YwFloor::getName,YwRoom::getFloorName) |
| | |
| | | .leftJoin(YwBuilding.class,YwBuilding::getId,YwRoom::getBuildingId) |
| | | .eq(Constants.equalsInteger(ywContractBill.getType(),Constants.ONE),YwContractRoom::getContractId,id) |
| | | .eq(Constants.equalsInteger(ywContractBill.getType(),Constants.ONE),YwContractRoom::getType,Constants.ONE) |
| | | .eq(Constants.equalsInteger(ywContractBill.getType(),Constants.ZERO),YwContractRoom::getContractId,ywContractBill.getContractId()) |
| | | .eq(Constants.equalsInteger(ywContractBill.getType(),Constants.ZERO),YwContractRoom::getType,Constants.ZERO) |
| | | .eq(Constants.equalsInteger(ywContractBill.getType(),Constants.ZERO) || Constants.equalsInteger(ywContractBill.getType(),Constants.TWO),YwContractRoom::getContractId,ywContractBill.getContractId()) |
| | | .eq(Constants.equalsInteger(ywContractBill.getType(),Constants.ZERO)| Constants.equalsInteger(ywContractBill.getType(),Constants.TWO),YwContractRoom::getType,Constants.ZERO) |
| | | )); |
| | | |
| | | //收支记录 |
| | |
| | | for (YwContractBill ywContractBill:ywContractBillList) { |
| | | if(Constants.equalsInteger(ywContractBill.getType(),Constants.ZERO)){ |
| | | ywContractBill.setYwContractRoomList( |
| | | ywContractRoomList.stream().filter(i->Constants.equalsInteger(i.getType(),Constants.ZERO)&&Constants.equalsInteger(i.getContractId(),ywContractBill.getContractId())).collect(Collectors.toList()) |
| | | ywContractRoomList.stream().filter(i->(Constants.equalsInteger(i.getType(),Constants.TWO)||Constants.equalsInteger(i.getType(),Constants.ZERO))&&Constants.equalsInteger(i.getContractId(),ywContractBill.getContractId())).collect(Collectors.toList()) |
| | | ); |
| | | }else{ |
| | | ywContractBill.setYwContractRoomList( |
| | |
| | | for(YwContractBill addBill : param.getAddBillList()){ |
| | | addBill.setIsdeleted(Constants.ZERO); |
| | | addBill.setContractId(param.getId()); |
| | | addBill.setType(Constants.ONE); |
| | | addBill.setType(Constants.TWO); |
| | | addBill.setStatus(Constants.ZERO); |
| | | if(Constants.equalsInteger(addBill.getFeeType(),Constants.ONE)){ |
| | | addBill.setStartDate(addBill.getPlanPayDate()); |