文件记录表新增app_id字段
This commit is contained in:
@@ -1,5 +1,7 @@
|
|||||||
package com.gxwebsoft.common.system.controller;
|
package com.gxwebsoft.common.system.controller;
|
||||||
|
|
||||||
|
import cn.hutool.core.date.DateField;
|
||||||
|
import cn.hutool.core.date.DateTime;
|
||||||
import cn.hutool.core.date.DateUtil;
|
import cn.hutool.core.date.DateUtil;
|
||||||
import cn.hutool.core.util.StrUtil;
|
import cn.hutool.core.util.StrUtil;
|
||||||
import com.alibaba.fastjson.JSONObject;
|
import com.alibaba.fastjson.JSONObject;
|
||||||
@@ -184,6 +186,8 @@ public class MainController extends BaseController {
|
|||||||
menu.setMenuType(0);
|
menu.setMenuType(0);
|
||||||
list.add(menu);
|
list.add(menu);
|
||||||
tenant.setMenu(list);
|
tenant.setMenu(list);
|
||||||
|
// 服务器时间
|
||||||
|
tenant.setDate(serverTime());
|
||||||
// 授权信息
|
// 授权信息
|
||||||
HashMap<String, Object> config = new HashMap<>();
|
HashMap<String, Object> config = new HashMap<>();
|
||||||
config.put("LICENSE_CODE", "dk9mcwJyetRWQlxWRiojIzJCLi8mcQ5Wa4ojI0NWZqJWd6ICZpJCL0kjNwl1NnhENahnIvl2cyVmdiwiIiATMuEjI6IibQf0NW==");
|
config.put("LICENSE_CODE", "dk9mcwJyetRWQlxWRiojIzJCLi8mcQ5Wa4ojI0NWZqJWd6ICZpJCL0kjNwl1NnhENahnIvl2cyVmdiwiIiATMuEjI6IibQf0NW==");
|
||||||
@@ -972,6 +976,34 @@ public class MainController extends BaseController {
|
|||||||
return success("注册成功", tenant.getTenantId());
|
return success("注册成功", tenant.getTenantId());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取服务器时间
|
||||||
|
* @return String
|
||||||
|
*/
|
||||||
|
@ApiOperation("获取服务器时间")
|
||||||
|
@GetMapping("/serverTime")
|
||||||
|
public ApiResult<?> serverTime(){
|
||||||
|
HashMap<String, Object> map = new HashMap<>();
|
||||||
|
// 今天日期
|
||||||
|
DateTime date = DateUtil.date();
|
||||||
|
String today= DateUtil.today();
|
||||||
|
// 明天日期
|
||||||
|
final DateTime dateTime = DateUtil.tomorrow();
|
||||||
|
String tomorrow = DateUtil.format(dateTime, "yyyy-MM-dd");
|
||||||
|
// 今天星期几
|
||||||
|
final int week = DateUtil.thisDayOfWeek();;
|
||||||
|
final DateTime nextWeek = DateUtil.nextWeek();
|
||||||
|
|
||||||
|
map.put("now",DateUtil.now());
|
||||||
|
map.put("today",today);
|
||||||
|
map.put("tomorrow",tomorrow);
|
||||||
|
map.put("week",week);
|
||||||
|
map.put("minDate",DateUtil.offset(date, DateField.DAY_OF_WEEK, -7 ));
|
||||||
|
map.put("maxDate",DateUtil.offset(date, DateField.DAY_OF_WEEK, 7 ));
|
||||||
|
map.put("nextWeek",nextWeek);
|
||||||
|
return success(map);
|
||||||
|
}
|
||||||
|
|
||||||
// 缓存租户信息
|
// 缓存租户信息
|
||||||
private void saveRedis(Tenant tenant) {
|
private void saveRedis(Tenant tenant) {
|
||||||
String key = "tenant:" + tenant.getTenantId();
|
String key = "tenant:" + tenant.getTenantId();
|
||||||
|
|||||||
@@ -42,6 +42,9 @@ public class FileRecord implements Serializable {
|
|||||||
@ApiModelProperty("备注")
|
@ApiModelProperty("备注")
|
||||||
private String comments;
|
private String comments;
|
||||||
|
|
||||||
|
@ApiModelProperty("应用ID")
|
||||||
|
private Integer appId;
|
||||||
|
|
||||||
@ApiModelProperty("创建人")
|
@ApiModelProperty("创建人")
|
||||||
private Integer createUserId;
|
private Integer createUserId;
|
||||||
|
|
||||||
|
|||||||
@@ -52,14 +52,6 @@ public class Tenant implements Serializable {
|
|||||||
@ApiModelProperty(value = "修改时间")
|
@ApiModelProperty(value = "修改时间")
|
||||||
private Date updateTime;
|
private Date updateTime;
|
||||||
|
|
||||||
// @ApiModelProperty(value = "游客")
|
|
||||||
// @TableField(exist = false)
|
|
||||||
// private String username;
|
|
||||||
|
|
||||||
// @ApiModelProperty(value = "游客身份")
|
|
||||||
// @TableField(exist = false)
|
|
||||||
// private String token;
|
|
||||||
|
|
||||||
@ApiModelProperty(value = "菜单信息")
|
@ApiModelProperty(value = "菜单信息")
|
||||||
@TableField(exist = false)
|
@TableField(exist = false)
|
||||||
private List<Menu> menu;
|
private List<Menu> menu;
|
||||||
@@ -80,4 +72,8 @@ public class Tenant implements Serializable {
|
|||||||
@TableField(exist = false)
|
@TableField(exist = false)
|
||||||
private Object config;
|
private Object config;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "服务器时间")
|
||||||
|
@TableField(exist = false)
|
||||||
|
private Object date;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -20,6 +20,9 @@
|
|||||||
<if test="param.path != null">
|
<if test="param.path != null">
|
||||||
AND a.path LIKE CONCAT('%', #{param.path}, '%')
|
AND a.path LIKE CONCAT('%', #{param.path}, '%')
|
||||||
</if>
|
</if>
|
||||||
|
<if test="param.appId != null">
|
||||||
|
AND a.app_id = #{param.appId}
|
||||||
|
</if>
|
||||||
<if test="param.createUserId != null">
|
<if test="param.createUserId != null">
|
||||||
AND a.create_user_id = #{param.createUserId}
|
AND a.create_user_id = #{param.createUserId}
|
||||||
</if>
|
</if>
|
||||||
|
|||||||
@@ -38,6 +38,10 @@ public class FileRecordParam extends BaseParam {
|
|||||||
@ApiModelProperty("文件存储路径")
|
@ApiModelProperty("文件存储路径")
|
||||||
private String path;
|
private String path;
|
||||||
|
|
||||||
|
@QueryField(type = QueryType.EQ)
|
||||||
|
@ApiModelProperty("应用ID")
|
||||||
|
private Integer appId;
|
||||||
|
|
||||||
@QueryField(type = QueryType.EQ)
|
@QueryField(type = QueryType.EQ)
|
||||||
@ApiModelProperty("创建人")
|
@ApiModelProperty("创建人")
|
||||||
private Integer createUserId;
|
private Integer createUserId;
|
||||||
|
|||||||
Reference in New Issue
Block a user