public JsonResult InsertProduts(SalesProductDetails objdetails) { //_objBLSetting.Region_Code = Region_Code; //_objBLSetting.subDomainName = subDomainName; return(Json(_objBLSetting.InsertProduts(objdetails), JsonRequestBehavior.AllowGet)); //return _objBLSetting.productdetails(Region_Code); }
public string InsertProduts(SalesProductDetails obj) { string result = string.Empty; try { using (IDbConnection connection = IDbOpenConnection()) { var p = new DynamicParameters(); p.Add("@Tvp_ProductList", ToDataTable(obj.lst).AsTableValuedParameter()); p.Add("@Result", "", dbType: DbType.String, direction: ParameterDirection.Output); var res = connection.Query <string>("Sp_Hd_InsertProduct", p, commandType: CommandType.StoredProcedure); result = p.Get <string>("@Result"); connection.Close(); } } catch (Exception ex) { throw; } return(result); }
public string InsertProduts(SalesProductDetails obj) { DAL_Setting _objDALSetting = new DAL_Setting(); return(_objDALSetting.InsertProduts(obj)); }