| Line 385... |
Line 385... |
| 385 |
return responseSender.ok(fofoStoreRepository.selectByRetailerId(fofoId).getCode());
|
385 |
return responseSender.ok(fofoStoreRepository.selectByRetailerId(fofoId).getCode());
|
| 386 |
}
|
386 |
}
|
| 387 |
|
387 |
|
| 388 |
@RequestMapping(value = "/store/listing", method = RequestMethod.GET, produces = MediaType.APPLICATION_JSON_VALUE)
|
388 |
@RequestMapping(value = "/store/listing", method = RequestMethod.GET, produces = MediaType.APPLICATION_JSON_VALUE)
|
| 389 |
@Cacheable(value = "storelisting.all", cacheManager = "thirtyMinsTimeOutCacheManager")
|
389 |
@Cacheable(value = "storelisting.all", cacheManager = "thirtyMinsTimeOutCacheManager")
|
| 390 |
public ResponseEntity<?> getStoresListing(HttpServletRequest request, @PathVariable String pincode)
|
390 |
public ResponseEntity<?> getStoresListing(HttpServletRequest request)
|
| 391 |
throws Exception {
|
391 |
throws Exception {
|
| 392 |
List<WebListing> webListings = webListingRepository.selectAllWebListing(Optional.of(true));
|
392 |
List<WebListing> webListings = webListingRepository.selectAllWebListing(Optional.of(true));
|
| 393 |
for (WebListing webListing : webListings) {
|
393 |
for (WebListing webListing : webListings) {
|
| 394 |
List<Integer> webProducts = webProductListingRepository.selectAllByWebListingId(webListing.getId()).stream()
|
394 |
List<Integer> webProducts = webProductListingRepository.selectAllByWebListingId(webListing.getId()).stream()
|
| 395 |
.filter(x -> x.getRank() > 0).map(x -> x.getEntityId()).collect(Collectors.toList());
|
395 |
.filter(x -> x.getRank() > 0).map(x -> x.getEntityId()).collect(Collectors.toList());
|