dingxin hace 6 años
padre
commit
e23c3d9ae0

+ 12
- 13
CODE/smart-community/property-api/src/main/java/com/community/huiju/controller/UserController.java Ver fichero

@@ -1,12 +1,11 @@
1 1
 package com.community.huiju.controller;
2 2
 
3 3
 
4
+import com.alibaba.fastjson.JSONObject;
4 5
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
5
-import com.community.commom.constant.Constant;
6 6
 import com.community.commom.mode.ResponseBean;
7
-import com.community.commom.session.UserElement;
8 7
 import com.community.huiju.common.base.BaseController;
9
-import com.community.huiju.model.User;
8
+import com.community.huiju.model.TaUser;
10 9
 import com.community.huiju.service.IUserService;
11 10
 import io.swagger.annotations.Api;
12 11
 import io.swagger.annotations.ApiImplicitParam;
@@ -14,11 +13,10 @@ import io.swagger.annotations.ApiImplicitParams;
14 13
 import io.swagger.annotations.ApiOperation;
15 14
 import org.springframework.beans.factory.annotation.Autowired;
16 15
 import org.springframework.cloud.context.config.annotation.RefreshScope;
17
-import org.springframework.web.bind.annotation.RequestMapping;
18
-import org.springframework.web.bind.annotation.RequestMethod;
19
-import org.springframework.web.bind.annotation.RestController;
16
+import org.springframework.web.bind.annotation.*;
20 17
 
21 18
 import javax.servlet.http.HttpSession;
19
+import java.util.HashMap;
22 20
 
23 21
 /**
24 22
  * <p>
@@ -36,6 +34,7 @@ public class UserController extends BaseController {
36 34
 	
37 35
 	@Autowired
38 36
 	private IUserService userService;
37
+
39 38
 	
40 39
 	@ApiOperation(value = "获取用户列表",nickname = "获取用户信息")
41 40
 	@ApiImplicitParams({
@@ -52,13 +51,13 @@ public class UserController extends BaseController {
52 51
 
53 52
 	@ApiOperation(value = "获取已认证通过的用户信息",nickname ="获取已认证通过的用户信息")
54 53
 	@ApiImplicitParams({
55
-			@ApiImplicitParam(paramType="body",dataType = "String",name ="phone",value = "电话"),
56
-			@ApiImplicitParam(paramType="body",dataType = "String",name ="name",value = "姓名"),
57
-			@ApiImplicitParam(paramType="body",dataType = "String",name ="status",value = "认证状态")
58
-	})
59
-	@RequestMapping(value = "/userPassCertification",method = RequestMethod.GET)
60
-	public ResponseBean userPassCertification(){
54
+			@ApiImplicitParam(paramType = "body", dataType = "String", name = "paramets", value ="loginName:手机号,serName:姓名 ,verifyStatus:审核状态,current:每页显示多少条,pageSzie:当前页数")})
55
+
56
+	@RequestMapping(value="/userPassCertification",method = RequestMethod.POST)
57
+	public ResponseBean userPassCertification(@RequestBody String paramets){
58
+
61 59
 
62
-		return null;
60
+		ResponseBean allApprove=userService.selectUserApprove(paramets);
61
+		return allApprove;
63 62
 	}
64 63
 }

+ 32
- 0
CODE/smart-community/property-api/src/main/java/com/community/huiju/dao/TaUserMapper.java Ver fichero

@@ -0,0 +1,32 @@
1
+package com.community.huiju.dao;
2
+
3
+import com.baomidou.mybatisplus.core.metadata.IPage;
4
+import com.community.huiju.model.TaUser;
5
+import org.apache.ibatis.annotations.Mapper;
6
+import org.apache.ibatis.annotations.Param;
7
+
8
+import java.util.List;
9
+import java.util.Map;
10
+
11
+@Mapper
12
+public interface TaUserMapper {
13
+    int deleteByPrimaryKey(Integer id);
14
+
15
+    int insert(TaUser record);
16
+
17
+    int insertSelective(TaUser record);
18
+
19
+    TaUser selectByPrimaryKey(Integer id);
20
+
21
+    int updateByPrimaryKeySelective(TaUser record);
22
+
23
+    int updateByPrimaryKey(TaUser record);
24
+
25
+    /**
26
+     * 获取已认证通过的
27
+     * @param map
28
+     * @param page
29
+     * @return
30
+     */
31
+    List<Map<Object,Object>> selectUserApprove(Map<Object, Object> map, IPage page);
32
+}

