public List <OrderViewModel> GetOrderByAccount(string id) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_OrderSelectByAccount", "@Id", id); var lst = Ultis.DataTableToList <OrderViewModel>(dtb); return(lst); }
public List <CommentViewModel> GetCommentByProductId(Guid id) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_CommentSelectByProductId", "@Id", id); var lst = Ultis.DataTableToList <CommentViewModel>(dtb); return(lst); }
public List <ProductAttributeViewModel> GetAllProducAttributebySP(Guid masanpham) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("LoadAttr", "@Id", masanpham); var lst = Ultis.DataTableToList <ProductAttributeViewModel>(dtb); return(lst); }
public List <NewsViewModel> GetAllNews() { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_NewsSelectAll"); var lst = Ultis.DataTableToList <NewsViewModel>(dtb); return(lst); }
public List <ProductGroupViewModel> GetAllProductGroup() { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_ProductGroupSelectAll"); var lst = Ultis.DataTableToList <ProductGroupViewModel>(dtb); return(lst); }
public List <OrderDetailViewModel> GetOrderDetailByOrder(Guid id) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_OrderDetailSelectByOrder", "@Id", id); var lst = Ultis.DataTableToList <OrderDetailViewModel>(dtb); return(lst); }
public List <ProductAttributeValueViewModel> GetProductAttributeValueByProId(Guid Id) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Product_Attribute_ValueSelectByProId", "@Id", Id); var lst = Ultis.DataTableToList <ProductAttributeValueViewModel>(dtb); return(lst); }
public List <OrderViewModel> GetAllOrder() { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_OrderSelectAll"); var lst = Ultis.DataTableToList <OrderViewModel>(dtb); return(lst); }
public List <MenuViewModel> GetMenuByPId(Guid id) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_MenuSelectByPID", "@Id", id); var lst = Ultis.DataTableToList <MenuViewModel>(dtb); return(lst); }
public List <MenuViewModel> GetAllMenu() { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_MenuSelectAll"); var lst = Ultis.DataTableToList <MenuViewModel>(dtb); return(lst); }
public List <ProductAttributeValueViewModel> GetAllProductAttributeValue() { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Product_Attribute_ValueSelectAll"); var lst = Ultis.DataTableToList <ProductAttributeValueViewModel>(dtb); return(lst); }
public List <AccountViewModel> GetAllAccount() { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_AccountSelectAll"); var lst = Ultis.DataTableToList <AccountViewModel>(dtb); return(lst); }
public List <RoleDetailViewModel> GetAllAccountGroup() { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_DetailRoleSelectAll"); var lst = Ultis.DataTableToList <RoleDetailViewModel>(dtb); return(lst); }
public RoleViewModel GetRoleById(Guid Id) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_RoleSelectByID", "@Id", Id); RoleViewModel role = new RoleViewModel(); foreach (DataRow item in dtb.Rows) { role = Ultis.GetItem <RoleViewModel>(item); } return(role); }
public RoleDetailViewModel GetAccountGroupById(Guid Id) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_DetailRoleSelectByID", "@Id", Id); RoleDetailViewModel accgr = new RoleDetailViewModel(); foreach (DataRow item in dtb.Rows) { accgr = Ultis.GetItem <RoleDetailViewModel>(item); } return(accgr); }
public CommentViewModel GetCommentById(Guid id) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_CommentSelectByID", "@Id", id); CommentViewModel role = new CommentViewModel(); foreach (DataRow item in dtb.Rows) { role = Ultis.GetItem <CommentViewModel>(item); } return(role); }
public MenuViewModel GetMenuById(Guid id) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_MenuSelectByID", "@Id", id); MenuViewModel role = new MenuViewModel(); foreach (DataRow item in dtb.Rows) { role = Ultis.GetItem <MenuViewModel>(item); } return(role); }
public CompanyInfoViewModel GetCompanyInfo() { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_InforCompanySelectAll"); CompanyInfoViewModel role = new CompanyInfoViewModel(); foreach (DataRow item in dtb.Rows) { role = Ultis.GetItem <CompanyInfoViewModel>(item); } return(role); }
public ProductAttributeValueViewModel GetProductAttributeValueById(Guid Id) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Product_Attribute_ValueSelectByID", "@Id", Id); ProductAttributeValueViewModel role = new ProductAttributeValueViewModel(); foreach (DataRow item in dtb.Rows) { role = Ultis.GetItem <ProductAttributeValueViewModel>(item); } return(role); }
public ProductGroupViewModel GetProductGroupById(Guid Id) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_ProductGroupSelectByID", "@Id", Id); ProductGroupViewModel role = new ProductGroupViewModel(); foreach (DataRow item in dtb.Rows) { role = Ultis.GetItem <ProductGroupViewModel>(item); } return(role); }
public OrderDetailViewModel GetOrderEtailById(Guid proid, Guid oid) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_OrderDetailSelectByID", "@ProductId", proid, "@OrderID", oid); OrderDetailViewModel role = new OrderDetailViewModel(); foreach (DataRow item in dtb.Rows) { role = Ultis.GetItem <OrderDetailViewModel>(item); } return(role); }
public OrderViewModel GetOrderById(Guid id) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_OrderSelectByID", "@Id", id); OrderViewModel role = new OrderViewModel(); foreach (DataRow item in dtb.Rows) { role = Ultis.GetItem <OrderViewModel>(item); } return(role); }
public NewsViewModel GetNewsById(Guid Id) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_NewsSelectByID", "@Id", Id); NewsViewModel role = new NewsViewModel(); foreach (DataRow item in dtb.Rows) { role = Ultis.GetItem <NewsViewModel>(item); } return(role); }
public AccountViewModel GetAccountByEmail(string email) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_AccountSelectByEmail", "@Email", email); AccountViewModel acc = new AccountViewModel(); foreach (DataRow item in dtb.Rows) { acc = Ultis.GetItem <AccountViewModel>(item); } return(acc); }
public AccountViewModel GetAccountById(Guid Id) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_AccountSelectByID", "@Id", Id); AccountViewModel acc = new AccountViewModel(); foreach (DataRow item in dtb.Rows) { acc = Ultis.GetItem <AccountViewModel>(item); } return(acc); }
public AccountViewModel GetAccountByUserName(string userName) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("Tbl_AccountSelectByUserName1", "@UserName", userName); AccountViewModel acc = new AccountViewModel(); foreach (DataRow item in dtb.Rows) { acc = Ultis.GetItem <AccountViewModel>(item); } return(acc); }
public string GetRoleByGroup(string group) { DataTable dtb = SqlDb_Ultis.ExeStoredToDataTable("GetRoleByGroup", "@group", group); string rs; if (dtb.Rows.Count > 0) { rs = dtb.Rows[0][0].ToString() ?? String.Empty; } else { rs = ""; } return(rs); }