大致完成小程序返回平台接口
This commit is contained in:
parent
df97402324
commit
52330aa54f
@ -8,6 +8,7 @@ import com.xhpc.common.core.web.controller.BaseController;
|
|||||||
import com.xhpc.common.core.web.domain.AjaxResult;
|
import com.xhpc.common.core.web.domain.AjaxResult;
|
||||||
import com.xhpc.common.log.annotation.Log;
|
import com.xhpc.common.log.annotation.Log;
|
||||||
import com.xhpc.common.log.enums.BusinessType;
|
import com.xhpc.common.log.enums.BusinessType;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
@ -41,6 +42,13 @@ public class XhpcMessageBoardApiController extends BaseController {
|
|||||||
return AjaxResult.success();
|
return AjaxResult.success();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户查看所发送的聊天记录
|
||||||
|
*
|
||||||
|
* @author WH
|
||||||
|
* @date 2022/1/13 18:15
|
||||||
|
* @since version-1.0
|
||||||
|
*/
|
||||||
@GetMapping("/user/message")
|
@GetMapping("/user/message")
|
||||||
public AjaxResult queryUserMessage(UserQueryCondition userQueryCondition) {
|
public AjaxResult queryUserMessage(UserQueryCondition userQueryCondition) {
|
||||||
|
|
||||||
@ -48,4 +56,18 @@ public class XhpcMessageBoardApiController extends BaseController {
|
|||||||
return AjaxResult.success(queryUserMassageResponse);
|
return AjaxResult.success(queryUserMassageResponse);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取用户对应的租户的头像
|
||||||
|
*
|
||||||
|
* @author WH
|
||||||
|
* @date 2022/1/13 18:19
|
||||||
|
* @since version-1.0
|
||||||
|
*/
|
||||||
|
@GetMapping("/platform-icon")
|
||||||
|
public AjaxResult returnPlatformAvatar(@Param("tenantId") String tenantId, @Param("tenantType") Integer tenantType) {
|
||||||
|
|
||||||
|
String avatarAddress = xhpcMessageBoardService.returnPlatformAvatar(tenantId, tenantType);
|
||||||
|
return AjaxResult.success(avatarAddress);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -45,5 +45,16 @@ public interface XhpcMessageBoardService {
|
|||||||
*/
|
*/
|
||||||
QueryUserMassageResponse queryUserMessage(UserQueryCondition userQueryCondition);
|
QueryUserMassageResponse queryUserMessage(UserQueryCondition userQueryCondition);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据租户id和租户类型查询指定的租户头像
|
||||||
|
*
|
||||||
|
* @param tenantId 租户id
|
||||||
|
* @param tenantType 租户类型
|
||||||
|
* @return 头像地址
|
||||||
|
* @author WH
|
||||||
|
* @date 2022/1/13 18:30
|
||||||
|
* @since version-1.0
|
||||||
|
*/
|
||||||
|
String returnPlatformAvatar(String tenantId, Integer tenantType);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -225,4 +225,20 @@ public class XhpcMessageBoardServiceImpl implements XhpcMessageBoardService {
|
|||||||
return response;
|
return response;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据租户id和租户类型查询指定的租户头像
|
||||||
|
*
|
||||||
|
* @param tenantId 租户id
|
||||||
|
* @param tenantType 租户类型
|
||||||
|
* @return 头像地址
|
||||||
|
* @author WH
|
||||||
|
* @date 2022/1/13 18:30
|
||||||
|
* @since version-1.0
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public String returnPlatformAvatar(String tenantId, Integer tenantType) {
|
||||||
|
|
||||||
|
return "https://xhpc-bucket1.oss-cn-hangzhou.aliyuncs.com/avatar/logo.png";
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user