| Line 406... |
Line 406... |
| 406 |
@RequestMapping(value = "/fofo/brands", method = RequestMethod.GET, produces = MediaType.APPLICATION_JSON_VALUE)
|
406 |
@RequestMapping(value = "/fofo/brands", method = RequestMethod.GET, produces = MediaType.APPLICATION_JSON_VALUE)
|
| 407 |
@Cacheable(value = "display", cacheManager = "thirtyMinsTimeOutCacheManager")
|
407 |
@Cacheable(value = "display", cacheManager = "thirtyMinsTimeOutCacheManager")
|
| 408 |
public ResponseEntity<?> getBrandsToDisplay(HttpServletRequest request,
|
408 |
public ResponseEntity<?> getBrandsToDisplay(HttpServletRequest request,
|
| 409 |
@RequestParam(required = false, defaultValue = "0") int categoryId) throws Exception {
|
409 |
@RequestParam(required = false, defaultValue = "0") int categoryId) throws Exception {
|
| 410 |
UserInfo userInfo = (UserInfo) request.getAttribute("userInfo");
|
410 |
UserInfo userInfo = (UserInfo) request.getAttribute("userInfo");
|
| - |
|
411 |
logger.info("userInfo [{}]", userInfo);
|
| 411 |
List<DBObject> brandsDisplay = null;
|
412 |
List<DBObject> brandsDisplay = null;
|
| 412 |
if (categoryId == 3) {
|
413 |
if (categoryId == 3) {
|
| 413 |
brandsDisplay = mongoClient.getMongoBrands(userInfo.getRetailerId(), userInfo.getEmail(), categoryId);
|
414 |
brandsDisplay = mongoClient.getMongoBrands(userInfo.getRetailerId(), userInfo.getEmail(), categoryId);
|
| 414 |
} else {
|
415 |
} else {
|
| 415 |
brandsDisplay = this.getSubCategoriesToDisplay();
|
416 |
brandsDisplay = this.getSubCategoriesToDisplay();
|