Authored by tanling

fix

... ... @@ -40,7 +40,7 @@ public class SendUserMessageImpl extends AbstractSendMessage implements ISendUse
MessageCenterCommonEvent messageCenterCommonEvent = genMessageCenterCommonEvent(SendScenes.MEMBERSHIP_UPGRADE, null, uid);
messageCenterCommonEvent.putInParams("startTime", DateUtils.long2DateStr(Long.parseLong(String.valueOf(startTime)), "yyyy-MM-dd HH:mm"));
messageCenterCommonEvent.putInParams("assisId", assistId);
messageCenterCommonEvent.putInParams("assistId", assistId);
messageCenterMqHandler.sendMessageToMq(messageCenterCommonEvent);
return new SendMessageRspBo(200, "SUCCESS");
}
... ... @@ -48,7 +48,7 @@ public class SendUserMessageImpl extends AbstractSendMessage implements ISendUse
@Override
public SendMessageRspBo assistUidProcess(String uid, String assistId) {
MessageCenterCommonEvent messageCenterCommonEvent = genMessageCenterCommonEvent(SendScenes.MEMBERSHIP_UPGRADE, null, uid);
messageCenterCommonEvent.putInParams("assisId", assistId);
messageCenterCommonEvent.putInParams("assistId", assistId);
messageCenterMqHandler.sendMessageToMq(messageCenterCommonEvent);
return new SendMessageRspBo(200, "SUCCESS");
}
... ... @@ -56,7 +56,7 @@ public class SendUserMessageImpl extends AbstractSendMessage implements ISendUse
@Override
public SendMessageRspBo assistExpireProcess(String uid, String assistId) {
MessageCenterCommonEvent messageCenterCommonEvent = genMessageCenterCommonEvent(SendScenes.MEMBERSHIP_UPGRADE, null, uid);
messageCenterCommonEvent.putInParams("assisId", assistId);
messageCenterCommonEvent.putInParams("assistId", assistId);
messageCenterMqHandler.sendMessageToMq(messageCenterCommonEvent);
return new SendMessageRspBo(200, "SUCCESS");
}
... ...
package com.yoho.message.sdk.test;
import com.yoho.message.sdk.service.promotion.ISendPromotionMessage;
import com.yoho.message.sdk.service.user.ISendUserMessage;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
/**
* Created by yoho on 2017/6/27.
*/
@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration(locations = { "classpath*:META-INF/spring/test-message-sdk-*.xml" })
public class TestUserMessage {
@Autowired
private ISendUserMessage sendPromotionMessage;
@Test
public void assistStart() {
sendPromotionMessage.assistStart("54096844", "2", 1517905629);
}
@Test
public void assistUidProcess() {
sendPromotionMessage.assistUidProcess("54096844", "2");
}
@Test
public void assistExpireProcess() {
sendPromotionMessage.assistExpireProcess("54096844", "2");
}
}
... ...