Subversion Repositories SmartDukaan

Rev

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

Rev 11991 Rev 12007
Line 56... Line 56...
56
                    return "redirect";
56
                    return "redirect";
57
                } else if (couponCode.equals("saholicdeals")) {
57
                } else if (couponCode.equals("saholicdeals")) {
58
                	Cookie co = cookiesMap.get(UserInterceptor.DEAL_COUPON_REMOVED);
58
                	Cookie co = cookiesMap.get(UserInterceptor.DEAL_COUPON_REMOVED);
59
                	if (co != null) {
59
                	if (co != null) {
60
                		co.setMaxAge(0);
60
                		co.setMaxAge(0);
61
                		response.addCookie(co);
61
                		co.setDomain("/");
-
 
62
                		co.setDomain(domainName);
62
                	}
63
                	}
63
                }
64
                }
64
                promotionServiceClient = new PromotionClient();
65
                promotionServiceClient = new PromotionClient();
65
                PromotionService.Client promotionClient = promotionServiceClient.getClient();
66
                PromotionService.Client promotionClient = promotionServiceClient.getClient();
66
                String str = "Coupon applied";
67
                String str = "Coupon applied";
Line 75... Line 76...
75
            	if(userinfo.isPrivateDealUser()) {
76
            	if(userinfo.isPrivateDealUser()) {
76
            		if (cookiesMap.get(UserInterceptor.DEAL_COUPON_REMOVED)==null) {
77
            		if (cookiesMap.get(UserInterceptor.DEAL_COUPON_REMOVED)==null) {
77
        				Cookie co = new Cookie(UserInterceptor.DEAL_COUPON_REMOVED, "true");
78
        				Cookie co = new Cookie(UserInterceptor.DEAL_COUPON_REMOVED, "true");
78
        				co.setDomain(this.domainName);
79
        				co.setDomain(this.domainName);
79
        				co.setPath("/");
80
        				co.setPath("/");
80
        				response.addCookie(co);
-
 
81
        				log.info("added to cookies map");
81
        				cookiesMap.put(UserInterceptor.DEAL_COUPON_REMOVED, co);
82
            		}
82
            		}
83
            	}
83
            	}
84
                userServiceClient = new UserClient();
84
                userServiceClient = new UserClient();
85
                UserContextService.Client userClient = userServiceClient.getClient();
85
                UserContextService.Client userClient = userServiceClient.getClient();
86
                userClient.removeCoupon(cartId);
86
                userClient.removeCoupon(cartId);