예제 #1
0
 public RequestActivity Create(RequestActivity act)
 {
     return _dal.Create(act);
 }
        public PageDataResult<RequestActivity> TestCreateActivity()
        {
            var act = new RequestActivity {
                ActiveID=Guid.NewGuid(),
                ActiveTitle="测试活动",
                ActiveName="我们做游戏吧",
                ActiveCommodityPhoto="",
                ActiveContents="",
                BuyerSubsidies=0.00M,
                IsLockPrice=false,
                CanGetPrice=0.00M,
                CommodityID=1,
                Content="",
                HighSalePrice=0.00M,
                Context="",
                SilverShopFee=0.02M,
                Icon="",
                Icon2="",
                LowSalePrice=0.00M,
                Subsidies=0.02M,
                MainPhoto="",
                MarketPrice=0.23M,
                PhotoAddress="",
                Photos="",
                PublicSupplyPrice=0213.93M,
                RecommendSalePrice= "",
                RecommendText="",
                SaleAmount=10,
                ShopGoodsId="",
                Sku="",
                SkuKey="",
                TPType=10,
                TypeName="",
                WarehouseName="",
                BeginTime=DateTime.Now,
                EndTime=DateTime.Now,
                Disabled=false


            };
            var result = _bll.Create(act);
            return new PageDataResult<RequestActivity> { flag = EnumActionFlag.success, Data = result };
        }
예제 #3
0
 public RequestActivity Create(RequestActivity act)
 {
     db.RequestActivity.Add(act);
     db.SaveChanges();
     return act;
 }