+ 0
- 2
CODE/smart-community/property-api/src/main/java/com/community/huiju/dao/UserMapper.java Ver fichero

@@ -16,6 +16,4 @@ import java.util.Map;
16 16
  */
17 17
 public interface UserMapper extends BaseMapper<User> {
18 18
 
19
-    List<Map<Object,Object>> selectUserApprove(Map<Object,Object> map);
20
-
21 19
 }

+ 240
- 0
CODE/smart-community/property-api/src/main/java/com/community/huiju/model/TaUser.java Ver fichero

@@ -0,0 +1,240 @@
1
+package com.community.huiju.model;
2
+
3
+import java.util.Date;
4
+
5
+public class TaUser {
6
+    private Integer id;
7
+
8
+    private Integer communityId;
9
+
10
+    private Integer buildingOwnerInfoId;
11
+
12
+    private String headPortrait;
13
+
14
+    private String userName;
15
+
16
+    private String loginName;
17
+
18
+    private String loginPassword;
19
+
20
+    private String email;
21
+
22
+    private String gender;
23
+
24
+    private String status;
25
+
26
+    private String remark;
27
+
28
+    private Integer parentId;
29
+
30
+    private String acceptAgreementStatus;
31
+
32
+    private String verifyStatus;
33
+
34
+    private Integer createUser;
35
+
36
+    private Date createDate;
37
+
38
+    private Integer updateUser;
39
+
40
+    private Date updateDate;
41
+
42
+    // 海康UserId
43
+    private Integer hkUserId;
44
+
45
+    // 海康 卡片号
46
+    private String hkCardNo;
47
+
48
+    // 人脸状态
49
+    private String faceStatus;
50
+
51
+    // 角色编号
52
+    private Integer role;
53
+
54
+    // 角色名称
55
+    private String roleName;
56
+
57
+    public Integer getId() {
58
+        return id;
59
+    }
60
+
61
+    public void setId(Integer id) {
62
+        this.id = id;
63
+    }
64
+
65
+    public Integer getCommunityId() {
66
+        return communityId;
67
+    }
68
+
69
+    public void setCommunityId(Integer communityId) {
70
+        this.communityId = communityId;
71
+    }
72
+
73
+    public Integer getBuildingOwnerInfoId() {
74
+        return buildingOwnerInfoId;
75
+    }
76
+
77
+    public void setBuildingOwnerInfoId(Integer buildingOwnerInfoId) {
78
+        this.buildingOwnerInfoId = buildingOwnerInfoId;
79
+    }
80
+
81
+    public String getHeadPortrait() {
82
+        return headPortrait;
83
+    }
84
+
85
+    public void setHeadPortrait(String headPortrait) {
86
+        this.headPortrait = headPortrait == null ? null : headPortrait.trim();
87
+    }
88
+
89
+    public String getUserName() {
90
+        return userName;
91
+    }
92
+
93
+    public void setUserName(String userName) {
94
+        this.userName = userName == null ? null : userName.trim();
95
+    }
96
+
97
+    public String getLoginName() {
98
+        return loginName;
99
+    }
100
+
101
+    public void setLoginName(String loginName) {
102
+        this.loginName = loginName == null ? null : loginName.trim();
103
+    }
104
+
105
+    public String getLoginPassword() {
106
+        return loginPassword;
107
+    }
108
+
109
+    public void setLoginPassword(String loginPassword) {
110
+        this.loginPassword = loginPassword == null ? null : loginPassword.trim();
111
+    }
112
+
113
+    public String getEmail() {
114
+        return email;
115
+    }
116
+
117
+    public void setEmail(String email) {
118
+        this.email = email == null ? null : email.trim();
119
+    }
120
+
121
+    public String getGender() {
122
+        return gender;
123
+    }
124
+
125
+    public void setGender(String gender) {
126
+        this.gender = gender == null ? null : gender.trim();
127
+    }
128
+
129
+    public String getStatus() {
130
+        return status;
131
+    }
132
+
133
+    public void setStatus(String status) {
134
+        this.status = status == null ? null : status.trim();
135
+    }
136
+
137
+    public String getRemark() {
138
+        return remark;
139
+    }
140
+
141
+    public void setRemark(String remark) {
142
+        this.remark = remark == null ? null : remark.trim();
143
+    }
144
+
145
+    public Integer getParentId() {
146
+        return parentId;
147
+    }
148
+
149
+    public void setParentId(Integer parentId) {
150
+        this.parentId = parentId;
151
+    }
152
+
153
+    public String getAcceptAgreementStatus() {
154
+        return acceptAgreementStatus;
155
+    }
156
+
157
+    public void setAcceptAgreementStatus(String acceptAgreementStatus) {
158
+        this.acceptAgreementStatus = acceptAgreementStatus == null ? null : acceptAgreementStatus.trim();
159
+    }
160
+
161
+    public String getVerifyStatus() {
162
+        return verifyStatus;
163
+    }
164
+
165
+    public void setVerifyStatus(String verifyStatus) {
166
+        this.verifyStatus = verifyStatus == null ? null : verifyStatus.trim();
167
+    }
168
+
169
+    public String getFaceStatus() {
170
+        return faceStatus;
171
+    }
172
+
173
+    public void setFaceStatus(String faceStatus) {
174
+        this.faceStatus = faceStatus;
175
+    }
176
+
177
+    public Integer getCreateUser() {
178
+        return createUser;
179
+    }
180
+
181
+    public void setCreateUser(Integer createUser) {
182
+        this.createUser = createUser;
183
+    }
184
+
185
+    public Date getCreateDate() {
186
+        return createDate;
187
+    }
188
+
189
+    public void setCreateDate(Date createDate) {
190
+        this.createDate = createDate;
191
+    }
192
+
193
+    public Integer getUpdateUser() {
194
+        return updateUser;
195
+    }
196
+
197
+    public void setUpdateUser(Integer updateUser) {
198
+        this.updateUser = updateUser;
199
+    }
200
+
201
+    public Date getUpdateDate() {
202
+        return updateDate;
203
+    }
204
+
205
+    public void setUpdateDate(Date updateDate) {
206
+        this.updateDate = updateDate;
207
+    }
208
+
209
+    public Integer getHkUserId() {
210
+        return hkUserId;
211
+    }
212
+
213
+    public void setHkUserId(Integer hkUserId) {
214
+        this.hkUserId = hkUserId;
215
+    }
216
+
217
+    public String getHkCardNo() {
218
+        return hkCardNo;
219
+    }
220
+
221
+    public void setHkCardNo(String hkCardNo) {
222
+        this.hkCardNo = hkCardNo;
223
+    }
224
+
225
+    public Integer getRole() {
226
+        return role;
227
+    }
228
+
229
+    public void setRole(Integer role) {
230
+        this.role = role;
231
+    }
232
+
233
+    public String getRoleName() {
234
+        return roleName;
235
+    }
236
+
237
+    public void setRoleName(String roleName) {
238
+        this.roleName = roleName;
239
+    }
240
+}

