public JsonResult TreeOnPtp(string ptpId) { var module = new EqtTypeModule(CurrentUser); var items = module.FeatchAll(ptpId).ToArray(); var data = items.Distinct().Select(t => GetTree(t, items)).ToArray(); return(Json(data, JsonRequestBehavior.AllowGet)); }
public JObject GetData() { var module = new EqtTypeModule(CurrentUser); var items = module.FeatchAll().ToArray(); var json = TableEqtTypeDataModel.Model.GetJson(items, TableEqtTypeHeaderModel.Header); return(json); }
public JsonResult Tree() { var module = new EqtTypeModule(CurrentUser); var items = module.FeatchAll().ToArray(); var data = items.Where(t => string.IsNullOrWhiteSpace(t.Pid) || t.Pid == "0") .Select(t => GetTree(t, items)) .ToArray(); return(Json(data, JsonRequestBehavior.AllowGet)); }