Browse Source

Merge branch 'feature/0721-tenant' into develop

haonan 1 year ago
parent
commit
732d05c2d9

+ 1 - 1
cooleshow-user/user-admin/src/main/java/com/yonge/cooleshow/admin/controller/TenantAlbumController.java

@@ -235,7 +235,7 @@ public class TenantAlbumController {
     @PreAuthorize("@pcs.hasPermissions('tenantAlbum/updateStatus')")
     public HttpResponseResult<Boolean> updateStatus(@Validated @RequestBody TenantAlbumVo.UpdateStatus status) {
         tenantAlbumService.lambdaUpdate()
-                .set(TenantAlbum::getStatus, !status.getStatus())
+                .set(TenantAlbum::getStatus, status.getStatus())
                 .eq(TenantAlbum::getId, status.getId())
                 .update();
         return HttpResponseResult.succeed();

+ 5 - 1
cooleshow-user/user-biz/src/main/java/com/yonge/cooleshow/biz/dal/service/impl/StudentServiceImpl.java

@@ -686,7 +686,11 @@ public class StudentServiceImpl extends ServiceImpl<StudentDao, Student> impleme
             sysUser = JSON.parseObject(JSON.toJSONString(studentInfo),
                     com.yonge.cooleshow.biz.dal.entity.SysUser.class);
             sysUser.setPhone(studentInfo.getPhone());
-            sysUser.setAvatar(sysConfigService.findConfigValue(SysConfigConstant.DEFAULT_HEARD));
+            if (StringUtils.isEmpty(studentInfo.getAvatar())) {
+                sysUser.setAvatar(sysConfigService.findConfigValue(SysConfigConstant.DEFAULT_HEARD));
+            } else {
+                sysUser.setAvatar(studentInfo.getAvatar());
+            }
             sysUser.setGender(studentInfo.getGender());
             sysUser.setUserType("STUDENT");
             sysUser.setBirthdate(studentInfo.getBirthdate());

+ 1 - 1
cooleshow-user/user-biz/src/main/java/com/yonge/cooleshow/biz/dal/service/impl/UserTenantAlbumRecordServiceImpl.java

@@ -312,7 +312,7 @@ public class UserTenantAlbumRecordServiceImpl extends ServiceImpl<UserTenantAlbu
 
 
         //查询对应专辑的详情
-        List<TenantAlbum> list = tenantAlbumService.lambdaQuery().eq(TenantAlbum::getStatus, false).eq(TenantAlbum::getId, tenantAlbumId).list();
+        List<TenantAlbum> list = tenantAlbumService.lambdaQuery().eq(TenantAlbum::getStatus, true).eq(TenantAlbum::getId, tenantAlbumId).list();
         if (CollectionUtils.isEmpty(list)){
             throw new BizException("机构专辑不存在");
         }