diff --git a/healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/datacollection/appservice/impl/DataDashboardAppServiceImpl.java b/healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/datacollection/appservice/impl/DataDashboardAppServiceImpl.java index 8bcdf11d0..d54a69182 100644 --- a/healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/datacollection/appservice/impl/DataDashboardAppServiceImpl.java +++ b/healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/datacollection/appservice/impl/DataDashboardAppServiceImpl.java @@ -89,9 +89,10 @@ public class DataDashboardAppServiceImpl implements IDataDashboardAppService { cutoffDate = java.time.LocalDate.now().minusYears(1).toString(); } - if (cutoffDate != null) { + final String finalCutoff = cutoffDate; + if (finalCutoff != null) { allData = allData.stream() - .filter(ba -> ba.getStatDate() != null && ba.getStatDate().compareTo(cutoffDate) >= 0) + .filter(ba -> ba.getStatDate() != null && ba.getStatDate().compareTo(finalCutoff) >= 0) .collect(Collectors.toList()); } diff --git a/healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/reportmanage/dto/BiReportDto.java b/healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/reportmanage/dto/BiReportDto.java new file mode 100644 index 000000000..7dcb036bb --- /dev/null +++ b/healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/reportmanage/dto/BiReportDto.java @@ -0,0 +1,17 @@ +package com.healthlink.his.web.reportmanage.dto; + +import lombok.Data; +import lombok.experimental.Accessors; + +import java.util.List; +import java.util.Map; + +@Data +@Accessors(chain = true) +public class BiReportDto { + private String reportType; + private String title; + private List> records; + private Map summary; + private List> charts; +} diff --git a/healthlink-his-ui/src/api/datacollection/index.js b/healthlink-his-ui/src/api/datacollection/index.js new file mode 100644 index 000000000..8a8d3099e --- /dev/null +++ b/healthlink-his-ui/src/api/datacollection/index.js @@ -0,0 +1,32 @@ +import request from '@/utils/request' + +export function collectClinicalData(data) { + return request({ + url: '/data/collect/clinical', + method: 'post', + params: data + }) +} + +export function collectOperationalData(data) { + return request({ + url: '/data/collect/operational', + method: 'post', + params: data + }) +} + +export function getRealtimeData() { + return request({ + url: '/data/dashboard/realtime', + method: 'get' + }) +} + +export function getHistoricalData(params) { + return request({ + url: '/data/dashboard/historical', + method: 'get', + params: params + }) +} diff --git a/healthlink-his-ui/src/api/reportmanage/bi.js b/healthlink-his-ui/src/api/reportmanage/bi.js new file mode 100644 index 000000000..35fe3b024 --- /dev/null +++ b/healthlink-his-ui/src/api/reportmanage/bi.js @@ -0,0 +1,17 @@ +import request from '@/utils/request' + +export function generateBiReport(data) { + return request({ + url: '/report/bi/generate', + method: 'post', + params: { type: data.type }, + data: data.filters || {} + }) +} + +export function getBiDashboard() { + return request({ + url: '/report/bi/dashboard', + method: 'get' + }) +} diff --git a/healthlink-his-ui/src/views/datacollection/DataDashboard.vue b/healthlink-his-ui/src/views/datacollection/DataDashboard.vue new file mode 100644 index 000000000..edce28fed --- /dev/null +++ b/healthlink-his-ui/src/views/datacollection/DataDashboard.vue @@ -0,0 +1,144 @@ + + + + + diff --git a/healthlink-his-ui/src/views/reportmanage/BiDashboard.vue b/healthlink-his-ui/src/views/reportmanage/BiDashboard.vue new file mode 100644 index 000000000..aac17cefe --- /dev/null +++ b/healthlink-his-ui/src/views/reportmanage/BiDashboard.vue @@ -0,0 +1,131 @@ + + + + +