main
parent
1d6526d875
commit
f0e5266140
|
|
@ -112,8 +112,6 @@ public class AppUser extends BaseEntity
|
||||||
@Excel(name = "技能标签,多个用,逗号隔开")
|
@Excel(name = "技能标签,多个用,逗号隔开")
|
||||||
private String skills;
|
private String skills;
|
||||||
|
|
||||||
private List<UserSkill> userSkillList;
|
|
||||||
|
|
||||||
public void setId(Long id)
|
public void setId(Long id)
|
||||||
{
|
{
|
||||||
this.id = id;
|
this.id = id;
|
||||||
|
|
@ -312,16 +310,6 @@ public class AppUser extends BaseEntity
|
||||||
{
|
{
|
||||||
return type;
|
return type;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public void setUserSkillList(List<UserSkill> userSkillList) {
|
|
||||||
this.userSkillList = userSkillList;
|
|
||||||
}
|
|
||||||
|
|
||||||
public List<UserSkill> getUserSkillList() {
|
|
||||||
return userSkillList;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setSkills(String skills) {
|
public void setSkills(String skills) {
|
||||||
this.skills = skills;
|
this.skills = skills;
|
||||||
}
|
}
|
||||||
|
|
@ -357,7 +345,6 @@ public class AppUser extends BaseEntity
|
||||||
.append("skillId", getSkillId())
|
.append("skillId", getSkillId())
|
||||||
.append("jobContent", getJobContent())
|
.append("jobContent", getJobContent())
|
||||||
.append("type", getType())
|
.append("type", getType())
|
||||||
.append("userSkillList", getUserSkillList())
|
|
||||||
.toString();
|
.toString();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,364 @@
|
||||||
|
package com.ruoyi.app.domain.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import com.ruoyi.app.domain.UserSkill;
|
||||||
|
import com.ruoyi.common.core.annotation.Excel;
|
||||||
|
import com.ruoyi.common.core.web.domain.BaseEntity;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* app用户对象 app_user
|
||||||
|
*
|
||||||
|
* @author wyh
|
||||||
|
* @date 2024-04-23
|
||||||
|
*/
|
||||||
|
public class AppUserVo extends BaseEntity
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/** 用户ID */
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
/** 用户名 */
|
||||||
|
@Excel(name = "用户名")
|
||||||
|
private String username;
|
||||||
|
|
||||||
|
/** 密码 */
|
||||||
|
@Excel(name = "密码")
|
||||||
|
private String password;
|
||||||
|
|
||||||
|
/** 昵称 */
|
||||||
|
@Excel(name = "昵称")
|
||||||
|
private String nickname;
|
||||||
|
|
||||||
|
/** 邮箱 */
|
||||||
|
@Excel(name = "邮箱")
|
||||||
|
private String email;
|
||||||
|
|
||||||
|
/** 电话 */
|
||||||
|
@Excel(name = "电话")
|
||||||
|
private String phone;
|
||||||
|
|
||||||
|
/** 地址 */
|
||||||
|
@Excel(name = "地址")
|
||||||
|
private String address;
|
||||||
|
|
||||||
|
/** 头像 */
|
||||||
|
@Excel(name = "头像")
|
||||||
|
private String avatarUrl;
|
||||||
|
|
||||||
|
/** 学历 */
|
||||||
|
@Excel(name = "学历")
|
||||||
|
private String education;
|
||||||
|
|
||||||
|
/** 学校 */
|
||||||
|
@Excel(name = "学校")
|
||||||
|
private Long school;
|
||||||
|
|
||||||
|
/** 专业 */
|
||||||
|
@Excel(name = "专业")
|
||||||
|
private String major;
|
||||||
|
|
||||||
|
/** 学历开始时间 */
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Excel(name = "学历开始时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||||
|
private Date startTime;
|
||||||
|
|
||||||
|
/** 学历结束时间 */
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Excel(name = "学历结束时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||||
|
private Date endTime;
|
||||||
|
|
||||||
|
/** 在校经历 */
|
||||||
|
@Excel(name = "在校经历")
|
||||||
|
private String experience;
|
||||||
|
|
||||||
|
/** 公司名称 */
|
||||||
|
@Excel(name = "公司名称")
|
||||||
|
private String companyName;
|
||||||
|
|
||||||
|
/** 行业 */
|
||||||
|
@Excel(name = "行业")
|
||||||
|
private String industry;
|
||||||
|
|
||||||
|
/** 在职时间 */
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Excel(name = "在职时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||||
|
private Date jobTime;
|
||||||
|
|
||||||
|
/** 职位名称 */
|
||||||
|
@Excel(name = "职位名称")
|
||||||
|
private String jobName;
|
||||||
|
|
||||||
|
/** 职位类别 */
|
||||||
|
@Excel(name = "职位类别")
|
||||||
|
private String jobType;
|
||||||
|
|
||||||
|
/** 技能id */
|
||||||
|
@Excel(name = "技能id")
|
||||||
|
private Long skillId;
|
||||||
|
|
||||||
|
/** 工作内容 */
|
||||||
|
@Excel(name = "工作内容")
|
||||||
|
private String jobContent;
|
||||||
|
|
||||||
|
/** 权限:0公开1私密 */
|
||||||
|
@Excel(name = "权限:0公开1私密")
|
||||||
|
private Long type;
|
||||||
|
|
||||||
|
@Excel(name = "学校名称")
|
||||||
|
private String schoolName;
|
||||||
|
|
||||||
|
private List<UserSkill> userSkillList;
|
||||||
|
|
||||||
|
public void setId(Long id)
|
||||||
|
{
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getId()
|
||||||
|
{
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
public void setUsername(String username)
|
||||||
|
{
|
||||||
|
this.username = username;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getUsername()
|
||||||
|
{
|
||||||
|
return username;
|
||||||
|
}
|
||||||
|
public void setPassword(String password)
|
||||||
|
{
|
||||||
|
this.password = password;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPassword()
|
||||||
|
{
|
||||||
|
return password;
|
||||||
|
}
|
||||||
|
public void setNickname(String nickname)
|
||||||
|
{
|
||||||
|
this.nickname = nickname;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getNickname()
|
||||||
|
{
|
||||||
|
return nickname;
|
||||||
|
}
|
||||||
|
public void setEmail(String email)
|
||||||
|
{
|
||||||
|
this.email = email;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getEmail()
|
||||||
|
{
|
||||||
|
return email;
|
||||||
|
}
|
||||||
|
public void setPhone(String phone)
|
||||||
|
{
|
||||||
|
this.phone = phone;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPhone()
|
||||||
|
{
|
||||||
|
return phone;
|
||||||
|
}
|
||||||
|
public void setAddress(String address)
|
||||||
|
{
|
||||||
|
this.address = address;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getAddress()
|
||||||
|
{
|
||||||
|
return address;
|
||||||
|
}
|
||||||
|
public void setAvatarUrl(String avatarUrl)
|
||||||
|
{
|
||||||
|
this.avatarUrl = avatarUrl;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getAvatarUrl()
|
||||||
|
{
|
||||||
|
return avatarUrl;
|
||||||
|
}
|
||||||
|
public void setEducation(String education)
|
||||||
|
{
|
||||||
|
this.education = education;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getEducation()
|
||||||
|
{
|
||||||
|
return education;
|
||||||
|
}
|
||||||
|
public void setSchool(Long school)
|
||||||
|
{
|
||||||
|
this.school = school;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getSchool()
|
||||||
|
{
|
||||||
|
return school;
|
||||||
|
}
|
||||||
|
public void setMajor(String major)
|
||||||
|
{
|
||||||
|
this.major = major;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getMajor()
|
||||||
|
{
|
||||||
|
return major;
|
||||||
|
}
|
||||||
|
public void setStartTime(Date startTime)
|
||||||
|
{
|
||||||
|
this.startTime = startTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getStartTime()
|
||||||
|
{
|
||||||
|
return startTime;
|
||||||
|
}
|
||||||
|
public void setEndTime(Date endTime)
|
||||||
|
{
|
||||||
|
this.endTime = endTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getEndTime()
|
||||||
|
{
|
||||||
|
return endTime;
|
||||||
|
}
|
||||||
|
public void setExperience(String experience)
|
||||||
|
{
|
||||||
|
this.experience = experience;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getExperience()
|
||||||
|
{
|
||||||
|
return experience;
|
||||||
|
}
|
||||||
|
public void setCompanyName(String companyName)
|
||||||
|
{
|
||||||
|
this.companyName = companyName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCompanyName()
|
||||||
|
{
|
||||||
|
return companyName;
|
||||||
|
}
|
||||||
|
public void setIndustry(String industry)
|
||||||
|
{
|
||||||
|
this.industry = industry;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getIndustry()
|
||||||
|
{
|
||||||
|
return industry;
|
||||||
|
}
|
||||||
|
public void setJobTime(Date jobTime)
|
||||||
|
{
|
||||||
|
this.jobTime = jobTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getJobTime()
|
||||||
|
{
|
||||||
|
return jobTime;
|
||||||
|
}
|
||||||
|
public void setJobName(String jobName)
|
||||||
|
{
|
||||||
|
this.jobName = jobName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getJobName()
|
||||||
|
{
|
||||||
|
return jobName;
|
||||||
|
}
|
||||||
|
public void setJobType(String jobType)
|
||||||
|
{
|
||||||
|
this.jobType = jobType;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getJobType()
|
||||||
|
{
|
||||||
|
return jobType;
|
||||||
|
}
|
||||||
|
public void setSkillId(Long skillId)
|
||||||
|
{
|
||||||
|
this.skillId = skillId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getSkillId()
|
||||||
|
{
|
||||||
|
return skillId;
|
||||||
|
}
|
||||||
|
public void setJobContent(String jobContent)
|
||||||
|
{
|
||||||
|
this.jobContent = jobContent;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getJobContent()
|
||||||
|
{
|
||||||
|
return jobContent;
|
||||||
|
}
|
||||||
|
public void setType(Long type)
|
||||||
|
{
|
||||||
|
this.type = type;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getType()
|
||||||
|
{
|
||||||
|
return type;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public void setUserSkillList(List<UserSkill> userSkillList) {
|
||||||
|
this.userSkillList = userSkillList;
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<UserSkill> getUserSkillList() {
|
||||||
|
return userSkillList;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSchoolName(String schoolName) {
|
||||||
|
this.schoolName = schoolName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getSchoolName() {
|
||||||
|
return schoolName;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
.append("id", getId())
|
||||||
|
.append("username", getUsername())
|
||||||
|
.append("password", getPassword())
|
||||||
|
.append("nickname", getNickname())
|
||||||
|
.append("email", getEmail())
|
||||||
|
.append("phone", getPhone())
|
||||||
|
.append("address", getAddress())
|
||||||
|
.append("createTime", getCreateTime())
|
||||||
|
.append("updateTime", getUpdateTime())
|
||||||
|
.append("avatarUrl", getAvatarUrl())
|
||||||
|
.append("education", getEducation())
|
||||||
|
.append("school", getSchool())
|
||||||
|
.append("major", getMajor())
|
||||||
|
.append("startTime", getStartTime())
|
||||||
|
.append("endTime", getEndTime())
|
||||||
|
.append("experience", getExperience())
|
||||||
|
.append("companyName", getCompanyName())
|
||||||
|
.append("industry", getIndustry())
|
||||||
|
.append("jobTime", getJobTime())
|
||||||
|
.append("jobName", getJobName())
|
||||||
|
.append("jobType", getJobType())
|
||||||
|
.append("skillId", getSkillId())
|
||||||
|
.append("jobContent", getJobContent())
|
||||||
|
.append("type", getType())
|
||||||
|
.append("userSkillList", getUserSkillList())
|
||||||
|
.toString();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -2,6 +2,7 @@ package com.ruoyi.app.mapper;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import com.ruoyi.app.domain.AppUser;
|
import com.ruoyi.app.domain.AppUser;
|
||||||
|
import com.ruoyi.app.domain.vo.AppUserVo;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* app用户Mapper接口
|
* app用户Mapper接口
|
||||||
|
|
@ -17,7 +18,7 @@ public interface AppUserMapper
|
||||||
* @param id app用户主键
|
* @param id app用户主键
|
||||||
* @return app用户
|
* @return app用户
|
||||||
*/
|
*/
|
||||||
public AppUser selectAppUserById(Long id);
|
public AppUserVo selectAppUserById(Long id);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询app用户列表
|
* 查询app用户列表
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,7 @@ package com.ruoyi.app.service;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import com.ruoyi.app.domain.AppUser;
|
import com.ruoyi.app.domain.AppUser;
|
||||||
|
import com.ruoyi.app.domain.vo.AppUserVo;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* app用户Service接口
|
* app用户Service接口
|
||||||
|
|
@ -17,7 +18,7 @@ public interface IAppUserService
|
||||||
* @param id app用户主键
|
* @param id app用户主键
|
||||||
* @return app用户
|
* @return app用户
|
||||||
*/
|
*/
|
||||||
public AppUser selectAppUserById(Long id);
|
public AppUserVo selectAppUserById(Long id);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询app用户列表
|
* 查询app用户列表
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@ import java.util.Arrays;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import com.ruoyi.app.domain.UserSkill;
|
import com.ruoyi.app.domain.UserSkill;
|
||||||
|
import com.ruoyi.app.domain.vo.AppUserVo;
|
||||||
import com.ruoyi.app.mapper.UserSkillMapper;
|
import com.ruoyi.app.mapper.UserSkillMapper;
|
||||||
import com.ruoyi.common.core.utils.DateUtils;
|
import com.ruoyi.common.core.utils.DateUtils;
|
||||||
import com.ruoyi.common.security.utils.SecurityUtils;
|
import com.ruoyi.common.security.utils.SecurityUtils;
|
||||||
|
|
@ -37,11 +38,11 @@ public class AppUserServiceImpl implements IAppUserService
|
||||||
* @return app用户
|
* @return app用户
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public AppUser selectAppUserById(Long id) {
|
public AppUserVo selectAppUserById(Long id) {
|
||||||
UserSkill userSkill = new UserSkill();
|
UserSkill userSkill = new UserSkill();
|
||||||
userSkill.setUserId(id);
|
userSkill.setUserId(id);
|
||||||
List<UserSkill> userSkillList = userSkillMapper.selectUserSkillList(userSkill);
|
List<UserSkill> userSkillList = userSkillMapper.selectUserSkillList(userSkill);
|
||||||
AppUser appUser = appUserMapper.selectAppUserById(id);
|
AppUserVo appUser = appUserMapper.selectAppUserById(id);
|
||||||
appUser.setUserSkillList(userSkillList);
|
appUser.setUserSkillList(userSkillList);
|
||||||
return appUser;
|
return appUser;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -30,6 +30,32 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<result property="jobContent" column="job_content" />
|
<result property="jobContent" column="job_content" />
|
||||||
<result property="type" column="type" />
|
<result property="type" column="type" />
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
<sql id="appUserColumns">
|
||||||
|
a.id as "id",
|
||||||
|
a.username as "username",
|
||||||
|
a.password as "password",
|
||||||
|
a.nickname as "nickname",
|
||||||
|
a.email as "email",
|
||||||
|
a.phone as "phone",
|
||||||
|
a.address as "address",
|
||||||
|
a.create_time as "createTime",
|
||||||
|
a.update_time as "updateTime",
|
||||||
|
a.avatar_url as "avatarUrl",
|
||||||
|
a.education as "education",
|
||||||
|
a.school as "school",
|
||||||
|
a.major as "major",
|
||||||
|
a.start_time as "startTime",
|
||||||
|
a.end_time as "endTime",
|
||||||
|
a.experience as "experience",
|
||||||
|
a.company_name as "companyName",
|
||||||
|
a.industry as "industry",
|
||||||
|
a.job_time as "jobTime",
|
||||||
|
a.job_name as "jobName",
|
||||||
|
a.job_type as "jobType",
|
||||||
|
a.skill_id as "skillId",
|
||||||
|
a.job_content as "jobContent",
|
||||||
|
a.type as "type"
|
||||||
|
</sql>
|
||||||
|
|
||||||
<sql id="selectAppUserVo">
|
<sql id="selectAppUserVo">
|
||||||
select id, username, password, nickname, email, phone, address, create_time, update_time, avatar_url, education, school, major, start_time, end_time, experience, company_name, industry, job_time, job_name, job_type, skill_id, job_content, type from app_user
|
select id, username, password, nickname, email, phone, address, create_time, update_time, avatar_url, education, school, major, start_time, end_time, experience, company_name, industry, job_time, job_name, job_type, skill_id, job_content, type from app_user
|
||||||
|
|
@ -62,9 +88,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
</where>
|
</where>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<select id="selectAppUserById" parameterType="Long" resultMap="AppUserResult">
|
<select id="selectAppUserById" parameterType="Long" resultType="com.ruoyi.app.domain.vo.AppUserVo">
|
||||||
<include refid="selectAppUserVo"/>
|
select
|
||||||
where id = #{id}
|
<include refid="appUserColumns"/>,
|
||||||
|
s.name as "schoolName"
|
||||||
|
from app_user a
|
||||||
|
left join app_school s on s.id = a.school
|
||||||
|
where a.id = #{id}
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<insert id="insertAppUser" parameterType="AppUser" useGeneratedKeys="true" keyProperty="id">
|
<insert id="insertAppUser" parameterType="AppUser" useGeneratedKeys="true" keyProperty="id">
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue