Esempio n. 1
0
        bool setChosenGroup(int groupId)
        {
            var group = CurrentGroups.SingleOrDefault(
                g => g.GroupId == groupId);

            return(setChosenGroup(group));
        }
Esempio n. 2
0
        protected void subjectChosen(object chosenObject)
        {
            try {
                var id = Convert.ToInt32(chosenObject);

                if (id == -1)
                {
                    return;
                }

                var group    = CurrentGroups.SingleOrDefault(s => s.GroupId == id);
                var isChosen = setChosenGroup(group);

                if (isChosen)
                {
                    GroupChanged?.Invoke(PlatformServices.Preferences.GroupId, group.GroupName);
                }
            } catch (Exception ex) {
                AppLogs.Log(ex);
            }
        }