+ 4
- 2
CODE/smart-community/property-api/src/main/java/com/community/huiju/service/IUserService.java Ver fichero

@@ -1,10 +1,12 @@
1 1
 package com.community.huiju.service;
2 2
 
3 3
 
4
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
4 5
 import com.baomidou.mybatisplus.extension.service.IService;
6
+import com.community.commom.mode.ResponseBean;
7
+import com.community.huiju.model.TaUser;
5 8
 import com.community.huiju.model.User;
6 9
 
7
-import java.util.List;
8 10
 import java.util.Map;
9 11
 
10 12
 /**
@@ -16,6 +18,6 @@ import java.util.Map;
16 18
  * @since 2018-12-18
17 19
  */
18 20
 public interface IUserService extends IService<User> {
19
-    List<Object> selectUserApprove(Map map);
21
+    ResponseBean selectUserApprove(String paramets);
20 22
 
21 23
 }

+ 35
- 5
CODE/smart-community/property-api/src/main/java/com/community/huiju/service/impl/UserServiceImpl.java Ver fichero

@@ -1,13 +1,21 @@
1 1
 package com.community.huiju.service.impl;
2 2
 
3 3
 
4
+import com.alibaba.fastjson.JSONObject;
5
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
4 6
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
7
+import com.community.commom.mode.ResponseBean;
8
+import com.community.huiju.dao.TaUserMapper;
5 9
 import com.community.huiju.dao.UserMapper;
