示例#1
0
        public JsonResult Save(Billed model)
        {
            if (ModelState.IsValid && model.BilledDetails != null && model.BilledDetails.Count > 0)
            {
                if (billManager.SaveOrUpdate(model))
                {
                    return(Json(new { info = "Saved", status = true }, JsonRequestBehavior.AllowGet));
                }
                return(Json(new { info = "Not Saved", status = false }, JsonRequestBehavior.AllowGet));
            }

            else
            {
                return(Json(new { info = "Not Saved", status = false }, JsonRequestBehavior.AllowGet));
            }
        }