update 会所收入统计
This commit is contained in:
+1
-1
@@ -218,5 +218,5 @@ public interface PayWorkingGroupMapper extends BaseMapper<PayWorkingGroup> {
|
|||||||
|
|
||||||
AllMoney queryPageListDepartment33(@Param("departStatisticsSearch") DepartStatisticsSearch departStatisticsSearch, @Param("idList") List<String> idList);
|
AllMoney queryPageListDepartment33(@Param("departStatisticsSearch") DepartStatisticsSearch departStatisticsSearch, @Param("idList") List<String> idList);
|
||||||
|
|
||||||
IPage<AllProjectStatistics> queryPageListAllProjectMoney(Page<AllProjectStatistics> page, @Param(value = "allProjectStatisticsSearch") AllProjectStatisticsSearch allProjectStatisticsSearch, @Param("idList") List<String> idList);
|
List<AllProjectStatistics> queryListAllProjectMoney(@Param(value = "allProjectStatisticsSearch") AllProjectStatisticsSearch allProjectStatisticsSearch, @Param("idList") List<String> idList);
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -2217,7 +2217,7 @@
|
|||||||
</select>
|
</select>
|
||||||
|
|
||||||
<!-- 全所收入统计-->
|
<!-- 全所收入统计-->
|
||||||
<select id="queryPageListAllProjectMoney" resultType="com.jero.statistics.entity.AllProjectStatistics">
|
<select id="queryListAllProjectMoney" resultType="com.jero.statistics.entity.AllProjectStatistics">
|
||||||
select
|
select
|
||||||
sum(paidNoTaxAmount) as comeAllMoney,
|
sum(paidNoTaxAmount) as comeAllMoney,
|
||||||
sum(invoiceNoTaxAmount) as billMoney,
|
sum(invoiceNoTaxAmount) as billMoney,
|
||||||
|
|||||||
+1
-1
@@ -239,5 +239,5 @@ public interface IPayWorkingGroupService extends IService<PayWorkingGroup> {
|
|||||||
|
|
||||||
AllMoney queryPageListDepartment33(DepartStatisticsSearch departStatisticsSearch, List<String> idList);
|
AllMoney queryPageListDepartment33(DepartStatisticsSearch departStatisticsSearch, List<String> idList);
|
||||||
|
|
||||||
IPage<AllProjectStatistics> queryPageListAllProjectMoney(Page<AllProjectStatistics> page, AllProjectStatisticsSearch allProjectStatisticsSearch, List<String> idList );
|
List<AllProjectStatistics> queryListAllProjectMoney(AllProjectStatisticsSearch allProjectStatisticsSearch, List<String> idList );
|
||||||
}
|
}
|
||||||
|
|||||||
+16
-2
@@ -632,7 +632,21 @@ public class PayWorkingGroupServiceImpl extends ServiceImpl<PayWorkingGroupMappe
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public IPage<AllProjectStatistics> queryPageListAllProjectMoney(Page<AllProjectStatistics> page, AllProjectStatisticsSearch allProjectStatisticsSearch, List<String> idList) {
|
public List<AllProjectStatistics> queryListAllProjectMoney(AllProjectStatisticsSearch allProjectStatisticsSearch, List<String> idList) {
|
||||||
return payWorkingGroupMapper.queryPageListAllProjectMoney(page,allProjectStatisticsSearch,idList);
|
List<AllProjectStatistics> list = payWorkingGroupMapper.queryListAllProjectMoney(allProjectStatisticsSearch,idList);
|
||||||
|
List<Integer> collect=list.stream()
|
||||||
|
.map(allProjectStatistics -> Integer.valueOf(allProjectStatistics.getPaymentDate().split("-")[1]))
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
|
||||||
|
String paymentYear=allProjectStatisticsSearch.getPaymentYear();
|
||||||
|
for (int i=1; i <=12 ; i++) {
|
||||||
|
if(!collect.contains(i)){
|
||||||
|
StringBuilder stringBuilder = new StringBuilder().append(paymentYear);
|
||||||
|
AllProjectStatistics allProjectStatistics=new AllProjectStatistics("0.00","0.00","0.00",stringBuilder.append("-"+i).toString());
|
||||||
|
list.add(allProjectStatistics);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
list.sort(Comparator.comparing(allProjectStatistics -> Integer.valueOf(allProjectStatistics.getPaymentDate().split("-")[1])));
|
||||||
|
return list;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+10
-11
@@ -12,6 +12,7 @@ import com.jero.project.service.IPayWorkingGroupService;
|
|||||||
import com.jero.statistics.entity.AllMoney;
|
import com.jero.statistics.entity.AllMoney;
|
||||||
import com.jero.statistics.entity.AllProjectStatistics;
|
import com.jero.statistics.entity.AllProjectStatistics;
|
||||||
import com.jero.statistics.entity.AllProjectStatisticsSearch;
|
import com.jero.statistics.entity.AllProjectStatisticsSearch;
|
||||||
|
import com.mchange.lang.IntegerUtils;
|
||||||
import io.swagger.annotations.Api;
|
import io.swagger.annotations.Api;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
@@ -25,7 +26,10 @@ import org.springframework.web.bind.annotation.RestController;
|
|||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
import java.text.DecimalFormat;
|
import java.text.DecimalFormat;
|
||||||
import java.util.HashMap;
|
import java.util.*;
|
||||||
|
import java.util.function.Function;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
import java.util.stream.IntStream;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @Description: TODO
|
* @Description: TODO
|
||||||
@@ -52,26 +56,21 @@ public class AllProjectMoneyStatisticsController {
|
|||||||
* 分页列表查询
|
* 分页列表查询
|
||||||
*
|
*
|
||||||
* @param allProjectStatisticsSearch 全所收入统计搜索
|
* @param allProjectStatisticsSearch 全所收入统计搜索
|
||||||
* @param pageNo 页数
|
|
||||||
* @param pageSize 条数
|
|
||||||
*/
|
*/
|
||||||
@ApiOperation(value = "全所收入统计搜索-分页列表查询", notes = "全所收入统计搜索-详情分页列表查询")
|
@ApiOperation(value = "全所收入统计搜索-分页列表查询", notes = "全所收入统计搜索-详情分页列表查询")
|
||||||
@GetMapping(value = "/list")
|
@GetMapping(value = "/list")
|
||||||
public Result<?> list(AllProjectStatisticsSearch allProjectStatisticsSearch,
|
public Result<?> list(AllProjectStatisticsSearch allProjectStatisticsSearch) {
|
||||||
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
|
||||||
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize) {
|
List<AllProjectStatistics> list = payWorkingGroupService.queryListAllProjectMoney(allProjectStatisticsSearch, null);
|
||||||
|
|
||||||
Page<AllProjectStatistics> page = new Page<>(pageNo, pageSize);
|
|
||||||
IPage<AllProjectStatistics> pageList = payWorkingGroupService.queryPageListAllProjectMoney(page, allProjectStatisticsSearch, null);
|
|
||||||
HashMap<String, Object> hashMap = new HashMap<>();
|
HashMap<String, Object> hashMap = new HashMap<>();
|
||||||
|
|
||||||
AllMoney allMoney = payWorkingGroupService.queryPageList33(allProjectStatisticsSearch, null);
|
AllMoney allMoney = payWorkingGroupService.queryPageList33(allProjectStatisticsSearch, null);
|
||||||
|
|
||||||
hashMap.put("sumOfMoney", ObjectUtils.isEmpty(allMoney) ? 0 : allMoney.getAllMoney());
|
hashMap.put("sumOfMoney", ObjectUtils.isEmpty(allMoney) ? 0 : allMoney.getAllMoney());
|
||||||
hashMap.put("sumOfReallyMoney", ObjectUtils.isEmpty(allMoney) ? 0 : allMoney.getComeAllMoney());
|
hashMap.put("sumOfReallyMoney", ObjectUtils.isEmpty(allMoney) ? 0 : allMoney.getComeAllMoney());
|
||||||
hashMap.put("sumOfBillMoney", ObjectUtils.isEmpty(allMoney) ? 0 : allMoney.getBillMoney());
|
hashMap.put("sumOfBillMoney", ObjectUtils.isEmpty(allMoney) ? 0 : allMoney.getBillMoney());
|
||||||
hashMap.put("sumOfConfirmAmount", ObjectUtils.isEmpty(allMoney) ? 0 : allMoney.getConfirmAmount());
|
hashMap.put("sumOfConfirmAmount", ObjectUtils.isEmpty(allMoney) ? 0 : allMoney.getConfirmAmount());
|
||||||
hashMap.put("pageList", pageList);
|
hashMap.put("list", list);
|
||||||
|
|
||||||
return Result.OK(hashMap);
|
return Result.OK(hashMap);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
+11
@@ -2,7 +2,9 @@ package com.jero.statistics.entity;
|
|||||||
|
|
||||||
import com.baomidou.mybatisplus.annotation.TableField;
|
import com.baomidou.mybatisplus.annotation.TableField;
|
||||||
import io.swagger.annotations.ApiModelProperty;
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
|
import lombok.NoArgsConstructor;
|
||||||
import org.jeecgframework.poi.excel.annotation.Excel;
|
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||||
|
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
@@ -12,6 +14,8 @@ import java.util.Date;
|
|||||||
* @date 2021/9/17 18:04
|
* @date 2021/9/17 18:04
|
||||||
*/
|
*/
|
||||||
@Data
|
@Data
|
||||||
|
@AllArgsConstructor
|
||||||
|
@NoArgsConstructor
|
||||||
public class AllProjectStatistics {
|
public class AllProjectStatistics {
|
||||||
@ApiModelProperty(value = "项目id")
|
@ApiModelProperty(value = "项目id")
|
||||||
private String projectId;
|
private String projectId;
|
||||||
@@ -67,4 +71,11 @@ public class AllProjectStatistics {
|
|||||||
@Excel(name = "到账时间", width = 15)
|
@Excel(name = "到账时间", width = 15)
|
||||||
@ApiModelProperty(value = "到账时间")
|
@ApiModelProperty(value = "到账时间")
|
||||||
private String paymentDate;
|
private String paymentDate;
|
||||||
|
|
||||||
|
public AllProjectStatistics(String confirmAmount, String billMoney, String comeAllMoney, String paymentDate) {
|
||||||
|
this.confirmAmount=confirmAmount;
|
||||||
|
this.billMoney=billMoney;
|
||||||
|
this.comeAllMoney=comeAllMoney;
|
||||||
|
this.paymentDate=paymentDate;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user