Pre Merge pull request !83 from 杨柳清风/master

pull/83/MERGE
杨柳清风 2024-05-10 09:57:07 +00:00 committed by Gitee
commit 6f9ccb46b2
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
1 changed files with 2 additions and 2 deletions

View File

@ -156,7 +156,7 @@ public interface UserRepository extends JpaRepository<UserEntity, String>,
@Transactional(rollbackFor = Exception.class) @Transactional(rollbackFor = Exception.class)
@Modifying @Modifying
@CacheEvict(allEntries = true) @CacheEvict(allEntries = true)
@Query(value = "UPDATE UserEntity SET id=:id WHERE email=:email") @Query(value = "UPDATE UserEntity SET email=:email WHERE id=:id")
Integer updateByIdAndEmail(@Param(value = "id") String id, Integer updateByIdAndEmail(@Param(value = "id") String id,
@Param(value = "email") String email); @Param(value = "email") String email);
@ -170,7 +170,7 @@ public interface UserRepository extends JpaRepository<UserEntity, String>,
@Transactional(rollbackFor = Exception.class) @Transactional(rollbackFor = Exception.class)
@Modifying @Modifying
@CacheEvict(allEntries = true) @CacheEvict(allEntries = true)
@Query(value = "UPDATE UserEntity SET id=:id WHERE phone=:phone") @Query(value = "UPDATE UserEntity SET phone=:phone WHERE id=:id")
Integer updateByIdAndPhone(@Param(value = "id") String id, Integer updateByIdAndPhone(@Param(value = "id") String id,
@Param(value = "phone") String phone); @Param(value = "phone") String phone);