Esempio n. 1
0
        public void UpdateSkills()
        {
            var skills = new List <ProjectRequiredSkill>();

            if (!Requiredskillsidfks.IsEmpty() && !SkillsToAdd.IsEmpty())
            {
                skills = Requiredskillsidfks.Union(SkillsToAdd).ToList();
            }
            else if (!Requiredskillsidfks.IsEmpty())
            {
                skills = Requiredskillsidfks.ToList();
            }
            else if (!SkillsToAdd.IsEmpty())
            {
                skills = SkillsToAdd;
            }

            Skills = new ObservableCollection <ProjectRequiredSkill>(
                skills.Where(rs => !SkillsToDelete.Any(s => s == rs))
                );
            RaisePropertyChanged(nameof(Skills));
        }
Esempio n. 2
0
        public void UpdateSkills()
        {
            var skills = new List <EmployeeSkill>();

            if (!Skillidfks.IsEmpty() && !SkillsToAdd.IsEmpty())
            {
                skills = Skillidfks.Union(SkillsToAdd).ToList();
            }
            else if (!Skillidfks.IsEmpty())
            {
                skills = Skillidfks.ToList();
            }
            else if (!SkillsToAdd.IsEmpty())
            {
                skills = SkillsToAdd;
            }

            Skills = new ObservableCollection <EmployeeSkill>(
                skills.Where(es => !SkillsToDelete.Any(s => s == es))
                );
            RaisePropertyChanged(nameof(Skills));
        }