加字段
This commit is contained in:
parent
52d0c4bc36
commit
79ea08898b
@ -12,6 +12,7 @@ public class ScenicAccountEntity {
|
|||||||
private Long scenicId;
|
private Long scenicId;
|
||||||
private Integer isSuper;
|
private Integer isSuper;
|
||||||
private String name;
|
private String name;
|
||||||
|
private String phone;
|
||||||
private String account;
|
private String account;
|
||||||
private String password;
|
private String password;
|
||||||
private Integer status;
|
private Integer status;
|
||||||
|
@ -19,6 +19,9 @@ public class ScenicAccountReqQuery extends BaseQueryParameterReq {
|
|||||||
@ApiModelProperty("账号名称")
|
@ApiModelProperty("账号名称")
|
||||||
private String account;
|
private String account;
|
||||||
|
|
||||||
|
@ApiModelProperty("手机号")
|
||||||
|
private String phone;
|
||||||
|
|
||||||
@ApiModelProperty("账号状态(1启用/0关闭)")
|
@ApiModelProperty("账号状态(1启用/0关闭)")
|
||||||
private Integer status;
|
private Integer status;
|
||||||
|
|
||||||
|
@ -2,8 +2,8 @@
|
|||||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
||||||
<mapper namespace="com.ycwl.basic.mapper.ScenicAccountMapper">
|
<mapper namespace="com.ycwl.basic.mapper.ScenicAccountMapper">
|
||||||
<insert id="add">
|
<insert id="add">
|
||||||
insert into scenic_account(id, scenic_id, is_super, name, account, password, create_time, update_time)
|
insert into scenic_account(id, scenic_id, is_super, name, phone, account, password, create_time, update_time)
|
||||||
values (#{id}, #{scenicId}, #{isSuper}, #{name}, #{account}, #{password}, now(), now())
|
values (#{id}, #{scenicId}, #{isSuper}, #{name}, #{phone}, #{account}, #{password}, now(), now())
|
||||||
</insert>
|
</insert>
|
||||||
<update id="update">
|
<update id="update">
|
||||||
update scenic_account
|
update scenic_account
|
||||||
@ -11,6 +11,9 @@
|
|||||||
<if test="name != null and name != ''">
|
<if test="name != null and name != ''">
|
||||||
name = #{name},
|
name = #{name},
|
||||||
</if>
|
</if>
|
||||||
|
<if test="phone != null and phone != ''">
|
||||||
|
phone = #{phone},
|
||||||
|
</if>
|
||||||
<if test="account != null and account != ''">
|
<if test="account != null and account != ''">
|
||||||
account = #{account},
|
account = #{account},
|
||||||
</if>
|
</if>
|
||||||
@ -40,12 +43,12 @@
|
|||||||
</delete>
|
</delete>
|
||||||
<select id="getSuperAccountOfScenic"
|
<select id="getSuperAccountOfScenic"
|
||||||
resultType="com.ycwl.basic.model.pc.scenic.entity.ScenicAccountEntity">
|
resultType="com.ycwl.basic.model.pc.scenic.entity.ScenicAccountEntity">
|
||||||
select id, scenic_id, is_super, name, account, password, create_time, update_time
|
select id, scenic_id, is_super, name, phone, account, password, create_time, update_time
|
||||||
from scenic_account
|
from scenic_account
|
||||||
where scenic_id = #{scenicId} and is_super = 1
|
where scenic_id = #{scenicId} and is_super = 1
|
||||||
</select>
|
</select>
|
||||||
<select id="getByAccount" resultType="com.ycwl.basic.model.pc.scenic.entity.ScenicAccountEntity">
|
<select id="getByAccount" resultType="com.ycwl.basic.model.pc.scenic.entity.ScenicAccountEntity">
|
||||||
select id, scenic_id, is_super, name, account, password, status,create_time, update_time
|
select id, scenic_id, is_super, name, phone, account, password, status,create_time, update_time
|
||||||
from scenic_account
|
from scenic_account
|
||||||
where account = #{account}
|
where account = #{account}
|
||||||
</select>
|
</select>
|
||||||
@ -60,9 +63,12 @@
|
|||||||
<if test="scenicId != null">
|
<if test="scenicId != null">
|
||||||
AND scenic_id = #{scenicId}
|
AND scenic_id = #{scenicId}
|
||||||
</if>
|
</if>
|
||||||
<if test="account != null">
|
<if test="account != null and account != ''">
|
||||||
AND account LIKE CONCAT('%', #{account}, '%')
|
AND account LIKE CONCAT('%', #{account}, '%')
|
||||||
</if>
|
</if>
|
||||||
|
<if test="phone != null and phone != ''">
|
||||||
|
AND phone LIKE CONCAT('%', #{phone}, '%')
|
||||||
|
</if>
|
||||||
<if test="status != null">
|
<if test="status != null">
|
||||||
AND status = #{status}
|
AND status = #{status}
|
||||||
</if>
|
</if>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user