コード例 #1
0
        public List <Convenue> GetListBillByDate(int day, int month, int year) // 14
        {
            List <Convenue> list = new List <Convenue>();
            DataTable       data = DataProvider.Instance.ExecuteQuery("EXEC USP_GetListBillByDate @day , @month , @year", new object[] { day, month, year });

            foreach (DataRow item in data.Rows)
            {
                Convenue convenue = new Convenue(item);
                list.Add(convenue);
            }

            return(list);
        }
コード例 #2
0
        public List <Convenue> GetListBillByDateAndPage(int day, int month, int year, int pageNum, int rowOfPage) // 14
        {
            List <Convenue> list = new List <Convenue>();
            DataTable       data = DataProvider.Instance.ExecuteQuery("EXEC USP_GetListBillByDateAndPage @day , @month , @year , @page , @rowOfPage", new object[] { day, month, year, pageNum, rowOfPage });

            foreach (DataRow item in data.Rows)
            {
                Convenue bill = new Convenue(item);
                list.Add(bill);
            }

            return(list);
        }
コード例 #3
0
        public List <Convenue> GetListBillByYear(int year) // 14
        {
            List <Convenue> list = new List <Convenue>();
            DataTable       data = DataProvider.Instance.ExecuteQuery(" SELECT t.NameTable  , DateCheckIn , DateCheckOut , b.Hour, b.Minute, Discount  ,b.TotalPrice FROM dbo.Bill AS b, dbo.TableFood AS t WHERE b.StatusBill = 1 AND t.IDTable = b.IDTable AND YEAR(b.DateCheckOut) = " + year + " ORDER BY b.DateCheckOut DESC ");

            foreach (DataRow item in data.Rows)
            {
                Convenue convenue = new Convenue(item);
                list.Add(convenue);
            }

            return(list);
        }