10
+import com.community.huiju.model.TaUser;
6 11
 import com.community.huiju.model.User;
7 12
 import com.community.huiju.service.IUserService;
13
+import lombok.extern.slf4j.Slf4j;
8 14
 import org.springframework.beans.factory.annotation.Autowired;
9 15
 import org.springframework.stereotype.Service;
16
+import org.springframework.transaction.annotation.Transactional;
10 17
 
18
+import java.util.HashMap;
11 19
 import java.util.List;
12 20
 import java.util.Map;
13 21
 
@@ -20,12 +28,34 @@ import java.util.Map;
20 28
  * @since 2018-12-18
21 29
  */
22 30
 @Service("userService")
31
+@Transactional
32
+@Slf4j
23 33
 public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements IUserService {
24
-@Autowired
25
-private UserMapper userMapper;
34
+    @Autowired
35
+    private TaUserMapper taUserMapper;
36
+
26 37
     @Override
27
-    public List<Object> selectUserApprove(Map map) {
28
-        List UserApprove=userMapper.selectUserApprove(map);
29
-        return UserApprove;
38
+    public ResponseBean selectUserApprove(String paramets) {
39
+
40
+        ResponseBean responseBean = new ResponseBean();
41
+
42
+        JSONObject jsonobject = JSONObject.parseObject(paramets);
43
+        Integer pageNum= jsonobject.getInteger("pageNum");
44
+        Integer pageSize= jsonobject.getInteger("pageSize");
45
+        TaUser tpTicket = JSONObject.parseObject(paramets,TaUser.class);
46
+        HashMap map = new HashMap<>();
47
+        map.put("loginName",tpTicket.getLoginName());
48
+        map.put("userName",tpTicket.getUserName());
49
+        map.put("verifyStatus",tpTicket.getVerifyStatus());
50
+
51
+        // 分页
52
+        Page<TaUser> page = new Page<>();
53
+        page.setSize(pageSize == null ? 1 : pageSize);
54
+        page.setCurrent(pageNum == null ? 10 : pageNum);
55
+
56
+        List<Map<Object,Object>> mapList = taUserMapper.selectUserApprove(map,page);
57
+        responseBean.addSuccess(mapList);
58
+
59
+        return responseBean;
30 60
     }
31 61
 }

+ 301
- 0
CODE/smart-community/property-api/src/main/resources/mapper/TaUserMapper.xml Ver fichero

@@ -0,0 +1,301 @@
1
+<?xml version="1.0" encoding="UTF-8" ?>
2
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
3
+<mapper namespace="com.community.huiju.dao.TaUserMapper" >
4
+  <resultMap id="BaseResultMap" type="com.community.huiju.model.TaUser" >
5
+    <id column="id" property="id" jdbcType="INTEGER" />
6
+    <result column="community_id" property="communityId" jdbcType="INTEGER" />
7
+    <result column="building_owner_info_id" property="buildingOwnerInfoId" jdbcType="INTEGER" />
8
+    <result column="head_portrait" property="headPortrait" jdbcType="VARCHAR" />
9
+    <result column="user_name" property="userName" jdbcType="VARCHAR" />
10
+    <result column="login_name" property="loginName" jdbcType="VARCHAR" />
11
+    <result column="login_password" property="loginPassword" jdbcType="VARCHAR" />
12
+    <result column="email" property="email" jdbcType="VARCHAR" />
13
+    <result column="gender" property="gender" jdbcType="CHAR" />
14
+    <result column="status" property="status" jdbcType="CHAR" />
15
+    <result column="remark" property="remark" jdbcType="VARCHAR" />
16
+    <result column="parent_id" property="parentId" jdbcType="INTEGER" />
17
+    <result column="accept_agreement_status" property="acceptAgreementStatus" jdbcType="CHAR" />
18
+    <result column="verify_status" property="verifyStatus" jdbcType="CHAR" />
19
+    <result column="create_user" property="createUser" jdbcType="INTEGER" />
20
+    <result column="create_date" property="createDate" jdbcType="TIMESTAMP" />
21
+    <result column="update_user" property="updateUser" jdbcType="INTEGER" />
22
+    <result column="update_date" property="updateDate" jdbcType="TIMESTAMP" />
23
+    <result column="hk_user_id" property="hkUserId" jdbcType="INTEGER" />
24
+    <result column="hk_card_no" property="hkCardNo" jdbcType="VARCHAR" />
25
+    <result column="face_status" property="faceStatus" jdbcType="CHAR" />
26
+  </resultMap>
27
+  <sql id="Base_Column_List" >
28
+    id, community_id, building_owner_info_id, head_portrait, user_name, login_name, login_password,
29
+    email, gender, status, remark, parent_id, accept_agreement_status, verify_status,
30
+    create_user, create_date, update_user, update_date, hk_user_id, hk_card_no, face_status
31
+  </sql>
32
+  <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.Integer" >
33
+    select
34
+    <include refid="Base_Column_List" />
35
+    from ta_user
36
+    where id = #{id,jdbcType=INTEGER}
37
+  </select>
38
+  <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer" >
39
+    delete from ta_user
40
+    where id = #{id,jdbcType=INTEGER}
41
+  </delete>
42
+  <insert id="insert" parameterType="com.community.huiju.model.TaUser" useGeneratedKeys="true" keyProperty="id" >
43
+    insert into ta_user (id, community_id, building_owner_info_id,
44
+      head_portrait, user_name, login_name,
45
+      login_password, email, gender,
46
+      status, remark, parent_id,
47
+      accept_agreement_status, verify_status, create_user,
48
+      create_date, update_user, update_date,
49
+      hk_user_id, hk_card_no, face_status
50
+      )
51
+    values (#{id,jdbcType=INTEGER}, #{communityId,jdbcType=INTEGER}, #{buildingOwnerInfoId,jdbcType=INTEGER},
52
+      #{headPortrait,jdbcType=VARCHAR}, #{userName,jdbcType=VARCHAR}, #{loginName,jdbcType=VARCHAR},
53
+      #{loginPassword,jdbcType=VARCHAR}, #{email,jdbcType=VARCHAR}, #{gender,jdbcType=CHAR},
54
+      #{status,jdbcType=CHAR}, #{remark,jdbcType=VARCHAR}, #{parentId,jdbcType=INTEGER},
55
+      #{acceptAgreementStatus,jdbcType=CHAR}, #{verifyStatus,jdbcType=CHAR}, #{createUser,jdbcType=INTEGER},
56
+      #{createDate,jdbcType=TIMESTAMP}, #{updateUser,jdbcType=INTEGER}, #{updateDate,jdbcType=TIMESTAMP},
57
+      #{hkUserId,jdbcType=INTEGER}, #{hkCardNo,jdbcType=VARCHAR}, #{faceStatus,jdbcType=CHAR}
58
+      )
59
+  </insert>
60
+  <insert id="insertSelective" parameterType="com.community.huiju.model.TaUser" useGeneratedKeys="true" keyProperty="id" >
61
+    insert into ta_user
62
+    <trim prefix="(" suffix=")" suffixOverrides="," >
63
+      <if test="id != null" >
64
+        id,
65
+      </if>
66
+      <if test="communityId != null" >
67
+        community_id,
68
+      </if>
69
+      <if test="buildingOwnerInfoId != null" >
70
+        building_owner_info_id,
71
+      </if>
72
+      <if test="headPortrait != null" >
73
+        head_portrait,
74
+      </if>
75
+      <if test="userName != null" >
76
+        user_name,
77
+      </if>
78
+      <if test="loginName != null" >
79
+        login_name,
80
+      </if>
81
+      <if test="loginPassword != null" >
82
+        login_password,
83
+      </if>
84
+      <if test="email != null" >
85
+        email,
86
+      </if>
87
+      <if test="gender != null" >
88
+        gender,
89
+      </if>
90
+      <if test="status != null" >
91
+        status,
92
+      </if>
93
+      <if test="remark != null" >
94
+        remark,
95
+      </if>
96
+      <if test="parentId != null" >
97
+        parent_id,
98
+      </if>
99
+      <if test="acceptAgreementStatus != null" >
100
+        accept_agreement_status,
101
+      </if>
102
+      <if test="verifyStatus != null" >
103
+        verify_status,
104
+      </if>
105
+      <if test="createUser != null" >
106
+        create_user,
107
+      </if>
108
+      <if test="createDate != null" >
109
+        create_date,
110
+      </if>
111
+      <if test="updateUser != null" >
112
+        update_user,
113
+      </if>
114
+      <if test="updateDate != null" >
115
+        update_date,
116
+      </if>
117
+      <if test="hkUserId != null" >
118
+        hk_user_id,
119
+      </if>
120
+      <if test="hkCardNo != null" >
121
+        hk_card_no,
122
+      </if>
123
+      <if test="faceStatus != null" >
124
+        face_status,
125
+      </if>
126
+    </trim>
127
+    <trim prefix="values (" suffix=")" suffixOverrides="," >
128
+      <if test="id != null" >
129
+        #{id,jdbcType=INTEGER},
130
+      </if>
131
+      <if test="communityId != null" >
132
+        #{communityId,jdbcType=INTEGER},
133
+      </if>
134
+      <if test="buildingOwnerInfoId != null" >
135
+        #{buildingOwnerInfoId,jdbcType=INTEGER},
136
+      </if>
137
+      <if test="headPortrait != null" >
138
+        #{headPortrait,jdbcType=VARCHAR},
139
+      </if>
140
+      <if test="userName != null" >
141
+        #{userName,jdbcType=VARCHAR},
142
+      </if>
143
+      <if test="loginName != null" >
144
+        #{loginName,jdbcType=VARCHAR},
145
+      </if>
146
+      <if test="loginPassword != null" >
147
+        #{loginPassword,jdbcType=VARCHAR},
148
+      </if>
149
+      <if test="email != null" >
150
+        #{email,jdbcType=VARCHAR},
151
+      </if>
152
+      <if test="gender != null" >
153
+        #{gender,jdbcType=CHAR},
154
+      </if>
155
+      <if test="status != null" >
156
+        #{status,jdbcType=CHAR},
157
+      </if>
158
+      <if test="remark != null" >
159
+        #{remark,jdbcType=VARCHAR},
160
+      </if>
161
+      <if test="parentId != null" >
162
+        #{parentId,jdbcType=INTEGER},
163
+      </if>
164
+      <if test="acceptAgreementStatus != null" >
165
+        #{acceptAgreementStatus,jdbcType=CHAR},
166
+      </if>
167
+      <if test="verifyStatus != null" >
168
+        #{verifyStatus,jdbcType=CHAR},
169
+      </if>
170
+      <if test="createUser != null" >
171
+        #{createUser,jdbcType=INTEGER},
172
+      </if>
173
+      <if test="createDate != null" >
174
+        #{createDate,jdbcType=TIMESTAMP},
175
+      </if>
176
+      <if test="updateUser != null" >
177
+        #{updateUser,jdbcType=INTEGER},
178
+      </if>
179
+      <if test="updateDate != null" >
180
+        #{updateDate,jdbcType=TIMESTAMP},
181
+      </if>
182
+      <if test="hkUserId != null" >
183
+        #{hkUserId,jdbcType=INTEGER},
184
+      </if>
185
+      <if test="hkCardNo != null" >
186
+        #{hkCardNo,jdbcType=VARCHAR},
187
+      </if>
188
+      <if test="faceStatus != null" >
189
+        #{faceStatus,jdbcType=CHAR},
190
+      </if>
191
+    </trim>
192
+  </insert>
193
+  <update id="updateByPrimaryKeySelective" parameterType="com.community.huiju.model.TaUser" >
194
+    update ta_user
195
+    <set >
196
+      <if test="communityId != null" >
197
+        community_id = #{communityId,jdbcType=INTEGER},
198
+      </if>
199
+      <if test="buildingOwnerInfoId != null" >
200
+        building_owner_info_id = #{buildingOwnerInfoId,jdbcType=INTEGER},
201
+      </if>
202
+      <if test="headPortrait != null" >
203
+        head_portrait = #{headPortrait,jdbcType=VARCHAR},
204
+      </if>
205
+      <if test="userName != null" >
206
+        user_name = #{userName,jdbcType=VARCHAR},
207
+      </if>
208
+      <if test="loginName != null" >
209
+        login_name = #{loginName,jdbcType=VARCHAR},
210
+      </if>
211
+      <if test="loginPassword != null" >
212
+        login_password = #{loginPassword,jdbcType=VARCHAR},
213
+      </if>
214
+      <if test="email != null" >
215
+        email = #{email,jdbcType=VARCHAR},
216
+      </if>
217
+      <if test="gender != null" >
218
+        gender = #{gender,jdbcType=CHAR},
219
+      </if>
220
+      <if test="status != null" >
221
+        status = #{status,jdbcType=CHAR},
222
+      </if>
223
+      <if test="remark != null" >
224
+        remark = #{remark,jdbcType=VARCHAR},
225
+      </if>
226
+      <if test="parentId != null" >
227
+        parent_id = #{parentId,jdbcType=INTEGER},
228
+      </if>
229
+      <if test="acceptAgreementStatus != null" >
230
+        accept_agreement_status = #{acceptAgreementStatus,jdbcType=CHAR},
231
+      </if>
232
+      <if test="verifyStatus != null" >
233
+        verify_status = #{verifyStatus,jdbcType=CHAR},
234
+      </if>
235
+      <if test="createUser != null" >
236
+        create_user = #{createUser,jdbcType=INTEGER},
237
+      </if>
238
+      <if test="createDate != null" >
239
+        create_date = #{createDate,jdbcType=TIMESTAMP},
240
+      </if>
241
+      <if test="updateUser != null" >
242
+        update_user = #{updateUser,jdbcType=INTEGER},
243
+      </if>
244
+      <if test="updateDate != null" >
245
+        update_date = #{updateDate,jdbcType=TIMESTAMP},
246
+      </if>
247
+      <if test="hkUserId != null" >
248
+        hk_user_id = #{hkUserId,jdbcType=INTEGER},
249
+      </if>
250
+      <if test="hkCardNo != null" >
251
+        hk_card_no = #{hkCardNo,jdbcType=VARCHAR},
252
+      </if>
253
+      <if test="faceStatus != null" >
254
+        face_status = #{faceStatus,jdbcType=CHAR},
255
+      </if>
256
+    </set>
257
+    where id = #{id,jdbcType=INTEGER}
258
+  </update>
259
+  <update id="updateByPrimaryKey" parameterType="com.community.huiju.model.TaUser" >
260
+    update ta_user
261
+    set community_id = #{communityId,jdbcType=INTEGER},
262
+      building_owner_info_id = #{buildingOwnerInfoId,jdbcType=INTEGER},
263
+      head_portrait = #{headPortrait,jdbcType=VARCHAR},
264
+      user_name = #{userName,jdbcType=VARCHAR},
265
+      login_name = #{loginName,jdbcType=VARCHAR},
266
+      login_password = #{loginPassword,jdbcType=VARCHAR},
267
+      email = #{email,jdbcType=VARCHAR},
268
+      gender = #{gender,jdbcType=CHAR},
269
+      status = #{status,jdbcType=CHAR},
270
+      remark = #{remark,jdbcType=VARCHAR},
271
+      parent_id = #{parentId,jdbcType=INTEGER},
272
+      accept_agreement_status = #{acceptAgreementStatus,jdbcType=CHAR},
273
+      verify_status = #{verifyStatus,jdbcType=CHAR},
274
+      create_user = #{createUser,jdbcType=INTEGER},
275
+      create_date = #{createDate,jdbcType=TIMESTAMP},
276
+      update_user = #{updateUser,jdbcType=INTEGER},
277
+      update_date = #{updateDate,jdbcType=TIMESTAMP},
278
+      hk_user_id = #{hkUserId,jdbcType=INTEGER},
279
+      hk_card_no = #{hkCardNo,jdbcType=VARCHAR},
280
+      face_status = #{faceStatus,jdbcType=CHAR}
281
+    where id = #{id,jdbcType=INTEGER}
282
+  </update>
283
+  <select id="selectUserApprove" resultMap="BaseResultMap" parameterType="com.community.huiju.model.TaUser">
284
+    SELECT
285
+    t.user_name,
286
+    t.login_name ,
287
+    t.gender ,
288
+    boi.id_card ,
289
+    boi.unit ,
290
+    boi. LEVEL,
291
+    room_no,
292
+    boi.create_date,
293
+    t.verify_status
294
+    FROM
295
+    ta_user t
296
+    LEFT JOIN tp_building_owner_info boi ON t.building_owner_info_id = boi.id
297
+    LEFT JOIN ta_sys_user_role sur ON t.id=sur.user_id
298
+    WHERE
299
+    andsur.role_id=1 and t.status=1 and t.verify_status=1
300
+  </select>
301
+</mapper>

+ 1
- 17
CODE/smart-community/property-api/src/main/resources/mapper/UserMapper.xml Ver fichero

@@ -1,21 +1,5 @@
1 1
 <?xml version="1.0" encoding="UTF-8"?>
2 2
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
3 3
 <mapper namespace="com.community.huiju.dao.UserMapper">
4
-    <select id="selectUserApprove" resultType="map" parameterType="map">
5
-    SELECT
6
-	t.user_name,
7
-	t.login_name ,
8
-	t.gender ,
9
-	boi.id_card ,
10
-	boi.unit ,
11
-	boi. LEVEL,
12
-	room_no,
13
-	boi.create_date,
14
-	t.verify_status
15
-    FROM
16
-        ta_user t
17
-    LEFT JOIN tp_building_owner_info boi ON t.building_owner_info_id = boi.id
18
-    LEFT JOIN ta_sys_user_role sur ON t.id=sur.user_id
19
-    WHERE sur.role_id=1  and t.status=1 and t.verify_status=1
20
-    </select>
4
+
21 5
 </mapper>