Beispiel #1
0
 private bool Update()
 {
     return(DBCouponUsageHistory.Update(
                this.historyID,
                this.couponID,
                this.orderID,
                this.createdOn));
 }
Beispiel #2
0
 private void GetCouponUsageHistory(int historyId)
 {
     using (IDataReader reader = DBCouponUsageHistory.GetOne(historyId))
     {
         if (reader.Read())
         {
             this.historyID = Convert.ToInt32(reader["HistoryID"]);
             this.couponID  = Convert.ToInt32(reader["CouponID"]);
             this.orderID   = Convert.ToInt32(reader["OrderID"]);
             this.createdOn = Convert.ToDateTime(reader["CreatedOn"]);
         }
     }
 }
Beispiel #3
0
        private bool Create()
        {
            int newID = 0;

            newID = DBCouponUsageHistory.Create(
                this.couponID,
                this.orderID,
                this.createdOn);

            this.historyID = newID;

            return(newID > 0);
        }
Beispiel #4
0
        public static IDataReader GetByCoupon(int couponId)
        {
            IDataReader reader = DBCouponUsageHistory.GetByCoupon(couponId);

            return(reader); //LoadListFromReader(reader);
        }
Beispiel #5
0
 public static bool DeleteByOrder(int orderId)
 {
     return(DBCouponUsageHistory.DeleteByOrder(orderId));
 }
Beispiel #6
0
 public static bool DeleteByCoupon(int couponId)
 {
     return(DBCouponUsageHistory.DeleteByCoupon(couponId));
 }
Beispiel #7
0
 public static bool Delete(int historyId)
 {
     return(DBCouponUsageHistory.Delete(historyId));
 }
Beispiel #8
0
 public static int GetCountByCoupon(int couponId)
 {
     return(DBCouponUsageHistory.GetCountByCoupon(couponId));
 }