public string BookieConfirm_Select(string MatchDate) { BookieBL BBL = new BookieBL(); BookieModel BModel = new BookieModel(); BModel.MatchDate = MatchDate; return(BBL.BookieConfirm_Select(BModel)); }
public string BookieConfirm_Select(BookieModel BModel) { BaseDL bdl = new BaseDL(); Function fun = new Function(); DateTime dt = DateTime.ParseExact(BModel.MatchDate.Replace("-", "/"), "dd/MM/yyyy", CultureInfo.GetCultureInfo("en-us")); SqlParameter[] prms = new SqlParameter[1]; prms[0] = new SqlParameter("@MatchDate", SqlDbType.Date) { Value = dt }; DataTable DTBookieConfirm = bdl.SelectData("M_Match_BookieConfirm_Select", prms); return(fun.DataTableToJSONWithJSONNet(DTBookieConfirm)); }
public string BookieConfirmSave(string Table, string MatchDate) { if (Session["UserInfo"] == null) { return("2");//session time out } string userInfo = Session["UserInfo"] as string; BookieBL BBL = new BookieBL(); BookieModel BModel = new BookieModel(); BModel.MatchDate = MatchDate; BModel.BookieConfirmJson = Table; BModel.UserID = userInfo.Split('_')[0]; return(BBL.BookieConfirm_Insert(BModel)); }
public string BookieConfirm_Insert(BookieModel BModel) { BaseDL bdl = new BaseDL(); SqlParameter[] prms = new SqlParameter[2]; prms[0] = new SqlParameter("@UserID", SqlDbType.VarChar) { Value = BModel.UserID }; prms[1] = new SqlParameter("@BookieConfirmJson", SqlDbType.VarChar) { Value = BModel.BookieConfirmJson }; if (bdl.InsertUpdateDeleteData("BookieGambling_Insert", prms)) { return("1"); } return("0"); }