internal void ShowContributors(Role role)
        {
            AbstractPersonRepository     pRepo  = _personRepository;
            AbstractFilmPersonRepository fpRepo = _filmPersonRepository;
            List <Guid>   ids   = fpRepo.ListPersonIdsForilmIdAndRole(CurrentFilm.Id, role);
            List <string> names = new List <string>();

            foreach (Guid id in ids)
            {
                Person p = pRepo.GetById(id);
                names.Add(p.FullName);
            }
            if (names.Count > 0)
            {
                StringChooser chooser = new StringChooser(names);
                chooser.Show();
            }
            else
            {
                string[] contribkind = { "contributors", "actors", "composers", "directors", "scriptwriters" };

                string kind = contribkind[(int)role];

                ReportIt("There are (as yet) no " + kind + " defined for this film");
            }
        }
        private bool CheckForMissingInfo()
        {
            bool result = true;
            Guid id     = CurrentFilm.Id;
            AbstractFilmPersonRepository  fpRepo = _filmPersonRepository;
            AbstractFilmCountryRepository fcRepo = _filmCountryRepository;
            List <Guid> ids        = fpRepo.ListPersonIdsForilmIdAndRole(id, Role.Actor);
            int         actorCount = ids.Count;

            ids = fpRepo.ListPersonIdsForilmIdAndRole(id, Role.Composer);
            int composerCount = ids.Count;

            ids = fpRepo.ListPersonIdsForilmIdAndRole(id, Role.Director);
            int directorCount = ids.Count;

            ids = fcRepo.ListCountryIdsForFilmId(id);
            int countryCount = ids.Count;

            if (actorCount == 0)
            {
                ReportIt(CurrentFilm.Title + " has no actors.");
                result = false;
            }
            if (composerCount == 0)
            {
                ReportIt(CurrentFilm.Title + " has no composers.");
                result = false;
            }
            if (directorCount == 0)
            {
                ReportIt(CurrentFilm.Title + " has no directors.");
                result = false;
            }
            if (countryCount == 0)
            {
                ReportIt(CurrentFilm.Title + " has no countries.");
                result = false;
            }
            if (CurrentFilm.Location == null)
            {
                ReportIt(CurrentFilm.Title + "has no location");
                result = false;
            }
            return(result);
        }
        private List <Person> GetContributors(Role role)
        {
            List <Person> result = new List <Person>();
            AbstractFilmPersonRepository fpRepo = _view.FilmPersonRepository;
            AbstractPersonRepository     pRepo  = _view.PersonRepository;
            List <Guid> ids = fpRepo.ListPersonIdsForilmIdAndRole(Film.Id, role);

            foreach (Guid id in ids)
            {
                Person p = pRepo.GetById(id);
                result.Add(p);
            }
            return(result);
        }