Authored by Wang

增加被推荐人的uid

@@ -7,7 +7,7 @@ import com.yoho.message.sdk.common.model.SendMessageRspBo; @@ -7,7 +7,7 @@ import com.yoho.message.sdk.common.model.SendMessageRspBo;
7 */ 7 */
8 public interface ISendPromotionMessage { 8 public interface ISendPromotionMessage {
9 9
10 - SendMessageRspBo inviteCouponWait(String uid, String orderCode, String reward); 10 + SendMessageRspBo inviteCouponWait(String uid, String orderCode, String reward, String firstOrderUid);
11 11
12 - SendMessageRspBo inviteCouponSend(String uid, String orderCode, String reward); 12 + SendMessageRspBo inviteCouponSend(String uid, String orderCode, String reward, String firstOrderUid);
13 } 13 }
@@ -19,18 +19,20 @@ public class SendPromotionMessageImpl extends AbstractSendMessage implements ISe @@ -19,18 +19,20 @@ public class SendPromotionMessageImpl extends AbstractSendMessage implements ISe
19 private MessageCenterMqHandler messageCenterMqHandler; 19 private MessageCenterMqHandler messageCenterMqHandler;
20 20
21 @Override 21 @Override
22 - public SendMessageRspBo inviteCouponWait(String uid, String orderCode, String reward) { 22 + public SendMessageRspBo inviteCouponWait(String uid, String orderCode, String reward, String firstOrderUid) {
23 MessageCenterCommonEvent messageCenterCommonEvent = genMessageCenterCommonEvent(PromotionScenes.INVITE_COUPON_WAIT, orderCode, uid); 23 MessageCenterCommonEvent messageCenterCommonEvent = genMessageCenterCommonEvent(PromotionScenes.INVITE_COUPON_WAIT, orderCode, uid);
24 messageCenterCommonEvent.putInParams("amount", reward); 24 messageCenterCommonEvent.putInParams("amount", reward);
  25 + messageCenterCommonEvent.putInParams("firstOrderUid", firstOrderUid);
25 26
26 messageCenterMqHandler.sendMessageToMq(messageCenterCommonEvent); 27 messageCenterMqHandler.sendMessageToMq(messageCenterCommonEvent);
27 return new SendMessageRspBo(200, "SUCCESS"); 28 return new SendMessageRspBo(200, "SUCCESS");
28 } 29 }
29 30
30 @Override 31 @Override
31 - public SendMessageRspBo inviteCouponSend(String uid, String orderCode, String reward) { 32 + public SendMessageRspBo inviteCouponSend(String uid, String orderCode, String reward, String firstOrderUid) {
32 MessageCenterCommonEvent messageCenterCommonEvent = genMessageCenterCommonEvent(PromotionScenes.INVITE_COUPON_SEND, orderCode, uid); 33 MessageCenterCommonEvent messageCenterCommonEvent = genMessageCenterCommonEvent(PromotionScenes.INVITE_COUPON_SEND, orderCode, uid);
33 messageCenterCommonEvent.putInParams("amount", reward); 34 messageCenterCommonEvent.putInParams("amount", reward);
  35 + messageCenterCommonEvent.putInParams("firstOrderUid", firstOrderUid);
34 36
35 messageCenterMqHandler.sendMessageToMq(messageCenterCommonEvent); 37 messageCenterMqHandler.sendMessageToMq(messageCenterCommonEvent);
36 return new SendMessageRspBo(200, "SUCCESS"); 38 return new SendMessageRspBo(200, "SUCCESS");
@@ -19,11 +19,11 @@ public class TestPromotionMessage { @@ -19,11 +19,11 @@ public class TestPromotionMessage {
19 19
20 @Test 20 @Test
21 public void testInviteCouponWait() { 21 public void testInviteCouponWait() {
22 - sendPromotionMessage.inviteCouponWait("8041612", "1234567", "50元优惠券"); 22 + sendPromotionMessage.inviteCouponWait("50002614", "170183676", "50元优惠券", "1234567");
23 } 23 }
24 24
25 @Test 25 @Test
26 public void testInviteCouponSend() { 26 public void testInviteCouponSend() {
27 - sendPromotionMessage.inviteCouponSend("8041612", "1234567", "50元优惠券"); 27 + sendPromotionMessage.inviteCouponSend("50002614", "1234567", "50元优惠券", "1234567");
28 } 28 }
29 } 29 }