| Line 986... |
Line 986... |
| 986 |
.sum();
|
986 |
.sum();
|
| 987 |
|
987 |
|
| 988 |
List<Sold15daysOldAgingModel> sold15daysOldAgingModels = rbmTargetService.getAgingSale(LocalDate.now(), LocalDate.now().plusDays(1));
|
988 |
List<Sold15daysOldAgingModel> sold15daysOldAgingModels = rbmTargetService.getAgingSale(LocalDate.now(), LocalDate.now().plusDays(1));
|
| 989 |
List<Our15DaysOldAgingStock> our15DaysOldAgingStocks = rbmTargetService.our15DaysAgingStock();
|
989 |
List<Our15DaysOldAgingStock> our15DaysOldAgingStocks = rbmTargetService.our15DaysAgingStock();
|
| 990 |
|
990 |
|
| - |
|
991 |
|
| - |
|
992 |
// first week count of rbm partner billing
|
| - |
|
993 |
LocalDate firstOfCurrentMonth = LocalDate.now().withDayOfMonth(1);
|
| - |
|
994 |
LocalDate seventhOfCurrentMonth = LocalDate.now().withDayOfMonth(7);
|
| - |
|
995 |
|
| - |
|
996 |
List<RbmBilledFofoIdsModel> rbmBilledFofoIdsModelsFirstWeek = rbmTargetService.getDateWiseBilledFofoIdByRbm(firstOfCurrentMonth, seventhOfCurrentMonth);
|
| - |
|
997 |
|
| - |
|
998 |
Map<String, Long> rbmBilledCountMapFirstWeek = rbmBilledFofoIdsModelsFirstWeek.stream()
|
| - |
|
999 |
.filter(x -> x.getStatus().equals("Billed"))
|
| - |
|
1000 |
.collect(Collectors.groupingBy(RbmBilledFofoIdsModel::getRbmName, Collectors.counting()));
|
| - |
|
1001 |
|
| - |
|
1002 |
|
| - |
|
1003 |
// second week count of rbm partner billing
|
| - |
|
1004 |
|
| - |
|
1005 |
LocalDate eightOfCurrentMonth = LocalDate.now().withDayOfMonth(8);
|
| - |
|
1006 |
LocalDate fifteenOfCurrentMonth = LocalDate.now().withDayOfMonth(15);
|
| - |
|
1007 |
|
| - |
|
1008 |
List<RbmBilledFofoIdsModel> rbmBilledFofoIdsModelsSecondWeek = rbmTargetService.getDateWiseBilledFofoIdByRbm(eightOfCurrentMonth, fifteenOfCurrentMonth);
|
| - |
|
1009 |
|
| - |
|
1010 |
Map<String, Long> rbmBilledCountMapSecondWeek = rbmBilledFofoIdsModelsSecondWeek.stream()
|
| - |
|
1011 |
.filter(x -> x.getStatus().equals("Billed"))
|
| - |
|
1012 |
.collect(Collectors.groupingBy(RbmBilledFofoIdsModel::getRbmName, Collectors.counting()));
|
| - |
|
1013 |
|
| - |
|
1014 |
|
| - |
|
1015 |
// third week count of rbm partner billing
|
| - |
|
1016 |
|
| - |
|
1017 |
LocalDate sixteenOfCurrentMonth = LocalDate.now().withDayOfMonth(16);
|
| - |
|
1018 |
LocalDate twentySecondOfCurrentMonth = LocalDate.now().withDayOfMonth(22);
|
| - |
|
1019 |
|
| - |
|
1020 |
List<RbmBilledFofoIdsModel> rbmBilledFofoIdsModelsThirdWeek = rbmTargetService.getDateWiseBilledFofoIdByRbm(sixteenOfCurrentMonth, twentySecondOfCurrentMonth);
|
| - |
|
1021 |
|
| - |
|
1022 |
Map<String, Long> rbmBilledCountMapThirdWeek = rbmBilledFofoIdsModelsThirdWeek.stream()
|
| - |
|
1023 |
.filter(x -> x.getStatus().equals("Billed"))
|
| - |
|
1024 |
.collect(Collectors.groupingBy(RbmBilledFofoIdsModel::getRbmName, Collectors.counting()));
|
| - |
|
1025 |
|
| - |
|
1026 |
|
| - |
|
1027 |
// fourth week count of rbm partner billing
|
| - |
|
1028 |
|
| - |
|
1029 |
LocalDate twentyThirdOfCurrentMonth = LocalDate.now().withDayOfMonth(23);
|
| - |
|
1030 |
LocalDate lastDayOfCurrentMonth = LocalDate.now().withDayOfMonth(LocalDate.now().lengthOfMonth());
|
| - |
|
1031 |
|
| - |
|
1032 |
List<RbmBilledFofoIdsModel> rbmBilledFofoIdsModelsFourthWeek = rbmTargetService.getDateWiseBilledFofoIdByRbm(twentyThirdOfCurrentMonth, lastDayOfCurrentMonth);
|
| - |
|
1033 |
|
| - |
|
1034 |
Map<String, Long> rbmBilledCountMapFourthWeek = rbmBilledFofoIdsModelsFourthWeek.stream()
|
| - |
|
1035 |
.filter(x -> x.getStatus().equals("Billed"))
|
| - |
|
1036 |
.collect(Collectors.groupingBy(RbmBilledFofoIdsModel::getRbmName, Collectors.counting()));
|
| - |
|
1037 |
|
| - |
|
1038 |
|
| - |
|
1039 |
// mtd rbm partner billing
|
| - |
|
1040 |
|
| - |
|
1041 |
List<RbmBilledFofoIdsModel> rbmBilledFofoIdsModelsMtd = rbmTargetService.getDateWiseBilledFofoIdByRbm(firstOfCurrentMonth, LocalDate.now());
|
| - |
|
1042 |
|
| - |
|
1043 |
Map<String, Long> rbmBilledCountMapMtd = rbmBilledFofoIdsModelsMtd.stream()
|
| - |
|
1044 |
.filter(x -> x.getStatus().equals("Billed"))
|
| - |
|
1045 |
.collect(Collectors.groupingBy(RbmBilledFofoIdsModel::getRbmName, Collectors.counting()));
|
| - |
|
1046 |
|
| 991 |
LOGGER.info("rbmArrViewModels {}", rbmArrViewModels);
|
1047 |
LOGGER.info("rbmArrViewModels {}", rbmArrViewModels);
|
| 992 |
model.addAttribute("rbmArrViewModels", rbmArrViewModels);
|
1048 |
model.addAttribute("rbmArrViewModels", rbmArrViewModels);
|
| 993 |
model.addAttribute("totalTarget", totalTarget);
|
1049 |
model.addAttribute("totalTarget", totalTarget);
|
| 994 |
model.addAttribute("totalAchieved", totalAchieved);
|
1050 |
model.addAttribute("totalAchieved", totalAchieved);
|
| 995 |
model.addAttribute("sold15daysOldAgingModels", sold15daysOldAgingModels);
|
1051 |
model.addAttribute("sold15daysOldAgingModels", sold15daysOldAgingModels);
|
| 996 |
model.addAttribute("our15DaysOldAgingStocks", our15DaysOldAgingStocks);
|
1052 |
model.addAttribute("our15DaysOldAgingStocks", our15DaysOldAgingStocks);
|
| 997 |
|
1053 |
|
| - |
|
1054 |
model.addAttribute("rbmBilledCountMapFirstWeek", rbmBilledCountMapFirstWeek);
|
| - |
|
1055 |
model.addAttribute("rbmBilledCountMapSecondWeek", rbmBilledCountMapSecondWeek);
|
| - |
|
1056 |
model.addAttribute("rbmBilledCountMapThirdWeek", rbmBilledCountMapThirdWeek);
|
| - |
|
1057 |
model.addAttribute("rbmBilledCountMapFourthWeek", rbmBilledCountMapFourthWeek);
|
| - |
|
1058 |
model.addAttribute("rbmBilledCountMapMtd", rbmBilledCountMapMtd);
|
| - |
|
1059 |
|
| 998 |
return "rbm-today-arr";
|
1060 |
return "rbm-today-arr";
|
| 999 |
}
|
1061 |
}
|
| 1000 |
|
1062 |
|
| 1001 |
|
1063 |
|
| 1002 |
|
1064 |
|