Example #1
0
 private static string GetProductID()
 {
     if (globalProductID == -1)
     {
         globalProductID = StockSyncher.GetMaxEntityID(StoreDL.Instance.GetAllProductIDs());
     }
     globalProductID++;
     return("P" + globalProductID);
 }
Example #2
0
 private static string GetDiscountCode()
 {
     if (globalDiscountCode == -1)
     {
         globalDiscountCode = StockSyncher.GetMaxEntityID(StoreDL.Instance.GetAllDiscountIDs());
     }
     globalDiscountCode++;
     return("D" + globalDiscountCode);
 }
Example #3
0
 private static string GetDiscountCode()
 {
     if (_globalCategoryDiscountCode == -1)
     {
         _globalCategoryDiscountCode = StockSyncher.GetMaxEntityID(StoreDL.Instance.GetAllCategoryDiscountIDs());
     }
     _globalCategoryDiscountCode++;
     return("d" + _globalCategoryDiscountCode);
 }
Example #4
0
 private static string GetLotteryTicketID()
 {
     if (globalLotteryTicketID == -1)
     {
         globalLotteryTicketID = StockSyncher.GetMaxEntityID(StoreDL.Instance.GetAllLotteryTicketIDs());
     }
     globalLotteryTicketID++;
     return("T" + globalLotteryTicketID);
 }
Example #5
0
 private static string GetNextStoreId()
 {
     if (storeIdCounter == -1)
     {
         storeIdCounter = StockSyncher.GetMaxEntityID(StoreDL.Instance.GetAllStoresIDs());
     }
     storeIdCounter++;
     return("S" + storeIdCounter);
 }
Example #6
0
        private bool Equals(LotteryTicket obj)
        {
            StockSyncher handler = StockSyncher.Instance;

            return(obj.IntervalStart == IntervalStart &&
                   obj.IntervalEnd == IntervalEnd &&
                   obj.LotteryNumber == LotteryNumber &&
                   obj.myID == myID &&
                   EnumStringConverter.PrintEnum(obj.myStatus).Equals(EnumStringConverter.PrintEnum(myStatus)) &&
                   obj.UserID == UserID
                   );
        }