Пример #1
0
        public ActionResult GetOpdFormById(string opdId, string mode)
        {
            var allRecWithOpd = OpdService.GetOpdByIdWithRows(opdId);

            if (mode == "recreate")
            {
                allRecWithOpd.Opd.VisitNo    = allRecWithOpd.Records.Count + 1;
                allRecWithOpd.Opd.DoctorId   = "0";
                allRecWithOpd.Opd.Discount   = 0;
                allRecWithOpd.Opd.DiscountBy = " ";
                allRecWithOpd.Opd.DocFee     = 0;
                allRecWithOpd.Opd.DateTime   = DateTime.Now.ToLongTimeString();
                allRecWithOpd.Opd.Id         = 0;
            }
            var dataModel = new OpdPageModel
            {
                CreatedOpdForm = allRecWithOpd?.Opd,
                Mode           = mode,
                DoctorList     = DocService.GetAllDocsForDd(),
                Records        = allRecWithOpd?.Records
            };

            //recreate
            return(View("OpdpForms", dataModel));
        }
Пример #2
0
        public ActionResult CreateIpForm(string opdId)
        {
            var opd = new AppIp {
                BloodGroup = "B+"
            };

            if (!string.IsNullOrEmpty(opdId))
            {
                opd          = OpdService.ConvertToIp(opdId);
                opd.DateTime = DateTime.Now.ToLongTimeString();
            }

            var dataModel = new IpPageModel
            {
                DoctorList  = DocService.GetAllDocsForDd(),
                WardsList   = IpFormService.GetWards(),
                GeneralData = opd
            };

            return(View(dataModel));
        }
Пример #3
0
        public ActionResult OpdpForms()
        {
            var dataModel = new OpdPageModel
            {
                DoctorList     = DocService.GetAllDocsForDd(),
                CreatedOpdForm = new AppOpd
                {
                    DateTime     = " ",
                    VisitNo      = 1,
                    PatientNo    = " ",
                    Name         = " ",
                    GuardianName = " ",
                    CNIC         = " ",
                    Address      = " ",
                    Phone        = " ",
                    InsuranceNo  = " "
                },
                Mode = "new"
            };

            return(View(dataModel));
        }