public JavaScriptResult Create(FormCollection collection, Patient patient)
        {
            try
            {
                // TODO: Add insert logic here

                //Patients.All.Last();
                patient.PatientID = jQueryMobileTemplate.MvcApplication.ActivePatient.PatientID;
                UpdateModel(jQueryMobileTemplate.MvcApplication.ActivePatient);
                jQueryMobileTemplate.MvcApplication.ActivePatient.PatientID = patient.PatientID;
                var pa = Patients.All.Where(p => p.PatientID == patient.PatientID).FirstOrDefault();
                if (pa == null)
                {
                    Patients.All.Add(jQueryMobileTemplate.MvcApplication.ActivePatient);
                }
                else
                {
                    UpdateModel(pa);
                    pa.PatientID = patient.PatientID;
                }
                return JavaScript("window.location.href='/PatientInsurance/Create/'");
            }
            catch
            {
                return JavaScript("location.reload(true)");
            }
        }
        public JavaScriptResult Create(FormCollection collection, Patient Patient)
        {
            try
            {
                //TODO: Add insert logic here
                Patient.PatientID = (Convert.ToInt32(Patients.All.Max(p => p.PatientID)) + 1).ToString();
                UpdateModel(jQueryMobileTemplate.MvcApplication.ActivePatient);
                jQueryMobileTemplate.MvcApplication.ActivePatient.PatientID = Patient.PatientID;
                var pa = Patients.All.Where(p => p.PatientID == Patient.PatientID).FirstOrDefault();
                if (pa == null)
                {
                    Patients.All.Add(jQueryMobileTemplate.MvcApplication.ActivePatient);
                }
                else
                {
                    UpdateModel(pa);
                    pa.PatientID = Patient.PatientID;
                }
                return JavaScript("window.location.href='/PatientAdmission/Create/'");
            }

            catch
            {
                return JavaScript("location.reload(true)");
            }
        }
 //
 //// GET: /PatientAdmission/Create
 public ActionResult Create(Patient patient)
 {
     return View(jQueryMobileTemplate.MvcApplication.ActivePatient);
 }