|
|
@@ -363,7 +363,7 @@ public class HlwPaymentDetailController extends JeecgController<HlwPaymentDetail
|
|
|
list.add(businessAccountUtils.round(businessAccountUtils.div(weekUser, monthUser), 2) * 100);
|
|
|
list.add(monthUser);
|
|
|
//本月新增用户占年新增用户比例
|
|
|
- list.add(businessAccountUtils.round(businessAccountUtils.div(monthUser, yearUser), 2) * 100 );
|
|
|
+ list.add(businessAccountUtils.round(businessAccountUtils.div(monthUser, yearUser), 2) * 100);
|
|
|
//用户环增长比
|
|
|
list.add(rand.nextInt(9) + 8 + "%");
|
|
|
return Result.ok(list);
|
|
|
@@ -387,7 +387,7 @@ public class HlwPaymentDetailController extends JeecgController<HlwPaymentDetail
|
|
|
LocalDate lastDate = localDate.minusMonths(i + 1);
|
|
|
int increasedUser = hlwUserMapper.monthAddUser(DateUtils.asDate(lastDate));
|
|
|
map.put("value", increasedUser);
|
|
|
- map.put("x", lastDate.getMonthValue()+"月");
|
|
|
+ map.put("x", lastDate.getMonthValue() + "月");
|
|
|
list.add(0, map);
|
|
|
}
|
|
|
|
|
|
@@ -424,7 +424,7 @@ public class HlwPaymentDetailController extends JeecgController<HlwPaymentDetail
|
|
|
LocalDate lastDate = localDate.minusMonths(i + 1);
|
|
|
int monthOrder1 = hlwOrderMapper.monthAddOrder(DateUtils.asDate(lastDate));
|
|
|
map.put("value", monthOrder1);
|
|
|
- map.put("x", lastDate.getMonthValue()+"月");
|
|
|
+ map.put("x", lastDate.getMonthValue() + "月");
|
|
|
list1.add(0, map);
|
|
|
}
|
|
|
list.add(list1);
|
|
|
@@ -432,19 +432,21 @@ public class HlwPaymentDetailController extends JeecgController<HlwPaymentDetail
|
|
|
//企业信息列表
|
|
|
int totalCompany = hlwCompanyMapper.findTotalCompany();
|
|
|
Random rand = new Random();
|
|
|
- List<HlwCompany> hlwCompanyList=new ArrayList<>();
|
|
|
- if(totalCompany>5){
|
|
|
+ List<HlwCompany> hlwCompanyList = new ArrayList<>();
|
|
|
+ if (totalCompany > 5) {
|
|
|
//企业信息列表查询参数为limit两个参数,总计随机查询5条
|
|
|
- hlwCompanyList = hlwCompanyMapper.findCompanyList(rand.nextInt(totalCompany - 5), 5);
|
|
|
- }else{
|
|
|
- hlwCompanyList = hlwCompanyMapper.findCompanyList(0, totalCompany);
|
|
|
+ hlwCompanyList = hlwCompanyMapper.findCompanyList(rand.nextInt(totalCompany - 5), 5);
|
|
|
+ } else {
|
|
|
+ hlwCompanyList = hlwCompanyMapper.findCompanyList(0, totalCompany);
|
|
|
+ }
|
|
|
+ for (HlwCompany hlwCompany : hlwCompanyList) {
|
|
|
+ String provinceCityCountry = hlwCompany.getProvinceCityCountry();
|
|
|
+ provinceCityCountry = provinceCityCountry.replaceFirst("-", "#");
|
|
|
+ String province = provinceCityCountry.substring(0, provinceCityCountry.lastIndexOf("#"));
|
|
|
+ hlwCompany.setProvinceCityCountry(province);
|
|
|
}
|
|
|
list.add(hlwCompanyList);
|
|
|
return Result.ok(list);
|
|
|
}
|
|
|
|
|
|
- private static Date localDate2Date(LocalDate localDate) {
|
|
|
- ZonedDateTime zonedDateTime = localDate.atStartOfDay(ZoneId.systemDefault());
|
|
|
- return Date.from(zonedDateTime.toInstant());
|
|
|
- }
|
|
|
}
|