public JsonResult GetData(string sql, string where, string tableName, int pageNo, bool ForMobile) { Ctx ctx = Session["ctx"] as Ctx; VIS.Models.InfoProductModel model = new Models.InfoProductModel(); sql = SecureEngineBridge.DecryptByClientKey(sql, ctx.GetSecureKey()); where = SecureEngineBridge.DecryptByClientKey(where, ctx.GetSecureKey()); return(Json(JsonConvert.SerializeObject(model.GetData(sql, where, tableName, pageNo, ForMobile, ctx)), JsonRequestBehavior.AllowGet)); }
public JsonResult Save1(int id, string keyColumn, string prod, string listAst, string qty, string ordlineID, string listLoc, int locatorTo, string astID, int lineID) { List <string> prodID = new List <string>(); if (prod != null && prod.Trim().Length > 0) { prodID = JsonConvert.DeserializeObject <List <string> >(prod); } List <string> Attributes = new List <string>(); if (listAst != null && listAst.Trim().Length > 0) { Attributes = JsonConvert.DeserializeObject <List <string> >(listAst); } List <string> quantity = new List <string>(); if (qty != null && qty.Trim().Length > 0) { quantity = JsonConvert.DeserializeObject <List <string> >(qty); } List <string> olineID = new List <string>(); if (ordlineID != null && ordlineID.Trim().Length > 0) { olineID = JsonConvert.DeserializeObject <List <string> >(ordlineID); } List <string> Locators = new List <string>(); if (listLoc != null && listLoc.Trim().Length > 0) { Locators = JsonConvert.DeserializeObject <List <string> >(listLoc); } List <string> assetid = new List <string>(); if (astID != null && astID.Trim().Length > 0) { assetid = JsonConvert.DeserializeObject <List <string> >(listLoc); } VIS.Models.InfoProductModel model = new Models.InfoProductModel(); var value = model.SetProductQty1(id, keyColumn, prodID, Attributes, quantity, olineID, Locators, locatorTo, assetid, lineID, Session["ctx"] as Ctx); return(Json(new { result = value }, JsonRequestBehavior.AllowGet)); }
public JsonResult Save(int id, string keyColumn, string prod, string C_UOM_ID, string listAst, string qty, int locatorTo, int lineID, string InvCountID, string ReferenceNo, int Locator_ID, int WindowID, int ContainerID, int ContainerToID) { List <string> prodID = new List <string>(); if (prod != null && prod.Trim().Length > 0) { prodID = JsonConvert.DeserializeObject <List <string> >(prod); } List <string> uomID = new List <string>(); if (C_UOM_ID != null && C_UOM_ID.Trim().Length > 0) { uomID = JsonConvert.DeserializeObject <List <string> >(C_UOM_ID); } List <string> Attributes = new List <string>(); if (listAst != null && listAst.Trim().Length > 0) { Attributes = JsonConvert.DeserializeObject <List <string> >(listAst); } List <string> quantity = new List <string>(); if (qty != null && qty.Trim().Length > 0) { quantity = JsonConvert.DeserializeObject <List <string> >(qty); } List <string> countID = new List <string>(); if (InvCountID != null && InvCountID.Trim().Length > 0) { countID = JsonConvert.DeserializeObject <List <string> >(InvCountID); } List <string> RefNo = new List <string>(); if (ReferenceNo != null && ReferenceNo.Trim().Length > 0) { RefNo = JsonConvert.DeserializeObject <List <string> >(ReferenceNo); } VIS.Models.InfoProductModel model = new Models.InfoProductModel(); var value = model.SetProductQty(id, keyColumn, prodID, uomID, Attributes, quantity, locatorTo, lineID, countID, RefNo, Locator_ID, WindowID, ContainerID, ContainerToID, Session["ctx"] as Ctx); return(Json(JsonConvert.SerializeObject(value), JsonRequestBehavior.AllowGet)); }
public JsonResult SaveStockTfr(int id, string keyColumn, int AD_Table_ID, string prod, string C_UOM_ID, string listAst, string qty, string listLoc, int locatorTo, string astID, int lineID, int ContainerID) { List <string> prodID = new List <string>(); if (prod != null && prod.Trim().Length > 0) { prodID = JsonConvert.DeserializeObject <List <string> >(prod); } List <string> uomID = new List <string>(); if (C_UOM_ID != null && C_UOM_ID.Trim().Length > 0) { uomID = JsonConvert.DeserializeObject <List <string> >(C_UOM_ID); } List <string> Attributes = new List <string>(); if (listAst != null && listAst.Trim().Length > 0) { Attributes = JsonConvert.DeserializeObject <List <string> >(listAst); } List <string> quantity = new List <string>(); if (qty != null && qty.Trim().Length > 0) { quantity = JsonConvert.DeserializeObject <List <string> >(qty); } List <string> Locators = new List <string>(); if (listLoc != null && listLoc.Trim().Length > 0) { Locators = JsonConvert.DeserializeObject <List <string> >(listLoc); } VIS.Models.InfoProductModel model = new Models.InfoProductModel(); var value = model.SetProductQtyStockTrasfer(id, keyColumn, AD_Table_ID, prodID, uomID, Attributes, quantity, Locators, locatorTo, lineID, ContainerID, Session["ctx"] as Ctx); return(Json(new { result = value }, JsonRequestBehavior.AllowGet)); }
public JsonResult GetData(string sql, string tableName) { VIS.Models.InfoProductModel model = new Models.InfoProductModel(); //model.GetSchema(Ad_InfoWindow_ID); return(Json(JsonConvert.SerializeObject(model.GetData(sql, tableName, Session["ctx"] as Ctx)), JsonRequestBehavior.AllowGet)); }
public JsonResult GetInfoColumns(string tableName) { VIS.Models.InfoProductModel model = new Models.InfoProductModel(); return(Json(JsonConvert.SerializeObject(model.GetInfoColumns(Session["ctx"] as Ctx)), JsonRequestBehavior.AllowGet)); }