Subversion Repositories SmartDukaan

Rev

Rev 33119 | Rev 33127 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 33119 Rev 33121
Line 116... Line 116...
116
    }
116
    }
117
 
117
 
118
    public List<BrandStockPrice> getBrandStockPrices(int fofoId, boolean allBrands) throws Exception {
118
    public List<BrandStockPrice> getBrandStockPrices(int fofoId, boolean allBrands) throws Exception {
119
        Map<String, BrandStockPrice> brandStockPricesMap = inventoryService.getBrandWiseStockValue(fofoId);
119
        Map<String, BrandStockPrice> brandStockPricesMap = inventoryService.getBrandWiseStockValue(fofoId);
120
        List<BrandStockPrice> brandStockPrices = new ArrayList<>();
120
        List<BrandStockPrice> brandStockPrices = new ArrayList<>();
121
        List<BrandCatalog> mobileBrands = brandsService.getBrands(fofoId, null, 3);
121
        List<BrandCatalog> mobileBrands = brandsService.getBrands(3);
122
        mobileBrands.stream().forEach(x -> {
122
        mobileBrands.stream().forEach(x -> {
123
            if (brandStockPricesMap.containsKey(x.getName())) {
123
            if (brandStockPricesMap.containsKey(x.getName())) {
124
                BrandStockPrice brandStockPrice = brandStockPricesMap.get(x.getName());
124
                BrandStockPrice brandStockPrice = brandStockPricesMap.get(x.getName());
125
                brandStockPrice.setBrandUrl(x.getLogoUrl());
125
                brandStockPrice.setBrandUrl(x.getLogoUrl());
126
                brandStockPrice.setRank(x.getBrandCategory().getRank());
126
                brandStockPrice.setRank(x.getBrandCategory().getRank());