修改实务认知得分和智能评分规则
parent
ceb1613f62
commit
a8ac1aa1ad
@ -0,0 +1,25 @@
|
||||
package com.sztzjy.fund_investment.entity;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @Author xcj
|
||||
* @Date 2024/8/7
|
||||
*/
|
||||
@Data
|
||||
public class ZYUserInfo {
|
||||
private String username;
|
||||
private String password;
|
||||
private String name;
|
||||
private Integer userId;
|
||||
private Integer roleId;
|
||||
private Integer schoolId;
|
||||
private String schoolName;
|
||||
private Integer classId;
|
||||
private String className;
|
||||
private String phone;
|
||||
private Long collegeId;
|
||||
private String collegeName;
|
||||
private Long majorId;
|
||||
private String majorName;
|
||||
}
|
@ -1,434 +1,453 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.sztzjy.fund_investment.mapper.UserMapper">
|
||||
<resultMap id="BaseResultMap" type="com.sztzjy.fund_investment.entity.User">
|
||||
<id column="userid" jdbcType="VARCHAR" property="userid" />
|
||||
<result column="name" jdbcType="VARCHAR" property="name" />
|
||||
<result column="student_id" jdbcType="VARCHAR" property="studentId" />
|
||||
<result column="class_name" jdbcType="VARCHAR" property="className" />
|
||||
<result column="class_id" jdbcType="VARCHAR" property="classId" />
|
||||
<result column="username" jdbcType="VARCHAR" property="username" />
|
||||
<result column="password" jdbcType="VARCHAR" property="password" />
|
||||
<result column="phone" jdbcType="VARCHAR" property="phone" />
|
||||
<result column="role_id" jdbcType="INTEGER" property="roleId" />
|
||||
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
|
||||
<result column="school_id" jdbcType="VARCHAR" property="schoolId" />
|
||||
<result column="school_name" jdbcType="VARCHAR" property="schoolName" />
|
||||
<result column="un" jdbcType="VARCHAR" property="un" />
|
||||
<result column="dis" jdbcType="VARCHAR" property="dis" />
|
||||
<result column="access_token" jdbcType="VARCHAR" property="accessToken" />
|
||||
<result column="login_type" jdbcType="INTEGER" property="loginType" />
|
||||
</resultMap>
|
||||
<sql id="Example_Where_Clause">
|
||||
<where>
|
||||
<foreach collection="oredCriteria" item="criteria" separator="or">
|
||||
<if test="criteria.valid">
|
||||
<trim prefix="(" prefixOverrides="and" suffix=")">
|
||||
<foreach collection="criteria.criteria" item="criterion">
|
||||
<choose>
|
||||
<when test="criterion.noValue">
|
||||
and ${criterion.condition}
|
||||
</when>
|
||||
<when test="criterion.singleValue">
|
||||
and ${criterion.condition} #{criterion.value}
|
||||
</when>
|
||||
<when test="criterion.betweenValue">
|
||||
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
|
||||
</when>
|
||||
<when test="criterion.listValue">
|
||||
and ${criterion.condition}
|
||||
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
|
||||
#{listItem}
|
||||
</foreach>
|
||||
</when>
|
||||
</choose>
|
||||
<resultMap id="BaseResultMap" type="com.sztzjy.fund_investment.entity.User">
|
||||
<id column="userid" jdbcType="VARCHAR" property="userid"/>
|
||||
<result column="name" jdbcType="VARCHAR" property="name"/>
|
||||
<result column="student_id" jdbcType="VARCHAR" property="studentId"/>
|
||||
<result column="class_name" jdbcType="VARCHAR" property="className"/>
|
||||
<result column="class_id" jdbcType="VARCHAR" property="classId"/>
|
||||
<result column="username" jdbcType="VARCHAR" property="username"/>
|
||||
<result column="password" jdbcType="VARCHAR" property="password"/>
|
||||
<result column="phone" jdbcType="VARCHAR" property="phone"/>
|
||||
<result column="role_id" jdbcType="INTEGER" property="roleId"/>
|
||||
<result column="create_time" jdbcType="TIMESTAMP" property="createTime"/>
|
||||
<result column="school_id" jdbcType="VARCHAR" property="schoolId"/>
|
||||
<result column="school_name" jdbcType="VARCHAR" property="schoolName"/>
|
||||
<result column="un" jdbcType="VARCHAR" property="un"/>
|
||||
<result column="dis" jdbcType="VARCHAR" property="dis"/>
|
||||
<result column="access_token" jdbcType="VARCHAR" property="accessToken"/>
|
||||
<result column="login_type" jdbcType="INTEGER" property="loginType"/>
|
||||
</resultMap>
|
||||
<sql id="Example_Where_Clause">
|
||||
<where>
|
||||
<foreach collection="oredCriteria" item="criteria" separator="or">
|
||||
<if test="criteria.valid">
|
||||
<trim prefix="(" prefixOverrides="and" suffix=")">
|
||||
<foreach collection="criteria.criteria" item="criterion">
|
||||
<choose>
|
||||
<when test="criterion.noValue">
|
||||
and ${criterion.condition}
|
||||
</when>
|
||||
<when test="criterion.singleValue">
|
||||
and ${criterion.condition} #{criterion.value}
|
||||
</when>
|
||||
<when test="criterion.betweenValue">
|
||||
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
|
||||
</when>
|
||||
<when test="criterion.listValue">
|
||||
and ${criterion.condition}
|
||||
<foreach close=")" collection="criterion.value" item="listItem" open="("
|
||||
separator=",">
|
||||
#{listItem}
|
||||
</foreach>
|
||||
</when>
|
||||
</choose>
|
||||
</foreach>
|
||||
</trim>
|
||||
</if>
|
||||
</foreach>
|
||||
</trim>
|
||||
</if>
|
||||
</foreach>
|
||||
</where>
|
||||
</sql>
|
||||
<sql id="Update_By_Example_Where_Clause">
|
||||
<where>
|
||||
<foreach collection="example.oredCriteria" item="criteria" separator="or">
|
||||
<if test="criteria.valid">
|
||||
<trim prefix="(" prefixOverrides="and" suffix=")">
|
||||
<foreach collection="criteria.criteria" item="criterion">
|
||||
<choose>
|
||||
<when test="criterion.noValue">
|
||||
and ${criterion.condition}
|
||||
</when>
|
||||
<when test="criterion.singleValue">
|
||||
and ${criterion.condition} #{criterion.value}
|
||||
</when>
|
||||
<when test="criterion.betweenValue">
|
||||
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
|
||||
</when>
|
||||
<when test="criterion.listValue">
|
||||
and ${criterion.condition}
|
||||
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
|
||||
#{listItem}
|
||||
</foreach>
|
||||
</when>
|
||||
</choose>
|
||||
</where>
|
||||
</sql>
|
||||
<sql id="Update_By_Example_Where_Clause">
|
||||
<where>
|
||||
<foreach collection="example.oredCriteria" item="criteria" separator="or">
|
||||
<if test="criteria.valid">
|
||||
<trim prefix="(" prefixOverrides="and" suffix=")">
|
||||
<foreach collection="criteria.criteria" item="criterion">
|
||||
<choose>
|
||||
<when test="criterion.noValue">
|
||||
and ${criterion.condition}
|
||||
</when>
|
||||
<when test="criterion.singleValue">
|
||||
and ${criterion.condition} #{criterion.value}
|
||||
</when>
|
||||
<when test="criterion.betweenValue">
|
||||
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
|
||||
</when>
|
||||
<when test="criterion.listValue">
|
||||
and ${criterion.condition}
|
||||
<foreach close=")" collection="criterion.value" item="listItem" open="("
|
||||
separator=",">
|
||||
#{listItem}
|
||||
</foreach>
|
||||
</when>
|
||||
</choose>
|
||||
</foreach>
|
||||
</trim>
|
||||
</if>
|
||||
</foreach>
|
||||
</trim>
|
||||
</if>
|
||||
</foreach>
|
||||
</where>
|
||||
</sql>
|
||||
<sql id="Base_Column_List">
|
||||
userid, name, student_id, class_name, class_id, username, password, phone, role_id,
|
||||
</where>
|
||||
</sql>
|
||||
<sql id="Base_Column_List">
|
||||
userid
|
||||
, name, student_id, class_name, class_id, username, password, phone, role_id,
|
||||
create_time, school_id, school_name, un, dis, access_token, login_type
|
||||
</sql>
|
||||
</sql>
|
||||
|
||||
<select id="selectByUn" parameterType="java.lang.String" resultMap="BaseResultMap">
|
||||
select
|
||||
<include refid="Base_Column_List" />
|
||||
from wx_user
|
||||
where un = #{un,jdbcType=VARCHAR}
|
||||
</select>
|
||||
<select id="selectByUn" parameterType="java.lang.String" resultMap="BaseResultMap">
|
||||
select
|
||||
<include refid="Base_Column_List"/>
|
||||
from wx_user
|
||||
where un = #{un,jdbcType=VARCHAR}
|
||||
</select>
|
||||
|
||||
<select id="selectByExample" parameterType="com.sztzjy.fund_investment.entity.UserExample" resultMap="BaseResultMap">
|
||||
select
|
||||
<if test="distinct">
|
||||
distinct
|
||||
</if>
|
||||
<include refid="Base_Column_List" />
|
||||
from wx_user
|
||||
<if test="_parameter != null">
|
||||
<include refid="Example_Where_Clause" />
|
||||
</if>
|
||||
<if test="orderByClause != null">
|
||||
order by ${orderByClause}
|
||||
</if>
|
||||
</select>
|
||||
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
|
||||
select
|
||||
<include refid="Base_Column_List" />
|
||||
from wx_user
|
||||
where userid = #{userid,jdbcType=VARCHAR}
|
||||
</select>
|
||||
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
|
||||
delete from wx_user
|
||||
where userid = #{userid,jdbcType=VARCHAR}
|
||||
</delete>
|
||||
<delete id="deleteByExample" parameterType="com.sztzjy.fund_investment.entity.UserExample">
|
||||
delete from wx_user
|
||||
<if test="_parameter != null">
|
||||
<include refid="Example_Where_Clause" />
|
||||
</if>
|
||||
</delete>
|
||||
<insert id="insert" parameterType="com.sztzjy.fund_investment.entity.User">
|
||||
insert into wx_user (userid, name, student_id,
|
||||
class_name, class_id, username,
|
||||
password, phone, role_id,
|
||||
create_time, school_id, school_name,
|
||||
un, dis, access_token,
|
||||
login_type)
|
||||
values (#{userid,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{studentId,jdbcType=VARCHAR},
|
||||
#{className,jdbcType=VARCHAR}, #{classId,jdbcType=VARCHAR}, #{username,jdbcType=VARCHAR},
|
||||
#{password,jdbcType=VARCHAR}, #{phone,jdbcType=VARCHAR}, #{roleId,jdbcType=INTEGER},
|
||||
#{createTime,jdbcType=TIMESTAMP}, #{schoolId,jdbcType=VARCHAR}, #{schoolName,jdbcType=VARCHAR},
|
||||
#{un,jdbcType=VARCHAR}, #{dis,jdbcType=VARCHAR}, #{accessToken,jdbcType=VARCHAR},
|
||||
#{loginType,jdbcType=INTEGER})
|
||||
</insert>
|
||||
<insert id="insertSelective" parameterType="com.sztzjy.fund_investment.entity.User">
|
||||
insert into wx_user
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="userid != null">
|
||||
userid,
|
||||
</if>
|
||||
<if test="name != null">
|
||||
name,
|
||||
</if>
|
||||
<if test="studentId != null">
|
||||
student_id,
|
||||
</if>
|
||||
<if test="className != null">
|
||||
class_name,
|
||||
</if>
|
||||
<if test="classId != null">
|
||||
class_id,
|
||||
</if>
|
||||
<if test="username != null">
|
||||
username,
|
||||
</if>
|
||||
<if test="password != null">
|
||||
password,
|
||||
</if>
|
||||
<if test="phone != null">
|
||||
phone,
|
||||
</if>
|
||||
<if test="roleId != null">
|
||||
role_id,
|
||||
</if>
|
||||
<if test="createTime != null">
|
||||
create_time,
|
||||
</if>
|
||||
<if test="schoolId != null">
|
||||
school_id,
|
||||
</if>
|
||||
<if test="schoolName != null">
|
||||
school_name,
|
||||
</if>
|
||||
<if test="un != null">
|
||||
un,
|
||||
</if>
|
||||
<if test="dis != null">
|
||||
dis,
|
||||
</if>
|
||||
<if test="accessToken != null">
|
||||
access_token,
|
||||
</if>
|
||||
<if test="loginType != null">
|
||||
login_type,
|
||||
</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="userid != null">
|
||||
#{userid,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="name != null">
|
||||
#{name,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="studentId != null">
|
||||
#{studentId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="className != null">
|
||||
#{className,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="classId != null">
|
||||
#{classId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="username != null">
|
||||
#{username,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="password != null">
|
||||
#{password,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="phone != null">
|
||||
#{phone,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="roleId != null">
|
||||
#{roleId,jdbcType=INTEGER},
|
||||
</if>
|
||||
<if test="createTime != null">
|
||||
#{createTime,jdbcType=TIMESTAMP},
|
||||
</if>
|
||||
<if test="schoolId != null">
|
||||
#{schoolId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="schoolName != null">
|
||||
#{schoolName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="un != null">
|
||||
#{un,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="dis != null">
|
||||
#{dis,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="accessToken != null">
|
||||
#{accessToken,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="loginType != null">
|
||||
#{loginType,jdbcType=INTEGER},
|
||||
</if>
|
||||
</trim>
|
||||
</insert>
|
||||
<select id="countByExample" parameterType="com.sztzjy.fund_investment.entity.UserExample" resultType="java.lang.Long">
|
||||
select count(*) from wx_user
|
||||
<if test="_parameter != null">
|
||||
<include refid="Example_Where_Clause" />
|
||||
</if>
|
||||
</select>
|
||||
<update id="updateByExampleSelective" parameterType="map">
|
||||
update wx_user
|
||||
<set>
|
||||
<if test="record.userid != null">
|
||||
userid = #{record.userid,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.name != null">
|
||||
<select id="selectByExample" parameterType="com.sztzjy.fund_investment.entity.UserExample"
|
||||
resultMap="BaseResultMap">
|
||||
select
|
||||
<if test="distinct">
|
||||
distinct
|
||||
</if>
|
||||
<include refid="Base_Column_List"/>
|
||||
from wx_user
|
||||
<if test="_parameter != null">
|
||||
<include refid="Example_Where_Clause"/>
|
||||
</if>
|
||||
<if test="orderByClause != null">
|
||||
order by ${orderByClause}
|
||||
</if>
|
||||
</select>
|
||||
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
|
||||
select
|
||||
<include refid="Base_Column_List"/>
|
||||
from wx_user
|
||||
where userid = #{userid,jdbcType=VARCHAR}
|
||||
</select>
|
||||
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
|
||||
delete
|
||||
from wx_user
|
||||
where userid = #{userid,jdbcType=VARCHAR}
|
||||
</delete>
|
||||
<delete id="deleteByExample" parameterType="com.sztzjy.fund_investment.entity.UserExample">
|
||||
delete from wx_user
|
||||
<if test="_parameter != null">
|
||||
<include refid="Example_Where_Clause"/>
|
||||
</if>
|
||||
</delete>
|
||||
<insert id="insert" parameterType="com.sztzjy.fund_investment.entity.User">
|
||||
insert into wx_user (userid, name, student_id,
|
||||
class_name, class_id, username,
|
||||
password, phone, role_id,
|
||||
create_time, school_id, school_name,
|
||||
un, dis, access_token,
|
||||
login_type)
|
||||
values (#{userid,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{studentId,jdbcType=VARCHAR},
|
||||
#{className,jdbcType=VARCHAR}, #{classId,jdbcType=VARCHAR}, #{username,jdbcType=VARCHAR},
|
||||
#{password,jdbcType=VARCHAR}, #{phone,jdbcType=VARCHAR}, #{roleId,jdbcType=INTEGER},
|
||||
#{createTime,jdbcType=TIMESTAMP}, #{schoolId,jdbcType=VARCHAR}, #{schoolName,jdbcType=VARCHAR},
|
||||
#{un,jdbcType=VARCHAR}, #{dis,jdbcType=VARCHAR}, #{accessToken,jdbcType=VARCHAR},
|
||||
#{loginType,jdbcType=INTEGER})
|
||||
</insert>
|
||||
<insert id="insertSelective" parameterType="com.sztzjy.fund_investment.entity.User">
|
||||
insert into wx_user
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="userid != null">
|
||||
userid,
|
||||
</if>
|
||||
<if test="name != null">
|
||||
name,
|
||||
</if>
|
||||
<if test="studentId != null">
|
||||
student_id,
|
||||
</if>
|
||||
<if test="className != null">
|
||||
class_name,
|
||||
</if>
|
||||
<if test="classId != null">
|
||||
class_id,
|
||||
</if>
|
||||
<if test="username != null">
|
||||
username,
|
||||
</if>
|
||||
<if test="password != null">
|
||||
password,
|
||||
</if>
|
||||
<if test="phone != null">
|
||||
phone,
|
||||
</if>
|
||||
<if test="roleId != null">
|
||||
role_id,
|
||||
</if>
|
||||
<if test="createTime != null">
|
||||
create_time,
|
||||
</if>
|
||||
<if test="schoolId != null">
|
||||
school_id,
|
||||
</if>
|
||||
<if test="schoolName != null">
|
||||
school_name,
|
||||
</if>
|
||||
<if test="un != null">
|
||||
un,
|
||||
</if>
|
||||
<if test="dis != null">
|
||||
dis,
|
||||
</if>
|
||||
<if test="accessToken != null">
|
||||
access_token,
|
||||
</if>
|
||||
<if test="loginType != null">
|
||||
login_type,
|
||||
</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="userid != null">
|
||||
#{userid,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="name != null">
|
||||
#{name,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="studentId != null">
|
||||
#{studentId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="className != null">
|
||||
#{className,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="classId != null">
|
||||
#{classId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="username != null">
|
||||
#{username,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="password != null">
|
||||
#{password,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="phone != null">
|
||||
#{phone,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="roleId != null">
|
||||
#{roleId,jdbcType=INTEGER},
|
||||
</if>
|
||||
<if test="createTime != null">
|
||||
#{createTime,jdbcType=TIMESTAMP},
|
||||
</if>
|
||||
<if test="schoolId != null">
|
||||
#{schoolId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="schoolName != null">
|
||||
#{schoolName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="un != null">
|
||||
#{un,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="dis != null">
|
||||
#{dis,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="accessToken != null">
|
||||
#{accessToken,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="loginType != null">
|
||||
#{loginType,jdbcType=INTEGER},
|
||||
</if>
|
||||
</trim>
|
||||
</insert>
|
||||
<select id="countByExample" parameterType="com.sztzjy.fund_investment.entity.UserExample"
|
||||
resultType="java.lang.Long">
|
||||
select count(*) from wx_user
|
||||
<if test="_parameter != null">
|
||||
<include refid="Example_Where_Clause"/>
|
||||
</if>
|
||||
</select>
|
||||
<update id="updateByExampleSelective" parameterType="map">
|
||||
update wx_user
|
||||
<set>
|
||||
<if test="record.userid != null">
|
||||
userid = #{record.userid,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.name != null">
|
||||
name = #{record.name,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.studentId != null">
|
||||
student_id = #{record.studentId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.className != null">
|
||||
class_name = #{record.className,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.classId != null">
|
||||
class_id = #{record.classId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.username != null">
|
||||
username = #{record.username,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.password != null">
|
||||
password = #{record.password,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.phone != null">
|
||||
phone = #{record.phone,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.roleId != null">
|
||||
role_id = #{record.roleId,jdbcType=INTEGER},
|
||||
</if>
|
||||
<if test="record.createTime != null">
|
||||
create_time = #{record.createTime,jdbcType=TIMESTAMP},
|
||||
</if>
|
||||
<if test="record.schoolId != null">
|
||||
school_id = #{record.schoolId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.schoolName != null">
|
||||
school_name = #{record.schoolName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.un != null">
|
||||
un = #{record.un,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.dis != null">
|
||||
dis = #{record.dis,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.accessToken != null">
|
||||
access_token = #{record.accessToken,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.loginType != null">
|
||||
login_type = #{record.loginType,jdbcType=INTEGER},
|
||||
</if>
|
||||
</set>
|
||||
<if test="_parameter != null">
|
||||
<include refid="Update_By_Example_Where_Clause"/>
|
||||
</if>
|
||||
</update>
|
||||
<update id="updateByExample" parameterType="map">
|
||||
update wx_user
|
||||
set userid = #{record.userid,jdbcType=VARCHAR},
|
||||
name = #{record.name,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.studentId != null">
|
||||
student_id = #{record.studentId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.className != null">
|
||||
class_name = #{record.className,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.classId != null">
|
||||
class_id = #{record.classId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.username != null">
|
||||
username = #{record.username,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.password != null">
|
||||
password = #{record.password,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.phone != null">
|
||||
phone = #{record.phone,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.roleId != null">
|
||||
role_id = #{record.roleId,jdbcType=INTEGER},
|
||||
</if>
|
||||
<if test="record.createTime != null">
|
||||
create_time = #{record.createTime,jdbcType=TIMESTAMP},
|
||||
</if>
|
||||
<if test="record.schoolId != null">
|
||||
school_id = #{record.schoolId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.schoolName != null">
|
||||
school_name = #{record.schoolName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.un != null">
|
||||
un = #{record.un,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.dis != null">
|
||||
dis = #{record.dis,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.accessToken != null">
|
||||
access_token = #{record.accessToken,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="record.loginType != null">
|
||||
login_type = #{record.loginType,jdbcType=INTEGER},
|
||||
</if>
|
||||
</set>
|
||||
<if test="_parameter != null">
|
||||
<include refid="Update_By_Example_Where_Clause" />
|
||||
</if>
|
||||
</update>
|
||||
<update id="updateByExample" parameterType="map">
|
||||
update wx_user
|
||||
set userid = #{record.userid,jdbcType=VARCHAR},
|
||||
name = #{record.name,jdbcType=VARCHAR},
|
||||
student_id = #{record.studentId,jdbcType=VARCHAR},
|
||||
class_name = #{record.className,jdbcType=VARCHAR},
|
||||
class_id = #{record.classId,jdbcType=VARCHAR},
|
||||
username = #{record.username,jdbcType=VARCHAR},
|
||||
password = #{record.password,jdbcType=VARCHAR},
|
||||
phone = #{record.phone,jdbcType=VARCHAR},
|
||||
role_id = #{record.roleId,jdbcType=INTEGER},
|
||||
create_time = #{record.createTime,jdbcType=TIMESTAMP},
|
||||
school_id = #{record.schoolId,jdbcType=VARCHAR},
|
||||
school_name = #{record.schoolName,jdbcType=VARCHAR},
|
||||
un = #{record.un,jdbcType=VARCHAR},
|
||||
dis = #{record.dis,jdbcType=VARCHAR},
|
||||
access_token = #{record.accessToken,jdbcType=VARCHAR},
|
||||
login_type = #{record.loginType,jdbcType=INTEGER}
|
||||
<if test="_parameter != null">
|
||||
<include refid="Update_By_Example_Where_Clause" />
|
||||
</if>
|
||||
</update>
|
||||
<update id="updateByPrimaryKeySelective" parameterType="com.sztzjy.fund_investment.entity.User">
|
||||
update wx_user
|
||||
<set>
|
||||
<if test="name != null">
|
||||
name = #{name,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="studentId != null">
|
||||
student_id = #{studentId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="className != null">
|
||||
class_name = #{className,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="classId != null">
|
||||
class_id = #{classId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="username != null">
|
||||
username = #{username,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="password != null">
|
||||
password = #{password,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="phone != null">
|
||||
phone = #{phone,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="roleId != null">
|
||||
role_id = #{roleId,jdbcType=INTEGER},
|
||||
</if>
|
||||
<if test="createTime != null">
|
||||
create_time = #{createTime,jdbcType=TIMESTAMP},
|
||||
</if>
|
||||
<if test="schoolId != null">
|
||||
school_id = #{schoolId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="schoolName != null">
|
||||
school_name = #{schoolName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="un != null">
|
||||
un = #{un,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="dis != null">
|
||||
dis = #{dis,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="accessToken != null">
|
||||
access_token = #{accessToken,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="loginType != null">
|
||||
login_type = #{loginType,jdbcType=INTEGER},
|
||||
</if>
|
||||
</set>
|
||||
where userid = #{userid,jdbcType=VARCHAR}
|
||||
</update>
|
||||
<update id="updateByPrimaryKey" parameterType="com.sztzjy.fund_investment.entity.User">
|
||||
update wx_user
|
||||
set name = #{name,jdbcType=VARCHAR},
|
||||
student_id = #{studentId,jdbcType=VARCHAR},
|
||||
class_name = #{className,jdbcType=VARCHAR},
|
||||
class_id = #{classId,jdbcType=VARCHAR},
|
||||
username = #{username,jdbcType=VARCHAR},
|
||||
password = #{password,jdbcType=VARCHAR},
|
||||
phone = #{phone,jdbcType=VARCHAR},
|
||||
role_id = #{roleId,jdbcType=INTEGER},
|
||||
create_time = #{createTime,jdbcType=TIMESTAMP},
|
||||
school_id = #{schoolId,jdbcType=VARCHAR},
|
||||
school_name = #{schoolName,jdbcType=VARCHAR},
|
||||
un = #{un,jdbcType=VARCHAR},
|
||||
dis = #{dis,jdbcType=VARCHAR},
|
||||
access_token = #{accessToken,jdbcType=VARCHAR},
|
||||
login_type = #{loginType,jdbcType=INTEGER}
|
||||
where userid = #{userid,jdbcType=VARCHAR}
|
||||
</update>
|
||||
login_type = #{record.loginType,jdbcType=INTEGER}
|
||||
<if test="_parameter != null">
|
||||
<include refid="Update_By_Example_Where_Clause"/>
|
||||
</if>
|
||||
</update>
|
||||
<update id="updateByPrimaryKeySelective" parameterType="com.sztzjy.fund_investment.entity.User">
|
||||
update wx_user
|
||||
<set>
|
||||
<if test="name != null">
|
||||
name = #{name,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="studentId != null">
|
||||
student_id = #{studentId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="className != null">
|
||||
class_name = #{className,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="classId != null">
|
||||
class_id = #{classId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="username != null">
|
||||
username = #{username,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="password != null">
|
||||
password = #{password,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="phone != null">
|
||||
phone = #{phone,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="roleId != null">
|
||||
role_id = #{roleId,jdbcType=INTEGER},
|
||||
</if>
|
||||
<if test="createTime != null">
|
||||
create_time = #{createTime,jdbcType=TIMESTAMP},
|
||||
</if>
|
||||
<if test="schoolId != null">
|
||||
school_id = #{schoolId,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="schoolName != null">
|
||||
school_name = #{schoolName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="un != null">
|
||||
un = #{un,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="dis != null">
|
||||
dis = #{dis,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="accessToken != null">
|
||||
access_token = #{accessToken,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="loginType != null">
|
||||
login_type = #{loginType,jdbcType=INTEGER},
|
||||
</if>
|
||||
</set>
|
||||
where userid = #{userid,jdbcType=VARCHAR}
|
||||
</update>
|
||||
<update id="updateByPrimaryKey" parameterType="com.sztzjy.fund_investment.entity.User">
|
||||
update wx_user
|
||||
set name = #{name,jdbcType=VARCHAR},
|
||||
student_id = #{studentId,jdbcType=VARCHAR},
|
||||
class_name = #{className,jdbcType=VARCHAR},
|
||||
class_id = #{classId,jdbcType=VARCHAR},
|
||||
username = #{username,jdbcType=VARCHAR},
|
||||
password = #{password,jdbcType=VARCHAR},
|
||||
phone = #{phone,jdbcType=VARCHAR},
|
||||
role_id = #{roleId,jdbcType=INTEGER},
|
||||
create_time = #{createTime,jdbcType=TIMESTAMP},
|
||||
school_id = #{schoolId,jdbcType=VARCHAR},
|
||||
school_name = #{schoolName,jdbcType=VARCHAR},
|
||||
un = #{un,jdbcType=VARCHAR},
|
||||
dis = #{dis,jdbcType=VARCHAR},
|
||||
access_token = #{accessToken,jdbcType=VARCHAR},
|
||||
login_type = #{loginType,jdbcType=INTEGER}
|
||||
where userid = #{userid,jdbcType=VARCHAR}
|
||||
</update>
|
||||
|
||||
<resultMap id="UserDtoMap" type="com.sztzjy.fund_investment.entity.dto.UserDto">
|
||||
<id column="userid" jdbcType="VARCHAR" property="userid"/>
|
||||
<result column="school_name" jdbcType="VARCHAR" property="schoolName"/>
|
||||
<result column="class_name" jdbcType="VARCHAR" property="className"/>
|
||||
<result column="name" jdbcType="VARCHAR" property="name"/>
|
||||
<result column="student_id" jdbcType="VARCHAR" property="studentId"/>
|
||||
<result column="class_id" jdbcType="VARCHAR" property="classId"/>
|
||||
<result column="school_id" jdbcType="VARCHAR" property="schoolId"/>
|
||||
<result column="report_name" jdbcType="VARCHAR" property="reportName"/>
|
||||
<result column="total_score" jdbcType="DECIMAL" property="score"/>
|
||||
<result column="flow_id" jdbcType="VARCHAR" property="flowId"/>
|
||||
<result column="id" jdbcType="VARCHAR" property="performanceScoreId"/>
|
||||
<result column="report_id" jdbcType="VARCHAR" property="reportId"/>
|
||||
</resultMap>
|
||||
<resultMap id="UserDtoMap" type="com.sztzjy.fund_investment.entity.dto.UserDto">
|
||||
<id column="userid" jdbcType="VARCHAR" property="userid"/>
|
||||
<result column="school_name" jdbcType="VARCHAR" property="schoolName"/>
|
||||
<result column="class_name" jdbcType="VARCHAR" property="className"/>
|
||||
<result column="name" jdbcType="VARCHAR" property="name"/>
|
||||
<result column="student_id" jdbcType="VARCHAR" property="studentId"/>
|
||||
<result column="class_id" jdbcType="VARCHAR" property="classId"/>
|
||||
<result column="school_id" jdbcType="VARCHAR" property="schoolId"/>
|
||||
<result column="report_name" jdbcType="VARCHAR" property="reportName"/>
|
||||
<result column="total_score" jdbcType="DECIMAL" property="score"/>
|
||||
<result column="flow_id" jdbcType="VARCHAR" property="flowId"/>
|
||||
<result column="id" jdbcType="VARCHAR" property="performanceScoreId"/>
|
||||
<result column="report_id" jdbcType="VARCHAR" property="reportId"/>
|
||||
</resultMap>
|
||||
|
||||
|
||||
<select id="getStudentScoreDetails" resultMap="UserDtoMap">
|
||||
SELECT u.class_id,u.class_name,u.school_id,u.school_name,u.`name`,u.student_id,
|
||||
u.userid,
|
||||
tr.report_name,tr.id report_id,
|
||||
ps.total_score,ps.id,
|
||||
f.flow_id
|
||||
FROM wx_user u
|
||||
JOIN flow f on u.userid = f.userid
|
||||
LEFT JOIN training_report tr ON tr.flow_id = f.flow_id AND tr.step = '投资报告'
|
||||
LEFT JOIN performance_score ps on ps.flow_id = f.flow_id
|
||||
WHERE u.role_id = 4
|
||||
<if test="schoolId != null">
|
||||
AND u.school_id = #{schoolId}
|
||||
</if>
|
||||
<if test="classId != null">
|
||||
AND u.class_id = #{classId}
|
||||
</if>
|
||||
<if test="studentIdOrName != null">
|
||||
AND u.name like '%${studentIdOrName}%' OR u.student_id like '%${studentIdOrName}%'
|
||||
</if>
|
||||
ORDER BY ps.total_score DESC
|
||||
</select>
|
||||
<select id="getStudentScoreDetails" resultMap="UserDtoMap">
|
||||
SELECT u.class_id,u.class_name,u.school_id,u.school_name,u.`name`,u.student_id,
|
||||
u.userid,
|
||||
tr.report_name,tr.id report_id,
|
||||
ps.total_score,ps.id,
|
||||
f.flow_id
|
||||
FROM wx_user u
|
||||
JOIN flow f on u.userid = f.userid
|
||||
LEFT JOIN training_report tr ON tr.flow_id = f.flow_id AND tr.step = '投资报告'
|
||||
LEFT JOIN performance_score ps on ps.flow_id = f.flow_id
|
||||
WHERE u.role_id = 4
|
||||
<if test="schoolId != null">
|
||||
AND u.school_id = #{schoolId}
|
||||
</if>
|
||||
<if test="classId != null">
|
||||
AND u.class_id = #{classId}
|
||||
</if>
|
||||
<if test="studentIdOrName != null">
|
||||
AND u.name like '%${studentIdOrName}%' OR u.student_id like '%${studentIdOrName}%'
|
||||
</if>
|
||||
ORDER BY ps.total_score DESC
|
||||
</select>
|
||||
|
||||
|
||||
<insert id="batchInsertStudents" parameterType="java.util.List">
|
||||
insert into wx_user (userid, name, student_id,
|
||||
class_name, class_id, username,
|
||||
password, phone, role_id,
|
||||
create_time, school_id, school_name)
|
||||
values
|
||||
<foreach collection="list" item="student" separator=",">
|
||||
(#{student.userid,jdbcType=VARCHAR}, #{student.name,jdbcType=VARCHAR}, #{student.studentId,jdbcType=VARCHAR},
|
||||
#{student.className,jdbcType=VARCHAR}, #{student.classId,jdbcType=VARCHAR}, #{student.username,jdbcType=VARCHAR},
|
||||
#{student.password,jdbcType=VARCHAR}, #{student.phone,jdbcType=VARCHAR}, #{student.roleId,jdbcType=INTEGER},
|
||||
#{student.createTime,jdbcType=TIMESTAMP}, #{student.schoolId,jdbcType=VARCHAR}, #{student.schoolName,jdbcType=VARCHAR})
|
||||
</foreach>
|
||||
</insert>
|
||||
</mapper>
|
Loading…
Reference in New Issue