public ActionResult AjaxForm() { var dnNewsSsc = new DN_NewsSSC(); if (DoAction == ActionType.Edit) { dnNewsSsc = _dnNewsSscda.GetById(ArrId.FirstOrDefault()); } ViewBag.AgencyID = _agencyDa.GetAll(); ViewData.Model = dnNewsSsc; ViewBag.Action = DoAction; ViewBag.ActionText = ActionText; return(View()); }
public ActionResult GetAll(string key) { var obj = key != Keyapi ? new List <AgencyItem>() : _da.GetAll(EnterprisesId()); return(Json(obj, JsonRequestBehavior.AllowGet)); }