Commit 36b7cda6 authored by wdy's avatar wdy

部门管理添加地址,邮编

parent bef0bd6e
...@@ -51,7 +51,13 @@ public class SysDept extends BaseEntity ...@@ -51,7 +51,13 @@ public class SysDept extends BaseEntity
/** 父部门名称 */ /** 父部门名称 */
private String parentName; private String parentName;
/** 地址 */
private String address;
/** 邮编 */
private String postcode;
/** 子部门 */ /** 子部门 */
private List<SysDept> children = new ArrayList<SysDept>(); private List<SysDept> children = new ArrayList<SysDept>();
...@@ -181,6 +187,22 @@ public class SysDept extends BaseEntity ...@@ -181,6 +187,22 @@ public class SysDept extends BaseEntity
this.children = children; this.children = children;
} }
public String getAddress() {
return address;
}
public void setAddress(String address) {
this.address = address;
}
public String getPostcode() {
return postcode;
}
public void setPostcode(String postcode) {
this.postcode = postcode;
}
@Override @Override
public String toString() { public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
...@@ -198,6 +220,8 @@ public class SysDept extends BaseEntity ...@@ -198,6 +220,8 @@ public class SysDept extends BaseEntity
.append("createTime", getCreateTime()) .append("createTime", getCreateTime())
.append("updateBy", getUpdateBy()) .append("updateBy", getUpdateBy())
.append("updateTime", getUpdateTime()) .append("updateTime", getUpdateTime())
.append("address",getAddress())
.append("postcode",getPostcode())
.toString(); .toString();
} }
} }
...@@ -20,10 +20,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -20,10 +20,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="createTime" column="create_time" /> <result property="createTime" column="create_time" />
<result property="updateBy" column="update_by" /> <result property="updateBy" column="update_by" />
<result property="updateTime" column="update_time" /> <result property="updateTime" column="update_time" />
<result property="address" column="address" />
<result property="postcode" column="postcode" />
</resultMap> </resultMap>
<sql id="selectDeptVo"> <sql id="selectDeptVo">
select d.dept_id, d.parent_id, d.ancestors, d.dept_name, d.order_num, d.leader, d.phone, d.email, d.status, d.del_flag, d.create_by, d.create_time select d.dept_id, d.parent_id, d.ancestors, d.dept_name, d.order_num, d.leader, d.phone, d.email, d.status, d.del_flag, d.create_by, d.create_time, d.address, d.postcode
from sys_dept d from sys_dept d
</sql> </sql>
...@@ -99,6 +101,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -99,6 +101,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="email != null and email != ''">email,</if> <if test="email != null and email != ''">email,</if>
<if test="status != null">status,</if> <if test="status != null">status,</if>
<if test="createBy != null and createBy != ''">create_by,</if> <if test="createBy != null and createBy != ''">create_by,</if>
<if test="address != null and address != ''">address,</if>
<if test="postcode != null and postcode != ''">postcode,</if>
create_time create_time
)values( )values(
<if test="deptId != null and deptId != 0">#{deptId},</if> <if test="deptId != null and deptId != 0">#{deptId},</if>
...@@ -111,6 +115,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -111,6 +115,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="email != null and email != ''">#{email},</if> <if test="email != null and email != ''">#{email},</if>
<if test="status != null">#{status},</if> <if test="status != null">#{status},</if>
<if test="createBy != null and createBy != ''">#{createBy},</if> <if test="createBy != null and createBy != ''">#{createBy},</if>
<if test="address != null and address != ''">#{address},</if>
<if test="postcode != null and postcode != ''">#{postcode},</if>
sysdate() sysdate()
) )
</insert> </insert>
...@@ -127,6 +133,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -127,6 +133,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="email != null">email = #{email},</if> <if test="email != null">email = #{email},</if>
<if test="status != null and status != ''">status = #{status},</if> <if test="status != null and status != ''">status = #{status},</if>
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if> <if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
<if test="address != null and address != ''">address = #{address},</if>
<if test="postcode != null and postcode != ''">postcode = #{postcode},</if>
update_time = sysdate() update_time = sysdate()
</set> </set>
where dept_id = #{deptId} where dept_id = #{deptId}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment