更新
This commit is contained in:
@@ -10,6 +10,7 @@ import com.czg.order.entity.ShopDirectMerchant;
|
||||
import com.czg.service.RedisService;
|
||||
import com.czg.service.order.dto.AggregateMerchantVO;
|
||||
import com.czg.service.order.service.ShopDirectMerchantService;
|
||||
import com.mybatisflex.core.query.QueryWrapper;
|
||||
import com.rabbitmq.client.Channel;
|
||||
import jakarta.annotation.Resource;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
@@ -86,8 +87,6 @@ public class EntryManagerMqListener {
|
||||
}
|
||||
EntryRespDto resp = EntryManager.entryMerchant(entry, platform.toArray(new String[0]));
|
||||
ShopDirectMerchant merchant = new ShopDirectMerchant();
|
||||
merchant.setShopId(entry.getShopId());
|
||||
|
||||
merchant.setWechatApplyId(resp.getWechatApplyId());
|
||||
merchant.setWechatStatus(resp.getWechatStatus());
|
||||
merchant.setWechatErrorMsg(resp.getWechatErrorMsg());
|
||||
@@ -96,17 +95,16 @@ public class EntryManagerMqListener {
|
||||
merchant.setAlipayStatus(resp.getAlipayStatus());
|
||||
merchant.setAlipayAuthInfo(resp.getAlipayAuthInfo());
|
||||
merchant.setAlipayErrorMsg(resp.getAlipayErrorMsg());
|
||||
shopDirectMerchantService.updateById(merchant);
|
||||
shopDirectMerchantService.update(merchant, new QueryWrapper().eq(ShopDirectMerchant::getShopId, shopId).eq(ShopDirectMerchant::getLicenceNo, split[1]));
|
||||
}
|
||||
channel.basicAck(deliveryTag, false);
|
||||
} catch (Exception e) {
|
||||
log.error("进件MQ对接业务异常shopId:{}", msg, e);
|
||||
ShopDirectMerchant merchant = new ShopDirectMerchant();
|
||||
merchant.setShopId(shopId);
|
||||
merchant.setWechatStatus(PayCst.EntryStatus.REJECTED);
|
||||
merchant.setAlipayStatus(PayCst.EntryStatus.REJECTED);
|
||||
merchant.setErrorMsg("系统错误,请联系管理员后重试。");
|
||||
shopDirectMerchantService.updateById(merchant);
|
||||
shopDirectMerchantService.update(merchant, new QueryWrapper().eq(ShopDirectMerchant::getShopId, shopId).eq(ShopDirectMerchant::getLicenceNo, split[1]));
|
||||
channel.basicNack(deliveryTag, false, false);
|
||||
} finally {
|
||||
delMessageId(msg);
|
||||
|
||||
Reference in New Issue
Block a user