From fb29714911490bee40d2c5b9342a3f9a4a84d46d Mon Sep 17 00:00:00 2001 From: Rucha Mahabal Date: Mon, 18 May 2020 16:28:11 +0530 Subject: [PATCH] feat: Healthcare Dashboard --- erpnext/healthcare/dashboard_fixtures.py | 88 +++++++++++++++++++++++- 1 file changed, 87 insertions(+), 1 deletion(-) diff --git a/erpnext/healthcare/dashboard_fixtures.py b/erpnext/healthcare/dashboard_fixtures.py index 8b86ac39ac..0f5728de9a 100644 --- a/erpnext/healthcare/dashboard_fixtures.py +++ b/erpnext/healthcare/dashboard_fixtures.py @@ -16,7 +16,13 @@ def get_dashboards(): "name": "Healthcare", "dashboard_name": "Healthcare", "charts": [ - { "chart": "Patient Appointments" } + { "chart": "Patient Appointments", "width": "Full"}, + { "chart": "In-Patient Status", "width": "Half"}, + { "chart": "Clinical Procedures Status", "width": "Half"}, + { "chart": "Symptoms", "width": "Half"}, + { "chart": "Diagnoses", "width": "Half"}, + { "chart": "Department wise Patient Appointments", "width": "Full"}, + { "chart": "Lab Tests", "width": "Full"}, ] }] @@ -36,5 +42,85 @@ def get_charts(): "document_type": "Patient Appointment", "type": "Line", "width": "Half" + }, + { + "doctype": "Dashboard Chart", + "name": "Department wise Patient Appointments", + "chart_name": "Department wise Patient Appointments", + "chart_type": "Group By", + "document_type": "Patient Appointment", + "group_by_type": "Count", + "group_by_based_on": "department", + 'is_public': 1, + "owner": "Administrator", + "type": "Bar", + "width": "Full", + "color": "#5F62F6" + }, + { + "doctype": "Dashboard Chart", + "name": "Lab Tests", + "chart_name": "Lab Tests", + "chart_type": "Group By", + "document_type": "Lab Test", + "group_by_type": "Count", + "group_by_based_on": "template", + 'is_public': 1, + "owner": "Administrator", + "type": "Bar", + "width": "Full", + "color": "#8548EB" + }, + { + "doctype": "Dashboard Chart", + "name": "In-Patient Status", + "chart_name": "In-Patient Status", + "chart_type": "Group By", + "document_type": "Inpatient Record", + "group_by_type": "Count", + "group_by_based_on": "status", + 'is_public': 1, + "owner": "Administrator", + "type": "Bar", + "width": "Half", + }, + { + "doctype": "Dashboard Chart", + "name": "Clinical Procedures Status", + "chart_name": "Clinical Procedure Status", + "chart_type": "Group By", + "document_type": "Clinical Procedure", + "group_by_type": "Count", + "group_by_based_on": "status", + 'is_public': 1, + "owner": "Administrator", + "type": "Pie", + "width": "Half", + }, + { + "doctype": "Dashboard Chart", + "name": "Symptoms", + "chart_name": "Symptoms", + "chart_type": "Group By", + "document_type": "Patient Encounter Symptom", + "group_by_type": "Count", + "group_by_based_on": "complaint", + 'is_public': 1, + "owner": "Administrator", + "type": "Percentage", + "width": "Half", + }, + { + "doctype": "Dashboard Chart", + "name": "Diagnoses", + "chart_name": "Diagnoses", + "chart_type": "Group By", + "document_type": "Patient Encounter Diagnosis", + "group_by_type": "Count", + "group_by_based_on": "diagnosis", + 'is_public': 1, + "owner": "Administrator", + "type": "Percentage", + "width": "Half", } ]