| 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(3);
|
121 |
List<BrandCatalog> mobileBrands = brandsService.getBrandsToDisplay(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());
|