예제 #1
0
        public async Task <CharacterExecuteTile> Update(CharacterExecuteTile item)
        {
            var extile = await _repo.Get((int)item.ExecuteTileId);

            if (extile == null)
            {
                return(extile);
            }

            extile.CommandId        = item.CommandId;
            extile.ShowTitle        = item.ShowTitle;
            extile.DisplayLinkImage = item.DisplayLinkImage;
            extile.LinkType         = item.LinkType;
            extile.AbilityId        = item.AbilityId;
            extile.BuffAndEffectId  = item.BuffAndEffectId;
            extile.SpellId          = item.SpellId;
            extile.ItemId           = item.ItemId;
            extile.AllyId           = item.AllyId;

            //extile.Color = item.Color;
            //extile.BgColor = item.BgColor;
            extile.BodyBgColor    = item.BodyBgColor;
            extile.BodyTextColor  = item.BodyTextColor;
            extile.TitleBgColor   = item.TitleBgColor;
            extile.TitleTextColor = item.TitleTextColor;
            extile.Shape          = item.Shape;
            extile.SortOrder      = item.SortOrder;
            extile.IsManual       = item.IsManual;
            extile.FontSize       = item.FontSize;
            extile.FontSizeTitle  = item.FontSizeTitle;

            try
            {
                await _repo.Update(extile);
            }
            catch (Exception ex)
            {
                throw ex;
            }

            return(extile);
        }
예제 #2
0
 public async Task <CharacterExecuteTile> Create(CharacterExecuteTile item)
 {
     return(await _repo.Add(item));
 }