public IHttpActionResult GetEmailDistributionListWithID([FromUri] int EmailDistributionListID, [FromUri] string lang = "en", [FromUri] string extra = "")
        {
            using (CSSPDBContext db = new CSSPDBContext(DatabaseType))
            {
                EmailDistributionListService emailDistributionListService = new EmailDistributionListService(new Query()
                {
                    Language = (lang == "fr" ? LanguageEnum.fr : LanguageEnum.en)
                }, db, ContactID);

                emailDistributionListService.Query = emailDistributionListService.FillQuery(typeof(EmailDistributionList), lang, 0, 1, "", "", extra);

                if (emailDistributionListService.Query.Extra == "A")
                {
                    EmailDistributionListExtraA emailDistributionListExtraA = new EmailDistributionListExtraA();
                    emailDistributionListExtraA = emailDistributionListService.GetEmailDistributionListExtraAWithEmailDistributionListID(EmailDistributionListID);

                    if (emailDistributionListExtraA == null)
                    {
                        return(NotFound());
                    }

                    return(Ok(emailDistributionListExtraA));
                }
                else if (emailDistributionListService.Query.Extra == "B")
                {
                    EmailDistributionListExtraB emailDistributionListExtraB = new EmailDistributionListExtraB();
                    emailDistributionListExtraB = emailDistributionListService.GetEmailDistributionListExtraBWithEmailDistributionListID(EmailDistributionListID);

                    if (emailDistributionListExtraB == null)
                    {
                        return(NotFound());
                    }

                    return(Ok(emailDistributionListExtraB));
                }
                else
                {
                    EmailDistributionList emailDistributionList = new EmailDistributionList();
                    emailDistributionList = emailDistributionListService.GetEmailDistributionListWithEmailDistributionListID(EmailDistributionListID);

                    if (emailDistributionList == null)
                    {
                        return(NotFound());
                    }

                    return(Ok(emailDistributionList));
                }
            }
        }
 public EmailDistributionListTest()
 {
     emailDistributionList       = new EmailDistributionList();
     emailDistributionListExtraA = new EmailDistributionListExtraA();
     emailDistributionListExtraB = new EmailDistributionListExtraB();
 }