Example #1
0
        private List <WebPage> GetWebPageFromBrandList(Predicate <BrandInfo> match)
        {
            List <WebPage> result = new List <WebPage>();
            var            list   = ExternalDomainBroker.GetBrandList();

            if (list != null)
            {
                var found = list.FindAll(match);
                if (found.Count > 0)
                {
                    found = found.OrderByDescending(p => p.SysNo).ToList();
                }
                foreach (var b in found)
                {
                    string pageName = "";
                    if (b.BrandNameLocal != null)
                    {
                        pageName += b.BrandNameLocal.Content;
                    }
                    pageName += b.BrandNameGlobal;
                    result.Add(new WebPage {
                        ID = b.SysNo, PageName = pageName
                    });
                }
            }
            return(result);
        }