...
|
...
|
@@ -5,6 +5,8 @@ import java.util.List; |
|
|
|
|
|
import javax.annotation.Resource;
|
|
|
|
|
|
import com.yoho.core.rest.client.ServiceCaller;
|
|
|
import com.yoho.service.model.promotion.CouponForm;
|
|
|
import org.apache.commons.collections.CollectionUtils;
|
|
|
import org.slf4j.Logger;
|
|
|
import org.slf4j.LoggerFactory;
|
...
|
...
|
@@ -37,6 +39,9 @@ public class OrderShareActivityServiceImpl implements IOrderShareActivityService |
|
|
@Resource
|
|
|
private IUserCouponHistoryDAO userCouponHistoryDAO;
|
|
|
|
|
|
@Resource
|
|
|
ServiceCaller serviceCaller;
|
|
|
|
|
|
@Value("${orderShare.maxNum}")
|
|
|
private String maxshare;// MAX_SHARE_NUM;
|
|
|
|
...
|
...
|
@@ -169,4 +174,18 @@ public class OrderShareActivityServiceImpl implements IOrderShareActivityService |
|
|
log.info("end with updateShareHistory.");
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 发送优惠券
|
|
|
* @param couponId
|
|
|
* @param uid
|
|
|
*/
|
|
|
private void sendCoupon(String couponId, String uid){
|
|
|
log.info("start with sendCoupon. couponId is {}, uid is {}",couponId , uid);
|
|
|
CouponForm form = new CouponForm();
|
|
|
form.setCouponId(couponId);
|
|
|
form.setUid(uid);
|
|
|
String couponCode = serviceCaller.call("promotion.sendCoupon",form,String.class);
|
|
|
log.info("end with sendCoupon. couponCode is {}", couponCode);
|
|
|
}
|
|
|
|
|
|
} |
...
|
...
|
|