//------------------------------------------------------------------------------- #region -GetGenreSearchResult ジャンル検索結果表示 //------------------------------------------------------------------------------- // private async Task<List<DispCircleInfo>> GetGenreSearchResult(string genreStr) { var res = await _catalogData.SearchCirclesByGenre(genreStr); List<DispCircleInfo> list = new List<DispCircleInfo>(); foreach (var cc in res) { var element = new DispCircleInfo() { Block = await _catalogData.GetBlockChr(cc.blockId), Area = await _catalogData.GetAreaChar(cc.blockId), Day = cc.day, CircleName = cc.circleName, CircleKana = cc.circleKana, PenName = cc.penName, BookName = cc.bookName, Description = cc.description, URL = cc.url, GenreStr = await _catalogData.GetGenreStringById(cc.genreId), Mail = cc.mailAddr, SpaceNo = cc.spaceNo, SpaceNoSub = cc.spaceNoSub, SerialNo = cc.updateId, MapX = cc.xpos, MapY = cc.ypos, Layout = cc.layout }; list.Add(element); } return list; }
//------------------------------------------------------------------------------- #endregion ((clas)IndicatorColorController ) //------------------------------------------------------------------------------- #region -GetCanvasIndex //------------------------------------------------------------------------------- // private async Task<int> GetCanvasIndex(DispCircleInfo item) { string area = await _catalogData.GetBigArea(item.Block); int canvasIndex = (item.Day == 1 && area == _mapName1) ? 0 : (item.Day == 1 && area == _mapName2) ? 1 : (item.Day == 1 && area == _mapName3) ? 2 : (item.Day == 2 && area == _mapName1) ? 3 : (item.Day == 2 && area == _mapName2) ? 4 : (item.Day == 2 && area == _mapName3) ? 5 : (item.Day == 3 && area == _mapName1) ? 6 : (item.Day == 3 && area == _mapName2) ? 7 : (item.Day == 3 && area == _mapName3) ? 8 : -1; return canvasIndex; }
//------------------------------------------------------------------------------- #region -GetCheckList チェックリストデータ取得 //------------------------------------------------------------------------------- // private async Task<List<DispCircleInfo>> GetCheckList(string queryStr) { var list = new List<DispCircleInfo>(); var items = (string.IsNullOrEmpty(queryStr)) ? _checkList.CircleList_Day1.Concat(_checkList.CircleList_Day2).Concat(_checkList.CircleList_Day3) : _checkList.CircleList_Day1.Where(cfci => cfci.Memo.Contains(queryStr)) .Concat(_checkList.CircleList_Day2.Where(cfci => cfci.Memo.Contains(queryStr))) .Concat(_checkList.CircleList_Day3.Where(cfci => cfci.Memo.Contains(queryStr))); foreach (var item in items) { var element = new DispCircleInfo() { Block = item.Block, Area = await _catalogData.GetAreaChar(item.Block), Day = await _catalogData.GetDayIndex(item.DayOfWeek), CircleName = item.CircleName, CircleKana = item.CircleKana, PenName = item.PenName, BookName = item.BookName, Description = item.Description, URL = item.URL, GenreStr = await _catalogData.GetGenreStringByCode(item.GenreCode), Mail = item.Mail, SpaceNo = item.SpaceNo, SpaceNoSub = item.SpaceNoSub, Memo = item.Memo, MapX = item.MapX, MapY = item.MapY, Layout = item.Layout, SerialNo = item.SerialNo, ColorIndex = item.ColorIndex, IndexToColorFunc = _checkList.ColorIndexToColorFunc }; list.Add(element); } return list; }