Compare commits
6 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6aaf91a755 | ||
|
|
f1ac7d6886 | ||
|
|
2f07f9eb66 | ||
|
|
919cd47623 | ||
|
|
eb1c20b033 | ||
|
|
c1559e96be |
25
.gitea/workflows/mvn-deploy.yaml
Normal file
25
.gitea/workflows/mvn-deploy.yaml
Normal file
@@ -0,0 +1,25 @@
|
||||
## 工作流触发时机
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- '*'
|
||||
|
||||
jobs:
|
||||
|
||||
## 任务名称
|
||||
local-deploy:
|
||||
|
||||
## 任务执行的服务器
|
||||
runs-on: tiesheng-local
|
||||
|
||||
## 任务步骤
|
||||
steps:
|
||||
|
||||
## 检出代码(固定配置)
|
||||
- name: Check out repository code
|
||||
uses: https://git.tieshengkeji.com/actions/checkout@v4
|
||||
|
||||
## maven打包
|
||||
- name: Maven deploy
|
||||
run: |
|
||||
mvn deploy
|
||||
@@ -1,3 +1,8 @@
|
||||
## 2.0.12
|
||||
|
||||
- 调整OkHttp日志
|
||||
|
||||
|
||||
## 2.0.0.rc46
|
||||
|
||||
现在导入导出都接入底层流程,无需新增接口,只需要实现接口即可。
|
||||
|
||||
25
pom.xml
25
pom.xml
@@ -6,7 +6,7 @@
|
||||
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-parent</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
<packaging>pom</packaging>
|
||||
<name>springboot-parent</name>
|
||||
<description>杭州铁晟科技有限公司基础依赖</description>
|
||||
@@ -58,49 +58,49 @@
|
||||
<dependency>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-database</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-login</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-web</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-util</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-platform</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-message</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-role</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-annotation</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -125,6 +125,13 @@
|
||||
</pluginRepository>
|
||||
</pluginRepositories>
|
||||
|
||||
<distributionManagement>
|
||||
<repository>
|
||||
<id>gitea</id>
|
||||
<url>https://git.tieshengkeji.com/api/packages/tieshengkeji/maven</url>
|
||||
</repository>
|
||||
</distributionManagement>
|
||||
|
||||
<build>
|
||||
<pluginManagement>
|
||||
<plugins>
|
||||
|
||||
@@ -6,11 +6,11 @@
|
||||
<parent>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-parent</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>springboot-ademo</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>8</maven.compiler.source>
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<parent>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-parent</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>springboot-annotation</artifactId>
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<parent>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-parent</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>springboot-database</artifactId>
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<parent>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-parent</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>springboot-login</artifactId>
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<parent>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-parent</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>springboot-message</artifactId>
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<parent>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-parent</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>springboot-platform</artifactId>
|
||||
|
||||
@@ -247,7 +247,7 @@ public class PlatformDingConfig {
|
||||
JSONObject object = new JSONObject();
|
||||
object.put("dept_id", deptId);
|
||||
object.put("cursor", cursor);
|
||||
object.put("size", 200);
|
||||
object.put("size", 100);
|
||||
|
||||
return doRequest(service, "https://oapi.dingtalk.com/topapi/v2/user/list",
|
||||
object, new TypeReference<DingResponse<DingUserListVo>>() {
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<parent>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-parent</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>springboot-role</artifactId>
|
||||
|
||||
@@ -49,6 +49,7 @@ public class CommRoleController {
|
||||
.in("id", list)
|
||||
.eq(CoreRoleServer.IS_DELETED, 0)
|
||||
.eq("is_open", 1)
|
||||
.orderByAsc("sort")
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -6,6 +6,7 @@ import com.tiesheng.annotation.role.RoleAuthority;
|
||||
import com.tiesheng.role.pojos.dao.CoreRoleAuthority;
|
||||
import com.tiesheng.role.pojos.dao.CoreRoleServer;
|
||||
import com.tiesheng.role.pojos.dto.MenuListDTO;
|
||||
import com.tiesheng.role.pojos.dto.ServerListDTO;
|
||||
import com.tiesheng.role.pojos.vo.ServiceMenuVO;
|
||||
import com.tiesheng.role.service.CoreRoleService;
|
||||
import com.tiesheng.util.pojos.ApiResp;
|
||||
@@ -29,10 +30,11 @@ public class RoleServerController {
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/server/list")
|
||||
public ApiResp<List<CoreRoleServer>> list() {
|
||||
public ApiResp<List<CoreRoleServer>> list(ServerListDTO dto) {
|
||||
return ApiResp.respOK(coreRoleService.getServerMapper().selectList(new QueryWrapper<CoreRoleServer>()
|
||||
.eq(CoreRoleServer.IS_DELETED, 0)
|
||||
.eq("is_open", 1)
|
||||
.eq(StrUtil.isNotEmpty(dto.getIsOpen()), "is_open", dto.getIsOpen())
|
||||
.orderByAsc("sort")
|
||||
));
|
||||
}
|
||||
|
||||
|
||||
@@ -30,6 +30,12 @@ public class CoreRoleUser extends DaoBase {
|
||||
@TableField(value = "type_id")
|
||||
private String typeId;
|
||||
|
||||
/**
|
||||
* 说明
|
||||
*/
|
||||
@TableField(value = "remark")
|
||||
private String remark;
|
||||
|
||||
/**
|
||||
* 过期时间,无则不过期
|
||||
*/
|
||||
@@ -108,6 +114,14 @@ public class CoreRoleUser extends DaoBase {
|
||||
this.typeId = typeId;
|
||||
}
|
||||
|
||||
public String getRemark() {
|
||||
return remark;
|
||||
}
|
||||
|
||||
public void setRemark(String remark) {
|
||||
this.remark = remark;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取过期时间,无则不过期
|
||||
*
|
||||
@@ -179,4 +193,4 @@ public class CoreRoleUser extends DaoBase {
|
||||
public void setExt3(String ext3) {
|
||||
this.ext3 = ext3;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
package com.tiesheng.role.pojos.dto;
|
||||
|
||||
public class ServerListDTO {
|
||||
|
||||
private String isOpen;
|
||||
|
||||
|
||||
public String getIsOpen() {
|
||||
return isOpen;
|
||||
}
|
||||
|
||||
public void setIsOpen(String isOpen) {
|
||||
this.isOpen = isOpen;
|
||||
}
|
||||
}
|
||||
@@ -108,4 +108,7 @@ alter table core_role_authority
|
||||
alter table core_role_group_rx
|
||||
add type varchar(10) null comment '关联类型:dep-依赖,bind-绑定';
|
||||
|
||||
alter table core_role_user
|
||||
add remark varchar(500) null comment '说明' after type_id;
|
||||
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
<result column="user_id" jdbcType="VARCHAR" property="userId" />
|
||||
<result column="type" jdbcType="VARCHAR" property="type" />
|
||||
<result column="type_id" jdbcType="VARCHAR" property="typeId" />
|
||||
<result column="remark" jdbcType="VARCHAR" property="remark" />
|
||||
<result column="expire_time" jdbcType="TIMESTAMP" property="expireTime" />
|
||||
<result column="ext1" jdbcType="VARCHAR" property="ext1" />
|
||||
<result column="ext2" jdbcType="VARCHAR" property="ext2" />
|
||||
@@ -18,7 +19,7 @@
|
||||
</resultMap>
|
||||
<sql id="Base_Column_List">
|
||||
<!--@mbg.generated-->
|
||||
id, create_time, update_time, is_deleted, user_id, `type`, type_id, expire_time,
|
||||
id, create_time, update_time, is_deleted, user_id, `type`, type_id, remark, expire_time,
|
||||
ext1, ext2, ext3
|
||||
</sql>
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<parent>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-parent</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>springboot-util</artifactId>
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<parent>
|
||||
<groupId>com.tiesheng.springboot-parent</groupId>
|
||||
<artifactId>springboot-parent</artifactId>
|
||||
<version>2.0.8</version>
|
||||
<version>2.0.12</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>springboot-web</artifactId>
|
||||
|
||||
@@ -2,8 +2,8 @@ package com.tiesheng.web.service;
|
||||
|
||||
import cn.hutool.core.thread.ThreadUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.tiesheng.util.service.http.OkHttpUtil;
|
||||
import com.tiesheng.web.mapper.CoreLogApiMapper;
|
||||
import com.tiesheng.web.pojos.dao.CoreLogApi;
|
||||
import okhttp3.*;
|
||||
@@ -30,7 +30,7 @@ public class OkHttpLogInterceptor implements Interceptor {
|
||||
logApi.setUrl(request.url().toString());
|
||||
logApi.setContent(requestBody2String(request));
|
||||
|
||||
Response response;
|
||||
Response response = null;
|
||||
try {
|
||||
response = chain.proceed(request);
|
||||
logApi.setResult(response.code());
|
||||
@@ -46,20 +46,11 @@ public class OkHttpLogInterceptor implements Interceptor {
|
||||
}
|
||||
}
|
||||
} catch (Exception e) {
|
||||
|
||||
JSONObject object = new JSONObject();
|
||||
object.put("code", -1);
|
||||
object.put("message", e.getMessage());
|
||||
object.put("message", JSON.toJSONString(e));
|
||||
object.put("exception", e);
|
||||
logApi.setRespBody(object.toJSONString());
|
||||
|
||||
response = new Response.Builder()
|
||||
.request(request)
|
||||
.protocol(Protocol.HTTP_1_1)
|
||||
.code(logApi.getResult())
|
||||
.message(e.getMessage())
|
||||
.body(OkHttpUtil.ofJsonResponse(logApi.getRespBody()))
|
||||
.build();
|
||||
}
|
||||
|
||||
ThreadUtil.execute(() -> coreLogApiMapper.insert(logApi));
|
||||
|
||||
Reference in New Issue
Block a user