Пример #1
0
        public IActionResult DoctorView(Patient patient)
        {
            patientId          = patient.Id;
            Properties.patient = patient;

            var doctorSpecialization = DoctorTable.GetSpecializationById(Properties.UserId);

            if (patient.Name == null)
            {
                patient.Id = 100;
            }

            List <Visit>              visits        = VisitTable.GetDataByPatientIdAndSpecialization(patient.Id, doctorSpecialization[0].Specialization);
            List <Prescription>       prescriptions = PrescriptionTable.GetDataByPatientId(patient.Id);
            List <Test>               tests         = TestTable.GetDataByPatientId(patient.Id);
            List <Documentation>      docs          = DocumentationTable.GetDataByPatientId(patient.Id);
            List <MedicalDescription> list          = MedicalDescriptionTable.GetDataByPatientId(patient.Id);

            ViewData["data"]      = patient;
            ViewData["docs"]      = docs;
            ViewData["visits"]    = visits;
            ViewData["prescript"] = prescriptions;
            ViewData["tests"]     = tests;
            ViewData["medicalDescriptionData"] = list;
            return(View());
        }
Пример #2
0
        public ActionResult PatientView(Patient patient)

        {
            var patients    = PatientTable.GetPatientById(Properties.UserId);
            var description = MedicalDescriptionTable.GetDataByPatientId(Properties.UserId);
            var visit       = VisitTable.GetDataByPatientId(Properties.UserId);
            var prescript   = PrescriptionTable.GetData(Properties.UserId);
            var test        = TestTable.GetData(Properties.UserId);
            var leavesick   = SickLeaveTable.GetDataByPatientId(Properties.UserId);
            var doc         = DocumentationTable.GetDataByPatientId(Properties.UserId);

            //  ViewData["PatientName"] = PatientTable.GetPatientById(patient.Id);
            ViewData["PatientName"]        = patients[0];
            ViewData["visitData"]          = visit;
            ViewData["prescriptioneData"]  = prescript;
            ViewData["Tests"]              = test;
            ViewData["sickLeaveData"]      = leavesick;
            ViewData["medicalDescription"] = description;
            ViewData["documentation"]      = doc;

            return(View());
        }