Exemplo n.º 1
0
        public ActionResult PlanTab(int PatientId)
        {
            ViewBag.PatientId = new SelectList(Dropdowns.PatientDropDown, "Value", "Text", PatientId);

            PreNatal_Plan model = new PreNatal_Plan();

            return(View(model));
        }
Exemplo n.º 2
0
        public ActionResult PlanTab(PreNatal_Plan model)
        {
            PlanBL obj = new PlanBL();

            if (ModelState.IsValid)
            {
                var toReturn = obj.Save(model, out outmodel);
                return(RedirectToAction("GeneralTab", "PaedsPhyExamination", new { area = "PN" }));
            }
            ViewBag.PatientId = new SelectList(Dropdowns.PatientDropDown, "Value", "Text");

            return(View(model));
        }
Exemplo n.º 3
0
        public ActionResult Edit(PreNatal_Plan model)
        {
            try
            {
                obj.Update(model, out outmodel);
                if (!outmodel.Error)
                {
                    // TODO: Add update logic here

                    return(RedirectToAction("Index"));
                }
                else
                {
                    return(View(model));
                }
            }
            catch (Exception ex)
            {
                ex.Message.ToString();
                return(View());
            }
        }
Exemplo n.º 4
0
        public ActionResult Create(PreNatal_Plan model)
        {
            var toReturn = obj.Save(model, out outmodel);

            return(Json(new { mdl = outmodel, pa = toReturn }, JsonRequestBehavior.AllowGet));
        }