Commit ecb99dac5ae37941ea192bc040e98bac3a85dcbf

Authored by jiangjiazhi

Merge remote-tracking branch 'origin/master'

Showing 6 changed files

platform-biz-service/src/main/java/com/lyms/platform/permission/model/Users.java View file @ ecb99da
... ... @@ -22,7 +22,15 @@
22 22 private Date created;
23 23 private String remarks;
24 24 private Date lastLoginTime;
  25 + private Integer otherAccount; //第三方帐号, 1医院帐号
25 26  
  27 + public Integer getOtherAccount() {
  28 + return otherAccount;
  29 + }
  30 +
  31 + public void setOtherAccount(Integer otherAccount) {
  32 + this.otherAccount = otherAccount;
  33 + }
26 34  
27 35 private List<Roles> roles;
28 36 private Departments departmentses;
platform-biz-service/src/main/java/com/lyms/platform/permission/model/UsersQuery.java View file @ ecb99da
... ... @@ -29,6 +29,15 @@
29 29 private String keyword;
30 30 private Integer roleId;
31 31 private String foreignId;
  32 + private Integer otherAccount; //µÚÈý·½ÕʺÅ, 1Ò½ÔºÕʺÅ
  33 +
  34 + public Integer getOtherAccount() {
  35 + return otherAccount;
  36 + }
  37 +
  38 + public void setOtherAccount(Integer otherAccount) {
  39 + this.otherAccount = otherAccount;
  40 + }
32 41  
33 42 public String getForeignId() {
34 43 return foreignId;
platform-biz-service/src/main/resources/mainOrm/Users.xml View file @ ecb99da
... ... @@ -22,6 +22,7 @@
22 22 <result column="remarks" property="remarks" jdbcType="VARCHAR"/>
23 23 <result column="last_login_time" property="lastLoginTime" jdbcType="TIMESTAMP"/>
24 24 <result column="foreign_id" property="foreignId" jdbcType="VARCHAR"/>
  25 + <result column="other_account" property="otherAccount" jdbcType="INTEGER"/>
25 26 </resultMap>
26 27  
27 28  
28 29  
... ... @@ -100,12 +101,12 @@
100 101  
101 102  
102 103 <select id="getUsers" resultMap="UsersResultMap" parameterType="java.lang.Integer">
103   -select id,logincenter_id,type,org_id,dept_id,name,account,pwd,phone,publish_id,publish_name,yn,enable,modified,created,remarks,last_login_time, ks_id,foreign_id
  104 +select id,logincenter_id,type,org_id,dept_id,name,account,pwd,phone,publish_id,publish_name,yn,enable,modified,created,remarks,last_login_time, ks_id,foreign_id,other_account
104 105 from users where id = #{id,jdbcType=INTEGER}
105 106 </select>
106 107  
107 108 <select id="getUsersByLoginCenterId" resultMap="UsersResultMap" parameterType="java.lang.Integer">
108   - select id,logincenter_id,type,org_id,dept_id,name,account,pwd,phone,publish_id,publish_name,yn,enable,modified,created,remarks,last_login_time, ks_id,foreign_id
  109 + select id,logincenter_id,type,org_id,dept_id,name,account,pwd,phone,publish_id,publish_name,yn,enable,modified,created,remarks,last_login_time, ks_id,foreign_id,other_account
109 110 from users where logincenter_id = #{id,jdbcType=INTEGER} and enable =1 order by last_login_time desc
110 111 </select>
111 112  
... ... @@ -180,6 +181,9 @@
180 181 <if test="lastLoginTime != null">
181 182 and last_login_time = #{lastLoginTime,jdbcType=TIMESTAMP}
182 183 </if>
  184 + <if test="other_account != null and other_account >= 0">
  185 + and other_account = #{otherAccount,jdbcType=INTEGER}
  186 + </if>
183 187 </where>
184 188 </sql>
185 189  
... ... @@ -187,7 +191,7 @@
187 191 <select id="queryUsers" resultMap="UsersResultMap" parameterType="com.lyms.platform.permission.model.UsersQuery">
188 192 select
189 193 id,logincenter_id,type,org_id,dept_id,name,account,pwd,phone,publish_id,publish_name,yn,enable,modified,created,remarks,last_login_time,
190   - ks_id,foreign_id
  194 + ks_id,foreign_id,otherAccount
191 195 from users
192 196 <include refid="UsersCondition"/>
193 197 <include refid="orderAndLimit"/>
... ... @@ -197,7 +201,7 @@
197 201 <select id="queryUsers2" resultMap="UsersResultMap" parameterType="com.lyms.platform.permission.model.UsersQuery">
198 202 select DISTINCT u.id
199 203 id,logincenter_id,type,org_id,dept_id,name,account,pwd,phone,publish_id,publish_name,u.yn,enable,modified,created,remarks,last_login_time,
200   - ks_id,foreign_id
  204 + ks_id,foreign_id,other_account
201 205 from users u LEFT JOIN user_role_maps ur
202 206 on u.id = ur.user_id
203 207 where 1=1
platform-data-api/src/main/java/com/lyms/platform/data/service/impl/DataImportTaskServiceImpl.java View file @ ecb99da
... ... @@ -274,6 +274,8 @@
274 274 u.setOrgId(o.getId());
275 275 u.setDeptId(d.getId());
276 276 u.setKsId(d.getId());
  277 + u.setType(1);
  278 + u.setOtherAccount(1);
277 279 u.setLogincenterId(LoginUtil.aouHospitalUser(u.getAccount(), u.getPwd(), typeId, token));
278 280 usersQuery.setForeignId(u.getForeignId());
279 281 List<Users> usersList = usersService.queryUsers(usersQuery);
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/RegionController.java View file @ ecb99da
... ... @@ -88,7 +88,7 @@
88 88 region.put("id",config.getId());
89 89 region.put("regionName",config.getName());
90 90 region.put("parentId", config.getParentId());
91   - region.put("code", config.getCode());
  91 + region.put("code", config.getCode() );
92 92 list.add(region);
93 93 }
94 94 }
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/UsersController.java View file @ ecb99da
... ... @@ -742,7 +742,7 @@
742 742  
743 743  
744 744 //修改了手机号,不能修改已存在的手机号
745   - if(!phone.equals(users.getPhone())) {
  745 + if(!users.getOtherAccount().equals(1) && !phone.equals(users.getPhone())) {
746 746 //检查账户是否存在
747 747 UsersQuery usersQuery = new UsersQuery();
748 748 usersQuery.setPhone(phone);