优化切面类注解bug,加入spring管理

This commit is contained in:
sangchengzhi
2026-03-05 08:45:15 +08:00
parent cbf1ae116e
commit 9282ef6ada
7 changed files with 12 additions and 12 deletions

View File

@@ -3,9 +3,8 @@
<component name="CoolRequestSetting">
<option name="serializePaths">
<list>
<option value="C:\Users\Sang\.config\.cool-request\request\serialize\1bd30efc62b741008bc315a5b375dfce" />
<option value="C:\Users\Sang\.config\.cool-request\request\serialize\7c9ed71f67784c07ae7eca219e9a539a" />
<option value="C:\Users\Sang\.config\.cool-request\request\serialize\e73208943ce7420d81abaa46dddeaa89" />
<option value="C:\Users\Sang\.config\.cool-request\request\serialize\3876892f78a44bb7a7008fd29db477eb" />
</list>
</option>
<option name="projectCachePath" value="project-a9a67828-45d7-44aa-a811-3ecda9f37cac" />

View File

@@ -53,5 +53,5 @@ public interface UserCardMapper extends BaseMapper<UserCard> {
List<UserCardVo> selectByPatientId(@Param("patientId") String patientId);
List<UserCard> selectByUserId(Integer userId);
List<UserCardVo> selectByUserId(Integer userId);
}

View File

@@ -353,7 +353,7 @@ public class UserCardService {
return userCardMapper.deleteUserCard(userId,id);
}
public List<UserCard> selectByUserId(Integer userId) {
public List<UserCardVo> selectByUserId(Integer userId) {
return userCardMapper.selectByUserId(userId);
}
}

View File

@@ -7,6 +7,7 @@ import com.guahao.common.util.MD5Util;
import com.guahao.common.util.VeDate;
import com.guahao.h5.user.mapper.UserMapper;
import com.guahao.h5.user.model.UserCard;
import com.guahao.h5.user.model.UserCardVo;
import com.guahao.h5.user.model.UserVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
@@ -200,15 +201,15 @@ public class UserService {
}
public Boolean hasUser(Integer userId, String patientId) {
//判断该id下是否有绑定所查的用户信息
List<UserCard> list = userCardService.selectByUserId(userId);
List<UserCardVo> list = userCardService.selectByUserId(userId);
if (list == null || list.isEmpty()) {
return false;
}
// 检查用户是否绑定了特定的就诊卡号
for (UserCard userCard : list) {
if (patientId.equals(userCard.getCard_no())) {
for (UserCardVo userCard : list) {
if (patientId.equals(userCard.getCardNo())) {
return true;
}
}
@@ -216,7 +217,7 @@ public class UserService {
return false;
}
public List<UserCard> queryUserCardsByUserId(Integer userId) {
public List<UserCardVo> queryUserCardsByUserId(Integer userId) {
return userCardService.selectByUserId(userId);
}
}

View File

@@ -99,10 +99,10 @@ public class YbController {
String json = ybService.getPayAuthCode(qrcode,openid);
JSONObject jsonObject1 = JSON.parseObject(json);
String payAuthNo = jsonObject1.getString("pay_auth_no");
List<UserCard> cardList = userCardMapper.selectByUserId(uid);
List<UserCardVo> cardList = userCardMapper.selectByUserId(uid);
if (cardList.size() > 0){
cardList.forEach(vo -> {
hsjcMapper.updatePayAuthNoList(payAuthNo,vo.getCard_no());
hsjcMapper.updatePayAuthNoList(payAuthNo,vo.getCardNo());
});
}
IDVO vo =userCardMapper.queryUserCardDefaltByOpenid(openid);

View File

@@ -1,5 +1,5 @@
server.port=8089
#server.servlet.context-path=/WGZH
#server.servlet.context-path=/nxgzh
#公众号配置
wechat.AppId=wx45acd2b4907cb8f4
wechat.AppSecret=895b90585c4698485c07e113711eac85

View File

@@ -152,7 +152,7 @@
select * from user_card where patient_id = #{patientId} AND deleted = 0
</select>
<select id="selectByUserId" resultType="com.guahao.h5.user.model.UserCard">
<select id="selectByUserId" resultType="com.guahao.h5.user.model.UserCardVo">
select * from user_card where user_id = #{userId} AND deleted = 0
</select>