Browse Source

联合丽格

huangzhiguo 2 years ago
parent
commit
c7cc831a44

+ 18 - 6
src/main/java/com/caimei365/user/service/impl/ClubServiceImpl.java

@@ -279,13 +279,19 @@ public class ClubServiceImpl implements ClubService {
     public ResponseJson<ClubUpdateDto> updateOrganizeClubinfo(ClubUpdateDto club) {
         // 参数校验
         if (club.getUserId() == null) {
-            return ResponseJson.error("参数异常:用户Id不能为空!", null);
+            return ResponseJson.error(-1,"参数异常:用户Id不能为空!", null);
         }
         if (club.getClubId() == null) {
-            return ResponseJson.error("参数异常:机构Id不能为空!", null);
+            return ResponseJson.error(-1,"参数异常:机构Id不能为空!", null);
         }
         if (club.getLinkMan() == null) {
-            return ResponseJson.error("参数异常:联系人不能为空!", null);
+            return ResponseJson.error(-1,"参数异常:联系人不能为空!", null);
+        }
+        if (StringUtils.isBlank(club.getMedicalPracticeLicense()) || StringUtils.isEmpty(club.getMedicalPracticeLicense())) {
+            return ResponseJson.error(-1,"请上传营业执照",null);
+        }
+        if (StringUtils.isBlank(club.getBusinessLicense()) || StringUtils.isEmpty(club.getBusinessLicense())) {
+            return ResponseJson.error(-1,"请上传医疗职业许可证",null);
         }
         UserPo user = new UserPo();
         // 用户Id
@@ -318,13 +324,19 @@ public class ClubServiceImpl implements ClubService {
     public ResponseJson<ClubUpdateDto> organizeClubinfo(ClubUpdateDto club) {
         // 参数校验
         if (club.getUserId() == null) {
-            return ResponseJson.error("参数异常:用户Id不能为空!", null);
+            return ResponseJson.error(-1,"参数异常:用户Id不能为空!", null);
         }
         if (club.getClubId() == null) {
-            return ResponseJson.error("参数异常:机构Id不能为空!", null);
+            return ResponseJson.error(-1,"参数异常:机构Id不能为空!", null);
         }
         if (club.getLinkMan() == null) {
-            return ResponseJson.error("参数异常:联系人不能为空!", null);
+            return ResponseJson.error(-1,"参数异常:联系人不能为空!", null);
+        }
+        if (StringUtils.isBlank(club.getMedicalPracticeLicense()) || StringUtils.isEmpty(club.getMedicalPracticeLicense())) {
+            return ResponseJson.error(-1,"请上传营业执照",null);
+        }
+        if (StringUtils.isBlank(club.getBusinessLicense()) || StringUtils.isEmpty(club.getBusinessLicense())) {
+            return ResponseJson.error(-1,"请上传医疗职业许可证",null);
         }
         UserPo user = new UserPo();
         // 用户Id

+ 2 - 0
src/main/java/com/caimei365/user/service/impl/LoginServiceImpl.java

@@ -197,6 +197,7 @@ public class LoginServiceImpl implements LoginService {
                 operationVo.setStatus(2);
                 operationVo.setUnionId(unionId);
                 operationVo.setBindTime(new Date());
+                operationVo.setAddTime(new Date());
                 operationVo.setDelFlag(0);
                 loginMapper.insertOperation(operationVo);
                 log.info("operationVo***"+operationVo);
@@ -370,6 +371,7 @@ public class LoginServiceImpl implements LoginService {
                         operationVo.setStatus(2);
                         operationVo.setUnionId(unionId);
                         operationVo.setBindTime(new Date());
+                        operationVo.setAddTime(new Date());
                         operationVo.setDelFlag(0);
                         loginMapper.insertOperation(operationVo);
                         log.info("operationVo***"+operationVo);

+ 0 - 3
src/main/java/com/caimei365/user/service/impl/RegisterServiceImpl.java

@@ -417,9 +417,6 @@ public class RegisterServiceImpl implements RegisterService {
         if (StringUtils.isBlank(organizeRegisterDto.getMedicalPracticeLicense()) || StringUtils.isEmpty(organizeRegisterDto.getMedicalPracticeLicense())) {
             return ResponseJson.error("请上传营业执照");
         }
-        if (StringUtils.isBlank(organizeRegisterDto.getShopPhoto()) || StringUtils.isEmpty(organizeRegisterDto.getShopPhoto())) {
-            return ResponseJson.error("请上传门头照");
-        }
         if (StringUtils.isBlank(organizeRegisterDto.getBusinessLicense()) || StringUtils.isEmpty(organizeRegisterDto.getBusinessLicense())) {
             return ResponseJson.error("请上传医疗职业许可证");
         }

+ 2 - 2
src/main/resources/mapper/LoginMapper.xml

@@ -137,8 +137,8 @@
         select id from cm_mall_operation_user where mobile = #{mobileOrEmail} and delFlag = 0 and userOrganizeID = 4 limit 1
     </select>
     <insert id="insertOperation">
-        INSERT INTO cm_mall_operation_user (userOrganizeID, userType, userID, clubID, mobile, linkName, STATUS, unionId, bindTime, delFlag)
-        values(#{organizeId}, #{userType}, #{userId}, #{clubId}, #{mobile}, #{linkName}, #{status}, #{unionId}, #{bindTime}, #{delFlag})
+        INSERT INTO cm_mall_operation_user (userOrganizeID, userType, userID, clubID, mobile, linkName, STATUS, unionId, bindTime, addTime, delFlag)
+        values(#{organizeId}, #{userType}, #{userId}, #{clubId}, #{mobile}, #{linkName}, #{status}, #{unionId}, #{bindTime}, #{addtime}, #{delFlag})
     </insert>
     <select id="getLoginUserByMobile" resultType="com.caimei365.user.model.vo.UserLoginVo">
         select u.userID             as userId,