Пример #1
0
        public List <StoreSaleEntity> Get_List_StoreSale_Open()
        {
            List <StoreSaleEntity> list = new List <StoreSaleEntity>();

            if (dbContext == null)
            {
                dbContext = new FoodDeliveryEntities();
            }
            var listvar = dbContext.GET_SALE_OPEN().ToList();

            foreach (var obj in listvar)
            {
                StoreSaleEntity entity = new StoreSaleEntity
                {
                    StoreSaleID = obj.StoreSaleID,
                    Sale        = (int)obj.Sale,
                    StratSale   = "" + obj.StartSale,
                    StoreID     = "" + obj.StoreID,
                    StopSale    = "" + obj.StopSale
                };
                list.Add(entity);
            }

            return(list);
        }