main
parent
f7e9ae7b68
commit
134d775067
|
|
@ -60,6 +60,8 @@ public class AppUser extends BaseEntity
|
||||||
@Excel(name = "学校")
|
@Excel(name = "学校")
|
||||||
private Long school;
|
private Long school;
|
||||||
|
|
||||||
|
private String schoolName;
|
||||||
|
|
||||||
/** 专业 */
|
/** 专业 */
|
||||||
@Excel(name = "专业")
|
@Excel(name = "专业")
|
||||||
private String major;
|
private String major;
|
||||||
|
|
|
||||||
|
|
@ -175,6 +175,7 @@ public class AppUserServiceImpl implements IAppUserService
|
||||||
entity.setIsMember(appUser.getIsMember());
|
entity.setIsMember(appUser.getIsMember());
|
||||||
entity.setAppId(appUser.getAppId());
|
entity.setAppId(appUser.getAppId());
|
||||||
entity.setSchool(appUser.getSchool());
|
entity.setSchool(appUser.getSchool());
|
||||||
|
entity.setSchoolName(appUser.getCompanyName() == null ? null : appUser.getCompanyName());
|
||||||
// 学校
|
// 学校
|
||||||
List<AppUserDataVo> schoolList = appUserMapper.selectList(entity);
|
List<AppUserDataVo> schoolList = appUserMapper.selectList(entity);
|
||||||
Collections.shuffle(schoolList);
|
Collections.shuffle(schoolList);
|
||||||
|
|
@ -185,6 +186,7 @@ public class AppUserServiceImpl implements IAppUserService
|
||||||
|
|
||||||
|
|
||||||
entity.setSchool(null);
|
entity.setSchool(null);
|
||||||
|
entity.setSchoolName(null);
|
||||||
entity.setCompanyName(appUser.getCompanyName());
|
entity.setCompanyName(appUser.getCompanyName());
|
||||||
// 公司
|
// 公司
|
||||||
List<AppUserDataVo> companylList = appUserMapper.selectList(entity);
|
List<AppUserDataVo> companylList = appUserMapper.selectList(entity);
|
||||||
|
|
@ -197,6 +199,7 @@ public class AppUserServiceImpl implements IAppUserService
|
||||||
// 好友的好友
|
// 好友的好友
|
||||||
List<Long> friendIds = appUserFriendMapper.selectByFriendId(ids);
|
List<Long> friendIds = appUserFriendMapper.selectByFriendId(ids);
|
||||||
entity.setCompanyName(null);
|
entity.setCompanyName(null);
|
||||||
|
entity.setUsername(appUser.getCompanyName() == null ? null : appUser.getCompanyName());
|
||||||
entity.setFriendIds(friendIds);
|
entity.setFriendIds(friendIds);
|
||||||
List<AppUserDataVo> friendList = appUserMapper.selectList(entity);
|
List<AppUserDataVo> friendList = appUserMapper.selectList(entity);
|
||||||
if (friendList == null || friendList.size() == 0) {
|
if (friendList == null || friendList.size() == 0) {
|
||||||
|
|
|
||||||
|
|
@ -182,10 +182,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="appId != null "> and a.id != #{appId}</if>
|
<if test="appId != null "> and a.id != #{appId}</if>
|
||||||
<if test="school != null and school != ''"> and a.school = #{school}</if>
|
<if test="school != null and school != ''"> and a.school = #{school}</if>
|
||||||
<if test="companyName != null and companyName != ''">
|
<if test="companyName != null and companyName != ''">
|
||||||
and (a.company_name like concat('%', #{companyName}, '%')
|
and a.company_name like concat('%', #{companyName}, '%')
|
||||||
or a.username like concat('%', #{companyName}, '%')
|
</if>
|
||||||
or s.name like concat('%', #{companyName}, '%')
|
<if test="username != null and username != ''">
|
||||||
)
|
and a.username like concat('%', #{username}, '%')
|
||||||
|
</if>
|
||||||
|
<if test="schoolName != null and schoolName != ''">
|
||||||
|
and s.name like concat('%', #{schoolName}, '%')
|
||||||
</if>
|
</if>
|
||||||
<if test="ids != null and ids.size()"> and a.id not in
|
<if test="ids != null and ids.size()"> and a.id not in
|
||||||
<foreach collection="ids" item="item" open="(" separator="," close=")">
|
<foreach collection="ids" item="item" open="(" separator="," close=")">
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue