Beispiel #1
0
        //public CharacterImageTile GetById(int? id)
        //{
        //    throw new NotImplementedException();
        //}

        public async Task<CharacterCharacterStatClusterTile> Update(CharacterCharacterStatClusterTile item)
        {

            var clusterTile = await _repo.Get((int)item.CharacterStatClusterTileId);

            if (clusterTile == null)
                return clusterTile;

            clusterTile.DisplayCharactersCharacterStatID = item.DisplayCharactersCharacterStatID;
            clusterTile.Title = item.Title;
            
            clusterTile.BodyBgColor = item.BodyBgColor;
            clusterTile.BodyTextColor = item.BodyTextColor;
            clusterTile.TitleBgColor = item.TitleBgColor;
            clusterTile.TitleTextColor = item.TitleTextColor;
            clusterTile.Shape = item.Shape;
            clusterTile.SortOrder = item.SortOrder;
            clusterTile.ClusterWithSortOrder = item.ClusterWithSortOrder;
            clusterTile.IsManual = item.IsManual;
            clusterTile.FontSize = item.FontSize;
            clusterTile.FontSizeTitle = item.FontSizeTitle;
            try
            {
                await _repo.Update(clusterTile);
            }
            catch (Exception ex)
            {
                throw ex;
            }

            return clusterTile;
        }
Beispiel #2
0
 public async Task<CharacterCharacterStatClusterTile> Create(CharacterCharacterStatClusterTile item)
 {
     return await _repo.Add(item);
 }