|
|
@@ -56,6 +56,9 @@ public class WebMediatorImpl implements ViewMediator {
|
|
|
private EvaluationAgencyDao agencyDao;
|
|
|
|
|
|
@Autowired
|
|
|
+ private AgencyResourceDao agencyResourceDao;
|
|
|
+
|
|
|
+ @Autowired
|
|
|
private CrowdTestProjectDao projectDao;
|
|
|
|
|
|
@Autowired
|
|
|
@@ -119,6 +122,18 @@ public class WebMediatorImpl implements ViewMediator {
|
|
|
img.add("http://mooctest-crowd-service.oss-cn-hangzhou.aliyuncs.com/Image/invictus.jpg");
|
|
|
img.add("http://mooctest-crowd-service.oss-cn-hangzhou.aliyuncs.com/Image/timg.jpeg");
|
|
|
indexDTO.setImgList(img);
|
|
|
+
|
|
|
+ //获取系统统计信息
|
|
|
+ List<PieChartDataVO> statisticsInfo = new ArrayList<>();
|
|
|
+ statisticsInfo.add(new PieChartDataVO("用户总数", userRepo.getAllUserNum()));
|
|
|
+ statisticsInfo.add(new PieChartDataVO("测评机构总数", userRepo.getAllAgencyNum()));
|
|
|
+ statisticsInfo.add(new PieChartDataVO("测试人员总数", agencyResourceDao.getTotalResourceByType("人力资源")));
|
|
|
+ statisticsInfo.add(new PieChartDataVO("服务器总数", agencyResourceDao.getTotalResourceByType("服务器资源")));
|
|
|
+ statisticsInfo.add(new PieChartDataVO("专用设备总数", agencyResourceDao.getTotalResourceByType("专用设备")));
|
|
|
+ statisticsInfo.add(new PieChartDataVO("测试项目总数", projectRepo.getAllProjectNum()));
|
|
|
+ statisticsInfo.add(new PieChartDataVO("测试任务总数", projectRepo.getAllTaskNum()));
|
|
|
+ statisticsInfo.add(new PieChartDataVO("测试报告总数", projectRepo.getAllReportNum()));
|
|
|
+ indexDTO.setSystemStatistics(statisticsInfo);
|
|
|
return indexDTO;
|
|
|
}
|
|
|
|