예제 #1
0
        /// <summary>
        /// 取周边门店轮播图、图标
        /// </summary>
        /// <returns></returns>
        public static List <Mall.DTO.SlideAdModel> GetShopBranchListSlide()
        {
            List <SlideAdInfo.SlideAdType> slideTypes = new List <SlideAdInfo.SlideAdType>()
            {
            };

            slideTypes.Add(SlideAdInfo.SlideAdType.NearShopBranchHome);    //轮播图1
            slideTypes.Add(SlideAdInfo.SlideAdType.NearShopBranchIcon);    //图标
            slideTypes.Add(SlideAdInfo.SlideAdType.NearShopBranchSpecial); //广告图
            slideTypes.Add(SlideAdInfo.SlideAdType.NearShopBranchHome2);   //轮播图2

            var models = _iSlideAdsService.GetSlidAdsByTypes(0, slideTypes).OrderBy(a => a.DisplaySequence);
            var m      = models.Select(a => new Mall.DTO.SlideAdModel()
            {
                Id              = a.Id,
                ShopId          = a.ShopId,
                DisplaySequence = a.DisplaySequence,
                ImageUrl        = Mall.Core.MallIO.GetRomoteImagePath(a.ImageUrl),
                TypeId          = a.TypeId,
                Url             = a.Url,
                Description     = a.Description
            }).ToList();

            return(m);
        }