增加 Tenant MQ 的支持

This commit is contained in:
YunaiV
2021-12-06 01:32:41 +08:00
parent a231582637
commit 1ce2c09f47
12 changed files with 95 additions and 31 deletions

View File

@ -1,7 +1,7 @@
### 请求 /login 接口 => 成功
POST {{baseUrl}}/login
Content-Type: application/json
tenant-id: 0
tenant-id: 1
{
"username": "admin",
@ -13,10 +13,13 @@ tenant-id: 0
### 请求 /get-permission-info 接口 => 成功
GET {{baseUrl}}/get-permission-info
Authorization: Bearer {{token}}
tenant-id: 1
### 请求 /list-menus 接口 => 成功
GET {{baseUrl}}/list-menus
Authorization: Bearer {{token}}
#Authorization: Bearer 0d161f69c9ac4c7f836e1b850715a7b0
tenant-id: 1
### 请求 /druid/xxx 接口 => 失败 TODO 临时测试
GET http://127.0.0.1:8080/druid/123

View File

@ -21,7 +21,7 @@ public class SysTenantController {
@ApiImplicitParam(name = "name", value = "租户名", required = true, example = "芋道源码", dataTypeClass = Long.class)
public CommonResult<Long> getTenantIdByName(@RequestParam("name") String name) {
if (Objects.equals("芋道源码", name)) {
return CommonResult.success(0L);
return CommonResult.success(1L);
}
return CommonResult.success(null);
}

View File

@ -22,7 +22,7 @@ spring:
# MyBatis Plus 的配置项
mybatis-plus:
# 在 mybatis-config/mybatis-config.xml 中设置
# 在 mybatis-config/mybatis-config.xml 中设置 TODO jason看看有没其它解决方案
# configuration:
# map-underscore-to-camel-case: true # 虽然默认为 true ,但是还是显示去指定下。
# log-impl: org.apache.ibatis.logging.stdout.StdOutImpl # 打印日志

View File

@ -6,6 +6,7 @@
<settings>
<setting name="lazyLoadingEnabled" value="false" />
<setting name="mapUnderscoreToCamelCase" value="true"/>
<setting name="logImpl" value="org.apache.ibatis.logging.stdout.StdOutImpl"/>
</settings>
<typeAliases>
<typeAlias type="org.activiti.engine.impl.persistence.ByteArrayRefTypeHandler" alias="ByteArrayRefTypeHandler"/>