public void InitializeElection(ElectionModels.Election election) { if (election != null) { IMapper mapper = Utils.CreateMapper(); mapper.Map <ElectionModels.Election, ElectionViewModel>(election, this); CategoryTypes = Utils.CategoryTypes(); SelectedCategoryType = CategoryTypes.SingleOrDefault(n => n.Id == (int)CategoryTypeEnum.measure); HasLoaded = true; } }
public void RefreshSelectedCategory() { SelectedCategoryType = CategoryTypes.SingleOrDefault(n => n.Id == (int)CategoryTypeId); SubTitleVisible = InformationVisible = true; }