fix: added dashboard link in healthcare desk

This commit is contained in:
Nabin Hait 2020-05-19 20:58:00 +05:30
parent 4db4464123
commit 041e31b8ba
2 changed files with 20 additions and 14 deletions

View File

@ -3,7 +3,7 @@
import frappe import frappe
import json import json
from frappe import _
def get_data(): def get_data():
return frappe._dict({ return frappe._dict({
@ -51,7 +51,7 @@ def get_charts():
"doctype": "Dashboard Chart", "doctype": "Dashboard Chart",
"time_interval": "Daily", "time_interval": "Daily",
"name": "Patient Appointments", "name": "Patient Appointments",
"chart_name": "Patient Appointments", "chart_name": _("Patient Appointments"),
"timespan": "Last Month", "timespan": "Last Month",
"filters_json": json.dumps([ "filters_json": json.dumps([
["Patient Appointment", "company", "=", company, False], ["Patient Appointment", "company", "=", company, False],
@ -68,7 +68,7 @@ def get_charts():
{ {
"doctype": "Dashboard Chart", "doctype": "Dashboard Chart",
"name": "Department wise Patient Appointments", "name": "Department wise Patient Appointments",
"chart_name": "Department wise Patient Appointments", "chart_name": _("Department wise Patient Appointments"),
"chart_type": "Custom", "chart_type": "Custom",
"source": "Department wise Patient Appointments", "source": "Department wise Patient Appointments",
"filters_json": json.dumps({}), "filters_json": json.dumps({}),
@ -87,7 +87,7 @@ def get_charts():
{ {
"doctype": "Dashboard Chart", "doctype": "Dashboard Chart",
"name": "Lab Tests", "name": "Lab Tests",
"chart_name": "Lab Tests", "chart_name": _("Lab Tests"),
"chart_type": "Group By", "chart_type": "Group By",
"document_type": "Lab Test", "document_type": "Lab Test",
"group_by_type": "Count", "group_by_type": "Count",
@ -104,7 +104,7 @@ def get_charts():
{ {
"doctype": "Dashboard Chart", "doctype": "Dashboard Chart",
"name": "Clinical Procedures", "name": "Clinical Procedures",
"chart_name": "Clinical Procedures", "chart_name": _("Clinical Procedures"),
"chart_type": "Group By", "chart_type": "Group By",
"document_type": "Clinical Procedure", "document_type": "Clinical Procedure",
"group_by_type": "Count", "group_by_type": "Count",
@ -121,7 +121,7 @@ def get_charts():
{ {
"doctype": "Dashboard Chart", "doctype": "Dashboard Chart",
"name": "In-Patient Status", "name": "In-Patient Status",
"chart_name": "In-Patient Status", "chart_name": _("In-Patient Status"),
"chart_type": "Group By", "chart_type": "Group By",
"document_type": "Inpatient Record", "document_type": "Inpatient Record",
"group_by_type": "Count", "group_by_type": "Count",
@ -137,7 +137,7 @@ def get_charts():
{ {
"doctype": "Dashboard Chart", "doctype": "Dashboard Chart",
"name": "Clinical Procedures Status", "name": "Clinical Procedures Status",
"chart_name": "Clinical Procedure Status", "chart_name": _("Clinical Procedure Status"),
"chart_type": "Group By", "chart_type": "Group By",
"document_type": "Clinical Procedure", "document_type": "Clinical Procedure",
"group_by_type": "Count", "group_by_type": "Count",
@ -154,7 +154,7 @@ def get_charts():
{ {
"doctype": "Dashboard Chart", "doctype": "Dashboard Chart",
"name": "Symptoms", "name": "Symptoms",
"chart_name": "Symptoms", "chart_name": _("Symptoms"),
"chart_type": "Group By", "chart_type": "Group By",
"document_type": "Patient Encounter Symptom", "document_type": "Patient Encounter Symptom",
"group_by_type": "Count", "group_by_type": "Count",
@ -168,7 +168,7 @@ def get_charts():
{ {
"doctype": "Dashboard Chart", "doctype": "Dashboard Chart",
"name": "Diagnoses", "name": "Diagnoses",
"chart_name": "Diagnoses", "chart_name": _("Diagnoses"),
"chart_type": "Group By", "chart_type": "Group By",
"document_type": "Patient Encounter Diagnosis", "document_type": "Patient Encounter Diagnosis",
"group_by_type": "Count", "group_by_type": "Count",
@ -186,7 +186,7 @@ def get_number_cards():
return [ return [
{ {
"name": "Total Patients", "name": "Total Patients",
"label": "Total Patients", "label": _("Total Patients"),
"function": "Count", "function": "Count",
"doctype": "Number Card", "doctype": "Number Card",
"document_type": "Patient", "document_type": "Patient",
@ -200,7 +200,7 @@ def get_number_cards():
}, },
{ {
"name": "Total Patients Admitted", "name": "Total Patients Admitted",
"label": "Total Patients Admitted", "label": _("Total Patients Admitted"),
"function": "Count", "function": "Count",
"doctype": "Number Card", "doctype": "Number Card",
"document_type": "Patient", "document_type": "Patient",
@ -214,7 +214,7 @@ def get_number_cards():
}, },
{ {
"name": "Open Appointments", "name": "Open Appointments",
"label": "Open Appointments", "label": _("Open Appointments"),
"function": "Count", "function": "Count",
"doctype": "Number Card", "doctype": "Number Card",
"document_type": "Patient Appointment", "document_type": "Patient Appointment",
@ -229,7 +229,7 @@ def get_number_cards():
}, },
{ {
"name": "Appointments to Bill", "name": "Appointments to Bill",
"label": "Appointments to Bill", "label": _("Appointments to Bill"),
"function": "Count", "function": "Count",
"doctype": "Number Card", "doctype": "Number Card",
"document_type": "Patient Appointment", "document_type": "Patient Appointment",

View File

@ -60,10 +60,11 @@
"docstatus": 0, "docstatus": 0,
"doctype": "Desk Page", "doctype": "Desk Page",
"extends_another_page": 0, "extends_another_page": 0,
"hide_custom": 0,
"idx": 0, "idx": 0,
"is_standard": 1, "is_standard": 1,
"label": "Healthcare", "label": "Healthcare",
"modified": "2020-05-19 14:05:10.520457", "modified": "2020-05-19 20:57:22.797267",
"modified_by": "Administrator", "modified_by": "Administrator",
"module": "Healthcare", "module": "Healthcare",
"name": "Healthcare", "name": "Healthcare",
@ -106,6 +107,11 @@
"label": "Patient History", "label": "Patient History",
"link_to": "patient_history", "link_to": "patient_history",
"type": "Page" "type": "Page"
},
{
"label": "Healthcare Dashboard",
"link_to": "Healthcare",
"type": "Dashboard"
} }
] ]
} }