コード例 #1
0
        public ActionResult AddNewItem(ItemInfoDA Item)
        {

            try
            {
                var memId = RDN.Library.Classes.Account.User.GetMemberId();
                var league = MemberCache.GetLeagueOfMember(memId);
                Item.ItemsForLeague = league.LeagueId;
                Item.ItemAddByMember = memId;

                bool execute = RDN.Library.Classes.League.ItemInfoDA.Add_New_Item(Item);

            }
            catch (Exception exception)
            {
                ErrorDatabaseManager.AddException(exception, exception.GetType());
            }

            return Redirect(Url.Content("~/league/inventory/all?u=" + SiteMessagesEnum.sac));
        }
コード例 #2
0
        private static ItemInfoDA DisplayItemList(DataModels.League.ItemInfo oItem)
        {
            ItemInfoDA bl = new ItemInfoDA();
            bl.ItemId = oItem.ItemId;
            bl.ItemName = oItem.ItemName;
            bl.ItemSerialNo = oItem.ItemSerialNo;
            bl.Location = oItem.Location;
            bl.Quantity = oItem.Quantity;
            bl.Notes = oItem.Notes;
            bl.UnitePice = oItem.UnitePice;
            bl.ItemAddByMember = oItem.ItemAddByMember.MemberId;
            bl.ItemsForLeague = oItem.ItemsForLeague.LeagueId;

            return bl;
        }
コード例 #3
0
        public ActionResult EditItem(ItemInfoDA oItem)
        {
            try
            {
                bool execute = RDN.Library.Classes.League.ItemInfoDA.UpdateItemInfo(oItem);

                return Redirect(Url.Content("~/league/inventory/all?u=" + SiteMessagesEnum.s));
            }
            catch (Exception exception)
            {
                ErrorDatabaseManager.AddException(exception, exception.GetType());
            }
            return Redirect(Url.Content("~/?u=" + SiteMessagesEnum.sww));

        }