Пример #1
0
        private void InitC2List()
        {
            this.C2EngityList = new List <BaiduPlatformCategory2Entity>();
            List <Category2or3ConfigurationEntity> category2List = BaiduDA.GetCategory2or3List("M", AppConfig.CompanyCode);

            if (category2List != null)
            {
                foreach (var c2 in category2List)
                {
                    ProductNumberAndMinPriceEntity productCountEntity = BaiduDA.GetProductCountByFrontEndCategory2SysNo(c2.CategorySysNo, AppConfig.CompanyCode);

                    BaiduPlatformCategory2Entity c2Entity = new BaiduPlatformCategory2Entity(c2.CategorySysNo, c2.CategoryName, productCountEntity.ProductCount, productCountEntity.MinPrice);
                    this.C2EngityList.Add(c2Entity);
                }
            }
        }
Пример #2
0
        private void InitC3List()
        {
            this.C3EngityList = new List <BaiduPlatformCategory3Entity>();
            category3List     = BaiduDA.GetCategory2or3List("L", AppConfig.CompanyCode);

            if (category3List != null)
            {
                foreach (var c3 in category3List)
                {
                    ProductNumberAndMinPriceEntity productCountEntity = BaiduDA.GetProductCountByFrontEndCategory3SysNo(c3.CategorySysNo, AppConfig.CompanyCode);

                    BaiduPlatformCategory3Entity c3Entity = new BaiduPlatformCategory3Entity(c3.CategorySysNo, c3.CategoryName, productCountEntity.ProductCount, productCountEntity.MinPrice);
                    this.C3EngityList.Add(c3Entity);
                }
            }
        }
Пример #3
0
        private void InitC1List()
        {
            this.C1EngityList = new List <BaiduPlatformCategory1Entity>();
            List <Category1ConfigurationEntity> category1ConfigList = BaiduDA.GetCategory1ConfigList();

            if (category1ConfigList != null)
            {
                foreach (var c1 in category1ConfigList)
                {
                    ProductNumberAndMinPriceEntity productCountEntity = BaiduDA.GetProductCountByFrontEndCategory1SysNo(c1.CategorySysNo, AppConfig.CompanyCode);

                    BaiduPlatformCategory1Entity c1Entity = new BaiduPlatformCategory1Entity(c1.CategorySysNo, c1.CategoryName, c1.CategoryAddress, productCountEntity.ProductCount, productCountEntity.MinPrice);
                    this.C1EngityList.Add(c1Entity);
                }
            }
        }
Пример #4
0
        private void InitCategoryManufacturerList()
        {
            this.CategoryManufacturerEntityList = new List <BaiduPlatformCategoryManufacturerEntity>();

            foreach (Category2or3ConfigurationEntity category in category3List)
            {
                foreach (BaiduManufacturerEntity manufacturerEntity in manufacturerList)
                {
                    CategoryManufacturerPathEntity path = BaiduDA.GetCategoryManufacturerPath(manufacturerEntity.ManufacturerSysNo, category.CategorySysNo);
                    ProductNumberAndMinPriceEntity productCountEntity = BaiduDA.GetProductCountByFrontEndCategory3SysNoAndManufacturerSysNo(category.CategorySysNo, manufacturerEntity.ManufacturerSysNo, AppConfig.CompanyCode);

                    if (path != null)
                    {
                        BaiduPlatformCategoryManufacturerEntity categoryBrandEntity = new BaiduPlatformCategoryManufacturerEntity(category.CategorySysNo, category.CategoryName,
                                                                                                                                  path.PathSegment, path.ManufacturerSegment, manufacturerEntity.ManufacturerName, productCountEntity.ProductCount, productCountEntity.MinPrice);

                        this.CategoryManufacturerEntityList.Add(categoryBrandEntity);
                    }
                }
            }
        }