...
|
...
|
@@ -241,7 +241,7 @@ public class InBoxFacade { |
|
|
String sizeName = psog.getSizeName();
|
|
|
Integer sellerUid = psog.getUid();
|
|
|
InboxBusinessTypeEnum ibtOfSeller = InboxBusinessTypeEnum.NOTICE_SELLER_WHEN_APPRAISE_PASS;
|
|
|
String paramsOfSeller = buildParams(prdName, sizeName);
|
|
|
String paramsOfSeller = buildParams(prdName, sizeName,productCode);
|
|
|
InboxReqVO reqOfSeller = buildInboxReqVO(sellerUid, paramsOfSeller, ibtOfSeller);
|
|
|
|
|
|
InBoxResponse respOfSeller = inBoxSDK.addInbox(reqOfSeller);
|
...
|
...
|
@@ -546,11 +546,16 @@ public class InBoxFacade { |
|
|
* @param sellerUid
|
|
|
* @param prdName
|
|
|
*/
|
|
|
public void sellerPaidEarnestMoney(int sellerUid, String prdName) {
|
|
|
public void sellerPaidEarnestMoney(int sellerUid, String prdName,String sizeName,Integer productId) {
|
|
|
try {
|
|
|
executorService.execute(() -> {
|
|
|
logger.info("record sellerPaidEarnestMoney inbox in , sellerUid {}, prdName {}, sizeName {} ,productId {}",
|
|
|
sellerUid, prdName, sizeName,productId);
|
|
|
Product product = productMapper.selectByPrimaryKey(productId);
|
|
|
String productCode = product.getProductCode();
|
|
|
|
|
|
InboxBusinessTypeEnum ibt = InboxBusinessTypeEnum.SALE_SHELF;
|
|
|
String params = buildParams(prdName);
|
|
|
String params = buildParams(prdName,sizeName,productCode);
|
|
|
InboxReqVO req = buildInboxReqVO(sellerUid, params, ibt);
|
|
|
|
|
|
InBoxResponse resp = inBoxSDK.addInbox(req);
|
...
|
...
|
@@ -558,8 +563,8 @@ public class InBoxFacade { |
|
|
sellerUid, prdName, resp);
|
|
|
});
|
|
|
} catch (Exception e) {
|
|
|
logger.warn("InBoxFacade sellerPaidEarnestMoney error inbox msg, sellerUid {}, prdName {} ",
|
|
|
sellerUid, prdName, e);
|
|
|
logger.warn("InBoxFacade sellerPaidEarnestMoney error inbox msg, sellerUid {}, prdName {} ,productId {} ",
|
|
|
sellerUid, prdName,productId, e);
|
|
|
}
|
|
|
}
|
|
|
|
...
|
...
|
@@ -567,13 +572,17 @@ public class InBoxFacade { |
|
|
* 下架成功
|
|
|
*
|
|
|
* @param sellerUid
|
|
|
* @param prdName
|
|
|
*/
|
|
|
public void sellerPlaySelf(int sellerUid, String prdName) {
|
|
|
public void sellerPlaySelf(int sellerUid,SellerOrderGoods sellerOrderGoods) {
|
|
|
try {
|
|
|
executorService.execute(() -> {
|
|
|
String prdName = sellerOrderGoods.getProductName();
|
|
|
String sizeName = sellerOrderGoods.getSizeName();
|
|
|
Product product = productMapper.selectByPrimaryKey(sellerOrderGoods.getProductId());
|
|
|
String productCode = product.getProductCode();
|
|
|
|
|
|
InboxBusinessTypeEnum ibt = InboxBusinessTypeEnum.SALE_UNSHELF;
|
|
|
String params = buildParams(prdName);
|
|
|
String params = buildParams(prdName,sizeName,productCode);
|
|
|
InboxReqVO req = buildInboxReqVO(sellerUid, params, ibt);
|
|
|
|
|
|
InBoxResponse resp = inBoxSDK.addInbox(req);
|
...
|
...
|
@@ -583,7 +592,7 @@ public class InBoxFacade { |
|
|
|
|
|
} catch (Exception e) {
|
|
|
logger.warn("InBoxFacade sellerPlaySelf error inbox msg, sellerUid {}, prdName {} ",
|
|
|
sellerUid, prdName, e);
|
|
|
sellerUid, sellerOrderGoods, e);
|
|
|
}
|
|
|
|
|
|
}
|
...
|
...
|
@@ -593,13 +602,17 @@ public class InBoxFacade { |
|
|
* 卖家商品售出提醒,买家下单后
|
|
|
*
|
|
|
* @param sellerUid
|
|
|
* @param prdName
|
|
|
*/
|
|
|
public void sellerSkupCreateOrderByBuyer(int sellerUid, String prdName) {
|
|
|
public void sellerSkupCreateOrderByBuyer(int sellerUid, SellerOrderGoods psog) {
|
|
|
try {
|
|
|
executorService.execute(() -> {
|
|
|
String prdName = psog.getProductName();
|
|
|
String sizeName = psog.getSizeName();
|
|
|
Product product = productMapper.selectByPrimaryKey(psog.getProductId());
|
|
|
String productCode = product.getProductCode();
|
|
|
|
|
|
InboxBusinessTypeEnum ibt = InboxBusinessTypeEnum.SALE_SELLED;
|
|
|
String params = buildParams(prdName);
|
|
|
String params = buildParams(prdName,sizeName,productCode);
|
|
|
InboxReqVO req = buildInboxReqVO(sellerUid, params, ibt);
|
|
|
|
|
|
InBoxResponse resp = inBoxSDK.addInbox(req);
|
...
|
...
|
@@ -609,7 +622,7 @@ public class InBoxFacade { |
|
|
|
|
|
} catch (Exception e) {
|
|
|
logger.warn("InBoxFacade sellerSkupCreateOrderByBuyer error inbox msg, sellerUid {}, prdName {} ",
|
|
|
sellerUid, prdName, e);
|
|
|
sellerUid, psog, e);
|
|
|
}
|
|
|
}
|
|
|
|
...
|
...
|
@@ -622,11 +635,13 @@ public class InBoxFacade { |
|
|
String sizeName = sog.getSizeName();
|
|
|
try {
|
|
|
executorService.execute(() -> {
|
|
|
Product product = productMapper.selectByPrimaryKey(sog.getProductId());
|
|
|
String productCode = product.getProductCode();
|
|
|
InboxBusinessTypeEnum ibt = InboxBusinessTypeEnum.NOTICE_SELLER_WHEN_MINI_FAULT_UN_ACCEPT;
|
|
|
if(outTimeFlag){
|
|
|
ibt = InboxBusinessTypeEnum.NOTICE_SELLER_WHEN_MINI_FAULT_UN_ACCEPT_OUT_TIME;
|
|
|
}
|
|
|
String params = buildParams(prdName, sizeName);
|
|
|
String params = buildParams(prdName, sizeName,productCode);
|
|
|
InboxReqVO req = buildInboxReqVO(sellerUid, params, ibt);
|
|
|
|
|
|
InBoxResponse resp = inBoxSDK.addInbox(req);
|
...
|
...
|
@@ -644,7 +659,7 @@ public class InBoxFacade { |
|
|
if(outTimeFlag){
|
|
|
sms = InboxBusinessTypeEnum.SMS_NOTICE_SELLER_WHEN_MINI_FAULT_UN_ACCEPT_OUT_TIME;
|
|
|
}
|
|
|
String content = getReplacedContent(sms.getContent(),prdName,orderCode);
|
|
|
String content = getReplacedContent(sms.getContent(),prdName,sizeName,productCode,orderCode);
|
|
|
sendSmsService.smsSendByMobile(content, mobileList);
|
|
|
logger.info("record sellerMiniFaultUnAccept inbox sms msg,sellerUid {}, prdName {},orderCode {}",
|
|
|
sellerUid, prdName,orderCode);
|
...
|
...
|
@@ -665,8 +680,10 @@ public class InBoxFacade { |
|
|
String sizeName = sog.getSizeName();
|
|
|
try {
|
|
|
executorService.execute(() -> {
|
|
|
Product product = productMapper.selectByPrimaryKey(sog.getProductId());
|
|
|
String productCode = product.getProductCode();
|
|
|
InboxBusinessTypeEnum ibt = InboxBusinessTypeEnum.NOTICE_SELLER_WHEN_QUALITY_CHECK_REJECT;
|
|
|
String params = buildParams(prdName, sizeName);
|
|
|
String params = buildParams(prdName, sizeName,productCode);
|
|
|
InboxReqVO req = buildInboxReqVO(sellerUid, params, ibt);
|
|
|
|
|
|
InBoxResponse resp = inBoxSDK.addInbox(req);
|
...
|
...
|
@@ -680,7 +697,7 @@ public class InBoxFacade { |
|
|
return;
|
|
|
}
|
|
|
List<String> mobileList = Arrays.asList(phone);
|
|
|
String content = getReplacedContent(InboxBusinessTypeEnum.SMS_NOTICE_SELLER_WHEN_QUALITY_CHECK_REJECT.getContent(),prdName,orderCode);
|
|
|
String content = getReplacedContent(InboxBusinessTypeEnum.SMS_NOTICE_SELLER_WHEN_QUALITY_CHECK_REJECT.getContent(),prdName,sizeName,productCode,orderCode);
|
|
|
sendSmsService.smsSendByMobile(content, mobileList);
|
|
|
logger.info("record sellerQualityCheckNotPass inbox sms msg,sellerUid {}, prdName {},orderCode {}",
|
|
|
sellerUid, prdName,orderCode);
|
...
|
...
|
@@ -700,8 +717,10 @@ public class InBoxFacade { |
|
|
String sizeName = sog.getSizeName();
|
|
|
try {
|
|
|
executorService.execute(() -> {
|
|
|
Product product = productMapper.selectByPrimaryKey(sog.getProductId());
|
|
|
String productCode = product.getProductCode();
|
|
|
InboxBusinessTypeEnum ibt = InboxBusinessTypeEnum.NOTICE_SELLER_WHEN_EXPRESS_QUALITY_CHECK_REJECT;
|
|
|
String params = buildParams(prdName, sizeName);
|
|
|
String params = buildParams(prdName, sizeName,productCode);
|
|
|
InboxReqVO req = buildInboxReqVO(sellerUid, params, ibt);
|
|
|
|
|
|
InBoxResponse resp = inBoxSDK.addInbox(req);
|
...
|
...
|
@@ -721,7 +740,7 @@ public class InBoxFacade { |
|
|
}else if(type==3){
|
|
|
sms = InboxBusinessTypeEnum.SMS_NOTICE_SELLER_WHEN_EXPRESS_MINI_FAULT_UN_ACCEPT_OUT_TIME;
|
|
|
}
|
|
|
String content = getReplacedContent(sms.getContent(),prdName,orderCode,wayBillCode);
|
|
|
String content = getReplacedContent(sms.getContent(),prdName,sizeName,productCode,orderCode,wayBillCode);
|
|
|
sendSmsService.smsSendByMobile(content, mobileList);
|
|
|
logger.info("record sellerQualityCheckNotPass_send_back inbox sms msg,sellerUid {}, prdName {},type {},orderCode {}",
|
|
|
sellerUid, prdName,type,orderCode);
|
...
|
...
|
@@ -745,9 +764,11 @@ public class InBoxFacade { |
|
|
String sizeName = sog.getSizeName();
|
|
|
try {
|
|
|
executorService.execute(() -> {
|
|
|
Product product = productMapper.selectByPrimaryKey(sog.getProductId());
|
|
|
String productCode = product.getProductCode();
|
|
|
InboxBusinessTypeEnum ibt = InboxBusinessTypeEnum.SALE_SEND;
|
|
|
String timelimitDesc = new StringBuilder().append(deliveryTimeLimit).append(unit).toString();
|
|
|
String params = buildParams(prdName, sizeName, timelimitDesc);
|
|
|
String params = buildParams(prdName, sizeName,productCode, timelimitDesc);
|
|
|
InboxReqVO req = buildInboxReqVO(sellerUid, params, ibt);
|
|
|
|
|
|
InBoxResponse resp = inBoxSDK.addInbox(req);
|
...
|
...
|
@@ -762,7 +783,7 @@ public class InBoxFacade { |
|
|
return;
|
|
|
}
|
|
|
List<String> mobileList = Arrays.asList(phone);
|
|
|
String content = getReplacedContent(InboxBusinessTypeEnum.SMS_NOTIFIED_SEND.getContent(),prdName,orderCode,timelimitDesc);
|
|
|
String content = getReplacedContent(InboxBusinessTypeEnum.SMS_NOTIFIED_SEND.getContent(),prdName,orderCode,productCode,timelimitDesc);
|
|
|
sendSmsService.smsSendByMobile(content, mobileList);
|
|
|
logger.info("record sellerSkupPaidByBuyer inbox sms msg,sellerUid {}, prdName {},orderCode {} timelimitDesc {}",
|
|
|
sellerUid, prdName,orderCode, timelimitDesc);
|
...
|
...
|
@@ -785,9 +806,11 @@ public class InBoxFacade { |
|
|
String sizeName = sog.getSizeName();
|
|
|
try {
|
|
|
|
|
|
Product product = productMapper.selectByPrimaryKey(sog.getProductId());
|
|
|
String productCode = product.getProductCode();
|
|
|
executorService.execute(() -> {
|
|
|
InboxBusinessTypeEnum ibt = InboxBusinessTypeEnum.SALE_CLOSED_SELLER;
|
|
|
String params = buildParams(prdName, sizeName);
|
|
|
String params = buildParams(prdName, sizeName,productCode);
|
|
|
InboxReqVO req = buildInboxReqVO(sellerUid, params, ibt);
|
|
|
|
|
|
InBoxResponse resp = inBoxSDK.addInbox(req);
|
...
|
...
|
@@ -851,8 +874,10 @@ public class InBoxFacade { |
|
|
String sizeName = sog.getSizeName();
|
|
|
try {
|
|
|
executorService.execute(() -> {
|
|
|
Product product = productMapper.selectByPrimaryKey(sog.getProductId());
|
|
|
String productCode = product.getProductCode();
|
|
|
InboxBusinessTypeEnum ibt = InboxBusinessTypeEnum.SALE_CLOSED_PLATFORM;
|
|
|
String params = buildParams(prdName, sizeName);
|
|
|
String params = buildParams(prdName, sizeName,productCode);
|
|
|
InboxReqVO req = buildInboxReqVO(sellerUid, params, ibt);
|
|
|
|
|
|
InBoxResponse resp = inBoxSDK.addInbox(req);
|
...
|
...
|
@@ -867,7 +892,7 @@ public class InBoxFacade { |
|
|
return;
|
|
|
}
|
|
|
List<String> mobileList = Arrays.asList(phone);
|
|
|
String content = getReplacedContent(InboxBusinessTypeEnum.SMS_NOTICE_SELLER_WHEN_CLOSED_PLATFORM.getContent(),prdName,orderCode,wayBillCode);
|
|
|
String content = getReplacedContent(InboxBusinessTypeEnum.SMS_NOTICE_SELLER_WHEN_CLOSED_PLATFORM.getContent(),prdName,sizeName,productCode,orderCode,wayBillCode);
|
|
|
sendSmsService.smsSendByMobile(content, mobileList);
|
|
|
logger.info("record noticeSellerWhenAppraiseFail sms send,sellerUid {}, prdName {},orderCode {},wayBillCode {} ",
|
|
|
sellerUid, prdName,orderCode,wayBillCode);
|
...
|
...
|
@@ -885,13 +910,16 @@ public class InBoxFacade { |
|
|
* 商品下架提醒,
|
|
|
*
|
|
|
* @param sellerUid
|
|
|
* @param prdName
|
|
|
*/
|
|
|
public void notifyUnshelfCauseBySpecialReason(int sellerUid, String prdName) {
|
|
|
public void notifyUnshelfCauseBySpecialReason(int sellerUid,SellerOrderGoods psog ) {
|
|
|
try {
|
|
|
executorService.execute(() -> {
|
|
|
String prdName = psog.getProductName();
|
|
|
String sizeName = psog.getSizeName();
|
|
|
Product product = productMapper.selectByPrimaryKey(psog.getProductId());
|
|
|
String productCode = product.getProductCode();
|
|
|
InboxBusinessTypeEnum ibt = InboxBusinessTypeEnum.SALE_NOTIFIED_UNSHELF;
|
|
|
String params = buildParams(prdName);
|
|
|
String params = buildParams(prdName,sizeName,productCode);
|
|
|
InboxReqVO req = buildInboxReqVO(sellerUid, params, ibt);
|
|
|
|
|
|
InBoxResponse resp = inBoxSDK.addInbox(req);
|
...
|
...
|
@@ -905,17 +933,15 @@ public class InBoxFacade { |
|
|
return;
|
|
|
}
|
|
|
List<String> mobileList = Arrays.asList(phone);
|
|
|
//SmsContentEnum smsIbt = SmsContentEnum.SMS_NOTIFIED_UNSHELF;
|
|
|
//String content = smsIbt.getReplacedContent(prdName);
|
|
|
String content = getReplacedContent(InboxBusinessTypeEnum.SMS_NOTIFIED_UNSHELF.getContent(),prdName);
|
|
|
String content = getReplacedContent(InboxBusinessTypeEnum.SMS_NOTIFIED_UNSHELF.getContent(),prdName,sizeName,productCode);
|
|
|
sendSmsService.smsSendByMobile(content, mobileList);
|
|
|
logger.info("record notifyUnshelfCauseBySpecialReason inbox sms msg,sellerUid {}, prdName {}, resp {}",
|
|
|
sellerUid, prdName);
|
|
|
});
|
|
|
|
|
|
} catch (Exception e) {
|
|
|
logger.warn("InBoxFacade notifyUnshelfCauseBySpecialReason error inbox msg, sellerUid {}, prdName {} ",
|
|
|
sellerUid, prdName, e);
|
|
|
logger.warn("InBoxFacade notifyUnshelfCauseBySpecialReason error inbox msg, sellerUid {}, psog {} ",
|
|
|
sellerUid, psog, e);
|
|
|
}
|
|
|
}
|
|
|
|
...
|
...
|
@@ -1017,7 +1043,9 @@ public class InBoxFacade { |
|
|
executorService.execute(() -> {
|
|
|
// 发站内信
|
|
|
logger.info("record seller sham send out inbox sms msg for seller,sellerUid {}, prdName {}", sellerUid, prdName);
|
|
|
String params = buildParams(prdName, sizeName);
|
|
|
Product product = productMapper.selectByPrimaryKey(sog.getProductId());
|
|
|
String productCode = product.getProductCode();
|
|
|
String params = buildParams(prdName, sizeName,productCode);
|
|
|
InboxReqVO req = buildInboxReqVO(sellerUid, params, InboxBusinessTypeEnum.NOTICE_SELLER_SELLER_SHAM_SEND_OUT);
|
|
|
InBoxResponse resp = inBoxSDK.addInbox(req);
|
|
|
logger.info("record seller sham send out inbox msg,sellerUid {}, prdName {},sizeName {} resp {}",
|
...
|
...
|
@@ -1029,7 +1057,7 @@ public class InBoxFacade { |
|
|
return;
|
|
|
}
|
|
|
List<String> mobileList = Arrays.asList(phone);
|
|
|
String content = getReplacedContent(InboxBusinessTypeEnum.SMS_NOTICE_SELLER_SELLER_SHAM_SEND_OUT.getContent(),prdName,orderCode);
|
|
|
String content = getReplacedContent(InboxBusinessTypeEnum.SMS_NOTICE_SELLER_SELLER_SHAM_SEND_OUT.getContent(),prdName,sizeName,productCode);
|
|
|
sendSmsService.smsSendByMobile(content, mobileList);
|
|
|
logger.info("seller sham send out msg,sellerUid {}, prdName {}", sellerUid, prdName);
|
|
|
});
|
...
|
...
|
@@ -1098,17 +1126,19 @@ public class InBoxFacade { |
|
|
InboxBusinessTypeEnum smsInboxBusinessTypeEnum;
|
|
|
String params ;
|
|
|
String content;
|
|
|
Product product = productMapper.selectByPrimaryKey(sog.getProductId());
|
|
|
String productCode = product.getProductCode();
|
|
|
try {
|
|
|
if (times == 2) {
|
|
|
params = buildParams(prdName, sizeName, leftTime, timeUnit);
|
|
|
params = buildParams(prdName, sizeName,productCode, leftTime, timeUnit);
|
|
|
ibt = InboxBusinessTypeEnum.NOTICE_SELLER_DELIVER_GOODS;
|
|
|
smsInboxBusinessTypeEnum = InboxBusinessTypeEnum.SMS_NOTIFIED_SEND_SECOND;
|
|
|
content = getReplacedContent(smsInboxBusinessTypeEnum.getContent(),prdName,leftTime,timeUnit,orderCode);
|
|
|
content = getReplacedContent(smsInboxBusinessTypeEnum.getContent(),prdName,sizeName,productCode,leftTime,timeUnit,orderCode);
|
|
|
} else if (times == 3) {
|
|
|
params = buildParams(prdName, sizeName);
|
|
|
params = buildParams(prdName, sizeName,productCode);
|
|
|
ibt = InboxBusinessTypeEnum.NOTICE_SELLER_DELIVER_GOODS_FAIL;
|
|
|
smsInboxBusinessTypeEnum = InboxBusinessTypeEnum.SMS_NOTIFIED_SEND_FAILED;
|
|
|
content = getReplacedContent(smsInboxBusinessTypeEnum.getContent(),prdName,orderCode);
|
|
|
content = getReplacedContent(smsInboxBusinessTypeEnum.getContent(),prdName,sizeName,productCode,orderCode);
|
|
|
} else {
|
|
|
return;
|
|
|
}
|
...
|
...
|
@@ -1144,6 +1174,9 @@ public class InBoxFacade { |
|
|
String sizeName = sog.getSizeName();
|
|
|
try {
|
|
|
executorService.execute(()->{
|
|
|
Product product = productMapper.selectByPrimaryKey(sog.getProductId());
|
|
|
String productCode = product.getProductCode();
|
|
|
|
|
|
InboxBusinessTypeEnum ibt = InboxBusinessTypeEnum.PURCHASE_CLOSED_BY_BUYER_AFTER_DELIVERY;
|
|
|
String params = buildParams(orderCode,compesant);
|
|
|
InboxReqVO req = buildInboxReqVO(buyerUid, params, ibt);
|
...
|
...
|
@@ -1153,7 +1186,7 @@ public class InBoxFacade { |
|
|
buyerUid, orderCode,prdName, resp);
|
|
|
//seller
|
|
|
InboxBusinessTypeEnum ibtOfSeller = InboxBusinessTypeEnum.SALE_CLOSED_BY_BUYER_AFTER_DELIVERY;
|
|
|
String paramsOfSeller = buildParams(prdName, sizeName);
|
|
|
String paramsOfSeller = buildParams(prdName, sizeName,productCode);
|
|
|
InboxReqVO reqOfSeller = buildInboxReqVO(sellerUid, paramsOfSeller, ibtOfSeller);
|
|
|
InBoxResponse respOfSeller = inBoxSDK.addInbox(reqOfSeller);
|
|
|
logger.info("record buyerCancelBeforeDepotReceive to seller inbox msg, sellerUid {}, orderCode {},prdName {} resp {}",
|
...
|
...
|
|