Subversion Repositories SmartDukaan

Rev

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

Rev 24996 Rev 24999
Line 249... Line 249...
249
		}
249
		}
250
		Map<String, BrandStockPrice> brandStockPricesMap = inventoryService.getBrandWiseStockValue(loginDetails.getFofoId());
250
		Map<String, BrandStockPrice> brandStockPricesMap = inventoryService.getBrandWiseStockValue(loginDetails.getFofoId());
251
		List<DBObject> mobileBrands = mongoClient.getMongoBrands(loginDetails.getFofoId(), loginDetails.getEmailId(), 3);
251
		List<DBObject> mobileBrands = mongoClient.getMongoBrands(loginDetails.getFofoId(), loginDetails.getEmailId(), 3);
252
		List<BrandStockPrice> brandStockPrices = new ArrayList<>();
252
		List<BrandStockPrice> brandStockPrices = new ArrayList<>();
253
		mobileBrands.stream().forEach(x->{
253
		mobileBrands.stream().forEach(x->{
254
			String brand = (String)x.get("brand");
254
			String brand = (String)x.get("name");
255
			if(brandStockPricesMap.containsKey(brand)) {
255
			if(brandStockPricesMap.containsKey(brand)) {
256
				BrandStockPrice brandStockPrice = brandStockPricesMap.get(brand);
256
				BrandStockPrice brandStockPrice = brandStockPricesMap.get(brand);
257
				brandStockPrice.setBrandUrl((String)x.get("url"));
257
				brandStockPrice.setBrandUrl((String)x.get("url"));
258
				brandStockPrice.setRank((int)x.get("rank"));
258
				brandStockPrice.setRank((int)x.get("rank"));
259
				brandStockPrices.add(brandStockPrice);
259
				brandStockPrices.add(brandStockPrice);