Subversion Repositories SmartDukaan

Rev

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

Rev 23026 Rev 23047
Line 35... Line 35...
35
		Map<String, Object> map = retailerService.getByEmailIdOrMobileNumber(emailIdOrMobileNumber);
35
		Map<String, Object> map = retailerService.getByEmailIdOrMobileNumber(emailIdOrMobileNumber);
36
		model.addAllAttributes(map);
36
		model.addAllAttributes(map);
37
		return "retailer-details";
37
		return "retailer-details";
38
	}
38
	}
39
	
39
	
40
	@RequestMapping(value = "/updateRetailerDocument", method = RequestMethod.PUT)
-
 
41
	public String updateRetailerDocument(HttpServletRequest request, @RequestParam(name = ProfitMandiConstants.EMAIL_ID_OR_MOBILE_NUMBER) String emailIdOrMobileNumber, @RequestParam(name = ProfitMandiConstants.DOCUMENT_ID) int documentId, Model model)  throws ProfitMandiBusinessException{
-
 
42
		LOGGER.info("Request Received at url {} with documentId {}", request.getRequestURI(), documentId);
-
 
43
		Map<String, Object> map = retailerService.updateRetailerDocument(emailIdOrMobileNumber, documentId);
-
 
44
		model.addAllAttributes(map);
-
 
45
		return "retailer-details";
-
 
46
	}
-
 
47
	
-
 
48
	@RequestMapping(value = "/retailerDetails", method = RequestMethod.PUT)
40
	@RequestMapping(value = "/retailerDetails", method = RequestMethod.PUT)
49
	public String updateRetailerDetails(HttpServletRequest request, @RequestBody UpdateRetailerRequest updateRetailerRequest, Model model)  throws ProfitMandiBusinessException{
41
	public String updateRetailerDetails(HttpServletRequest request, @RequestBody UpdateRetailerRequest updateRetailerRequest, Model model)  throws ProfitMandiBusinessException{
50
		LOGGER.info("Request Received at url {} with body {}", request.getRequestURI(), updateRetailerRequest);
42
		LOGGER.info("Request Received at url {} with body {}", request.getRequestURI(), updateRetailerRequest);
51
		Map<String, Object> map = retailerService.updateRetailerDetails(updateRetailerRequest);
43
		Map<String, Object> map = retailerService.updateRetailerDetails(updateRetailerRequest);
52
		model.addAllAttributes(map);
44
		model.addAllAttributes(map);
53
		return "retailer-details";
45
		return "retailer-details";
54
	}
46
	}
55
	
47
	
56
	@RequestMapping(value = "/updateRetailerShopDocument", method = RequestMethod.PUT)
-
 
57
	public String updateRetailerShopDocument(HttpServletRequest request, @RequestParam(name = ProfitMandiConstants.EMAIL_ID_OR_MOBILE_NUMBER) String emailIdOrMobileNumber, @RequestParam(name = ProfitMandiConstants.SHOP_ID) int shopId, @RequestParam(name = ProfitMandiConstants.DOCUMENT_ID) int documentId, Model model)  throws ProfitMandiBusinessException{
-
 
58
		LOGGER.info("Request Received at url {} with documentId {}", request.getRequestURI(), documentId);
-
 
59
		Map<String, Object> map = retailerService.updateRetailerShopDocument(emailIdOrMobileNumber, shopId, documentId);
-
 
60
		model.addAllAttributes(map);
-
 
61
		return "retailer-details";
-
 
62
	}
-
 
63
	
-
 
64
 
48
 
65
	@RequestMapping(value = "/retailerInfo", method = RequestMethod.GET)
49
	@RequestMapping(value = "/retailerInfo", method = RequestMethod.GET)
66
	public String retailerInfo(HttpServletRequest request)  throws Exception{
50
	public String retailerInfo(HttpServletRequest request)  throws Exception{
67
		return "retailer-info";
51
		return "retailer-info";
68
	}
52
	}