From 1c7e22837254781947366d09282d48a45347d0e5 Mon Sep 17 00:00:00 2001
From: huliguo <2023611923@qq.com>
Date: 星期三, 06 八月 2025 10:20:45 +0800
Subject: [PATCH] 发送小程序订单数量
---
pt-errand/src/main/java/com/ruoyi/errand/service/impl/PhoneServiceImpl.java | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/pt-errand/src/main/java/com/ruoyi/errand/service/impl/PhoneServiceImpl.java b/pt-errand/src/main/java/com/ruoyi/errand/service/impl/PhoneServiceImpl.java
index 5b33142..ab8d0ff 100644
--- a/pt-errand/src/main/java/com/ruoyi/errand/service/impl/PhoneServiceImpl.java
+++ b/pt-errand/src/main/java/com/ruoyi/errand/service/impl/PhoneServiceImpl.java
@@ -24,20 +24,22 @@
AppUser appuser = (AppUser) SecurityContextHolder.getContext().getAuthentication().getPrincipal();
//查找小区客服
Phone phone = this.getBaseMapper().selectOne(new LambdaUpdateWrapper<Phone>().eq(Phone::getType, 2)
- .eq(Phone::getCommunity_id, appuser.getCommunityId()));
+ .eq(Phone::getCommunityId, appuser.getCommunityId()));
if (phone!=null){
return phone.getPhone();
}
//查找平台客服
List<Phone> list = this.getBaseMapper().selectList(new LambdaUpdateWrapper<Phone>().eq(Phone::getType, 1));
+ if (list.size()>0){}
return list.get(0).getPhone();
}
@Override
public void saveServicePhone(String phone) {
Phone phoneEntity = this.getBaseMapper().selectOne(new LambdaUpdateWrapper<Phone>().eq(Phone::getType, 1));
- if (phoneEntity!=null){
+ if (phoneEntity==null){
//不存在
+ phoneEntity = new Phone();
phoneEntity.setType(1);
phoneEntity.setPhone(phone);
this.save(phoneEntity);
--
Gitblit v1.7.1