|
|
@@ -10,7 +10,6 @@ import com.uas.platform.b2c.common.psmessage.dao.OrderCompleteInfoDao;
|
|
|
import com.uas.platform.b2c.common.psmessage.model.OrderCompleteInfo;
|
|
|
import com.uas.platform.b2c.common.psmessage.service.MessageService;
|
|
|
import com.uas.platform.b2c.core.config.SysConf;
|
|
|
-import com.uas.platform.b2c.core.constant.SplitChar;
|
|
|
import com.uas.platform.b2c.trade.order.StringConstant.StringFormat;
|
|
|
import com.uas.platform.b2c.trade.order.model.MessageNotifyPersonalManagement;
|
|
|
import com.uas.platform.b2c.trade.order.service.MessageNotifyPersonalManagementService;
|
|
|
@@ -63,24 +62,16 @@ public class MessageTask {
|
|
|
adminUu = enterpriseInfo.getEnAdminuu();
|
|
|
}
|
|
|
if (CollectionUtils.isNotEmpty(managements)) {
|
|
|
- MessageNotifyPersonalManagement messageNotifyPersonalManagement = managements.get(0);
|
|
|
if (CollectionUtils.isNotEmpty(completeInfos)) {
|
|
|
for (OrderCompleteInfo completeInfo : completeInfos) {
|
|
|
String orderId = completeInfo.getOrderId();
|
|
|
if (!StringUtils.isEmpty(orderId)) {
|
|
|
- String notifyPersonalUseruu = messageNotifyPersonalManagement.getNotifyPersonalUseruu();
|
|
|
- if (!StringUtils.isEmpty(notifyPersonalUseruu)) {
|
|
|
- String[] userUus = notifyPersonalUseruu.split(SplitChar.HYPHEN);
|
|
|
- for (String userUu : userUus) {
|
|
|
- try {
|
|
|
- Long useruu = Long.valueOf(userUu);
|
|
|
- MessageModel model = messageService.initMessage(String.format(StringFormat.APPLYPAID, orderId), MessageType.APPLY_PAID.getType(), useruu, sysConf.getEnUU(), ConsumerType.SINGLE, ConsumerApp.MALL, SMSType.DONT_SEND, completeInfo.getRemark(), adminUu, sysConf.getEnUU());
|
|
|
- sendMessageList.add(model);
|
|
|
- } catch (NumberFormatException e) {
|
|
|
- e.printStackTrace();
|
|
|
- }
|
|
|
- }
|
|
|
+ for (MessageNotifyPersonalManagement management : managements) {
|
|
|
+ Long notifyPersonalUseruu = management.getNotifyPersonalUseruu();
|
|
|
+ MessageModel model = messageService.initMessage(String.format(StringFormat.APPLYPAID, orderId), MessageType.APPLY_PAID.getType(), notifyPersonalUseruu, sysConf.getEnUU(), ConsumerType.SINGLE, ConsumerApp.MALL, SMSType.DONT_SEND, completeInfo.getRemark(), adminUu, sysConf.getEnUU());
|
|
|
+ sendMessageList.add(model);
|
|
|
}
|
|
|
+
|
|
|
}
|
|
|
}
|
|
|
}
|