Browse Source

正式版

dev
jihaipeng 3 weeks ago
parent
commit
9406e3c182
  1. 4
      lottery-system/lottery-pojo/src/main/java/com/lottery/entity/JwcodeTable.java
  2. 3
      lottery-system/lottery-service/src/main/java/com/lottery/interceptor/AuthInterceptor.java
  3. 2
      lottery-system/lottery-service/src/main/resources/application-prod.yml
  4. 2
      lottery-system/lottery-service/src/main/resources/application.yml

4
lottery-system/lottery-pojo/src/main/java/com/lottery/entity/JwcodeTable.java

@ -1,5 +1,7 @@
package com.lottery.entity; package com.lottery.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName; import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor; import lombok.AllArgsConstructor;
import lombok.Data; import lombok.Data;
@ -21,6 +23,8 @@ import java.time.LocalDateTime;
@AllArgsConstructor @AllArgsConstructor
@TableName("jwcode_table") @TableName("jwcode_table")
public class JwcodeTable { public class JwcodeTable {
@TableId(value = "id", type = IdType.AUTO) // 明确指定主键字段和生成策略
private Long id;
private String jwcode; private String jwcode;
private LocalDateTime createTime; private LocalDateTime createTime;
} }

3
lottery-system/lottery-service/src/main/java/com/lottery/interceptor/AuthInterceptor.java

@ -40,6 +40,9 @@ public class AuthInterceptor implements HandlerInterceptor {
if("/api/user/list".equals(request.getRequestURI())) { if("/api/user/list".equals(request.getRequestURI())) {
return true; return true;
} }
if("/admin/user/logout".equals(request.getRequestURI())) {
return true;
}
// if("/admin/win/list".equals(request.getRequestURI())) { // if("/admin/win/list".equals(request.getRequestURI())) {
// return true; // return true;
// } // }

2
lottery-system/lottery-service/src/main/resources/application-prod.yml

@ -5,7 +5,7 @@ spring:
# ========== 数据源配置 (MySQL) ========== # ========== 数据源配置 (MySQL) ==========
datasource: datasource:
url: jdbc:mysql://18.143.76.3:3306/activty?useSSL=false&allowPublicKeyRetrieval=true&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai
url: jdbc:mysql://localhost:3306/activty?useSSL=false&allowPublicKeyRetrieval=true&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai
username: activty username: activty
password: LnAcwpp5ayps5xnc password: LnAcwpp5ayps5xnc
driver-class-name: com.mysql.cj.jdbc.Driver driver-class-name: com.mysql.cj.jdbc.Driver

2
lottery-system/lottery-service/src/main/resources/application.yml

@ -1,7 +1,7 @@
spring: spring:
# 基础配置 (所有环境通用) # 基础配置 (所有环境通用)
profiles: profiles:
active: dev
active: prod
# Jackson 基础配置 # Jackson 基础配置
jackson: jackson:

Loading…
Cancel
Save