Subversion Repositories SmartDukaan

Rev

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

Rev 6302 Rev 6309
Line 11... Line 11...
11
import in.shop2020.utils.DataLogger;
11
import in.shop2020.utils.DataLogger;
12
 
12
 
13
import java.util.Collection;
13
import java.util.Collection;
14
import java.util.ResourceBundle;
14
import java.util.ResourceBundle;
15
 
15
 
-
 
16
import org.apache.commons.lang.StringUtils;
16
import org.apache.log4j.Logger;
17
import org.apache.log4j.Logger;
17
import org.apache.struts2.convention.annotation.InterceptorRef;
18
import org.apache.struts2.convention.annotation.InterceptorRef;
18
import org.apache.struts2.convention.annotation.InterceptorRefs;
19
import org.apache.struts2.convention.annotation.InterceptorRefs;
19
import org.apache.struts2.convention.annotation.Result;
20
import org.apache.struts2.convention.annotation.Result;
20
import org.apache.struts2.convention.annotation.Results;
21
import org.apache.struts2.convention.annotation.Results;
Line 96... Line 97...
96
            Cart cart = userClient.getCart(cartId);
97
            Cart cart = userClient.getCart(cartId);
97
            String couponCode = cart.getCouponCode();
98
            String couponCode = cart.getCouponCode();
98
            logger.info("Coupon: " + couponCode);
99
            logger.info("Coupon: " + couponCode);
99
            
100
            
100
            PromotionService.Client pc = new PromotionClient().getClient();
101
            PromotionService.Client pc = new PromotionClient().getClient();
101
            if(pc.isGiftVoucher(couponCode)){
102
            if(StringUtils.isNotEmpty(couponCode) && pc.isGiftVoucher(couponCode)){
102
            	hasGiftVoucher = true;
103
            	hasGiftVoucher = true;
103
            }
104
            }
104
            
105
            
105
            if (!hasGiftVoucher && deliveryLocation.equals("HotSpot")) {
106
            if (!hasGiftVoucher && deliveryLocation.equals("HotSpot")) {
106
            	userClient.addStoreToCart(cartId, hotSpotAddressId);
107
            	userClient.addStoreToCart(cartId, hotSpotAddressId);