Forráskód Böngészése

1.update account-service
2.update tnb service

reghao 8 hónapja
szülő
commit
03a4637184
77 módosított fájl, 310 hozzáadás és 2617 törlés
  1. 2 1
      account/account-api/src/main/java/cn/reghao/tnb/account/api/dto/AccountInfo.java
  2. 0 5
      account/account-service/pom.xml
  3. 0 11
      account/account-service/src/main/java/cn/reghao/tnb/account/app/aop/AuthException.java
  4. 0 15
      account/account-service/src/main/java/cn/reghao/tnb/account/app/aop/AuthUser.java
  5. 0 67
      account/account-service/src/main/java/cn/reghao/tnb/account/app/aop/AuthUserAspect.java
  6. 1 2
      account/account-service/src/main/java/cn/reghao/tnb/account/app/config/SpringDocConfig.java
  7. 2 9
      account/account-service/src/main/java/cn/reghao/tnb/account/app/config/web/AccountInterceptor.java
  8. 2 3
      account/account-service/src/main/java/cn/reghao/tnb/account/app/config/web/exception/ControllerExceptionHandler.java
  9. 37 0
      account/account-service/src/main/java/cn/reghao/tnb/account/app/controller/AccountAdminController.java
  10. 1 1
      account/account-service/src/main/java/cn/reghao/tnb/account/app/controller/AccountAuthController.java
  11. 1 1
      account/account-service/src/main/java/cn/reghao/tnb/account/app/controller/AccountProfileController.java
  12. 5 5
      account/account-service/src/main/java/cn/reghao/tnb/account/app/controller/AccountRecordController.java
  13. 1 2
      account/account-service/src/main/java/cn/reghao/tnb/account/app/controller/AccountResourceController.java
  14. 1 8
      account/account-service/src/main/java/cn/reghao/tnb/account/app/db/mapper/UserAccountMapper.java
  15. 1 0
      account/account-service/src/main/java/cn/reghao/tnb/account/app/db/mapper/UserAccountRoleMapper.java
  16. 0 15
      account/account-service/src/main/java/cn/reghao/tnb/account/app/db/query/UserAuthQuery.java
  17. 0 34
      account/account-service/src/main/java/cn/reghao/tnb/account/app/db/query/impl/UserAuthQueryImpl.java
  18. 27 46
      account/account-service/src/main/java/cn/reghao/tnb/account/app/db/repository/AccountRepository.java
  19. 6 10
      account/account-service/src/main/java/cn/reghao/tnb/account/app/model/constant/LoginPlat.java
  20. 4 4
      account/account-service/src/main/java/cn/reghao/tnb/account/app/model/constant/LoginType.java
  21. 0 18
      account/account-service/src/main/java/cn/reghao/tnb/account/app/model/dto/AccountDetail.java
  22. 3 3
      account/account-service/src/main/java/cn/reghao/tnb/account/app/model/dto/AccountLoginDto.java
  23. 1 1
      account/account-service/src/main/java/cn/reghao/tnb/account/app/model/dto/AccountLoginRet.java
  24. 1 1
      account/account-service/src/main/java/cn/reghao/tnb/account/app/model/po/LoginAttempts.java
  25. 81 4
      account/account-service/src/main/java/cn/reghao/tnb/account/app/model/po/UserAccount.java
  26. 1 0
      account/account-service/src/main/java/cn/reghao/tnb/account/app/model/po/UserAccountRole.java
  27. 1 1
      account/account-service/src/main/java/cn/reghao/tnb/account/app/model/po/UserAuthority.java
  28. 0 22
      account/account-service/src/main/java/cn/reghao/tnb/account/app/model/vo/AccessLog.java
  29. 0 17
      account/account-service/src/main/java/cn/reghao/tnb/account/app/model/vo/SiteOption.java
  30. 0 16
      account/account-service/src/main/java/cn/reghao/tnb/account/app/model/vo/SystemInfo.java
  31. 0 118
      account/account-service/src/main/java/cn/reghao/tnb/account/app/model/vo/UserDetail.java
  32. 5 6
      account/account-service/src/main/java/cn/reghao/tnb/account/app/rpc/AccountQueryImpl.java
  33. 1 1
      account/account-service/src/main/java/cn/reghao/tnb/account/app/security/OAuth2AuthorizationConfig.java
  34. 3 3
      account/account-service/src/main/java/cn/reghao/tnb/account/app/security/WebSecurityConfig.java
  35. 2 2
      account/account-service/src/main/java/cn/reghao/tnb/account/app/security/filter/LoginRedirectFilter.java
  36. 1 1
      account/account-service/src/main/java/cn/reghao/tnb/account/app/security/form/AccountAuthFilter.java
  37. 1 1
      account/account-service/src/main/java/cn/reghao/tnb/account/app/security/form/AccountAuthProvider.java
  38. 2 2
      account/account-service/src/main/java/cn/reghao/tnb/account/app/security/form/AccountAuthToken.java
  39. 1 1
      account/account-service/src/main/java/cn/reghao/tnb/account/app/security/form/ThirdPartyAuthFilter.java
  40. 15 14
      account/account-service/src/main/java/cn/reghao/tnb/account/app/security/handler/AuthSuccessHandlerImpl.java
  41. 5 5
      account/account-service/src/main/java/cn/reghao/tnb/account/app/service/AccountProfileService.java
  42. 2 3
      account/account-service/src/main/java/cn/reghao/tnb/account/app/service/AccountRegistryService.java
  43. 1 1
      account/account-service/src/main/java/cn/reghao/tnb/account/app/service/AccountTokenService.java
  44. 3 3
      account/account-service/src/main/java/cn/reghao/tnb/account/app/service/CodeService.java
  45. 1 1
      account/account-service/src/main/java/cn/reghao/tnb/account/app/service/PubkeyService.java
  46. 18 20
      account/account-service/src/main/java/cn/reghao/tnb/account/app/service/impl/AccountLoginServiceImpl.java
  47. 4 5
      account/account-service/src/main/java/cn/reghao/tnb/account/app/service/impl/AccountRegistryServiceImpl.java
  48. 3 5
      account/account-service/src/main/java/cn/reghao/tnb/account/app/service/impl/AccountTokenServiceImpl.java
  49. 3 3
      account/account-service/src/main/java/cn/reghao/tnb/account/app/service/impl/LoginAttemptServiceImpl.java
  50. 1 1
      account/account-service/src/main/java/cn/reghao/tnb/account/app/util/RabbitProducer.java
  51. 14 18
      account/account-service/src/main/resources/mapper/UserAccountMapper.xml
  52. 20 0
      account/account-service/src/main/resources/mapper/UserAccountRoleMapper.xml
  53. 0 12
      account/account-service/src/main/resources/menu.json
  54. 3 4
      account/account-service/src/main/resources/templates/auth/login.ftl
  55. 1 1
      account/account-service/src/main/resources/templates/inc/footer.ftl
  56. 2 2
      account/account-service/src/main/resources/templates/inc/header.ftl
  57. 3 3
      account/account-service/src/main/resources/templates/index.ftl
  58. 2 2
      account/account-service/src/test/java/UserAccountTest.java
  59. 1 2
      content/content-service/src/main/java/cn/reghao/tnb/content/app/config/SpringDocConfig.java
  60. 0 17
      content/content-service/src/test/java/cn/reghao/tnb/content/app/geo/service/GeoTest.java
  61. 0 8
      content/content-service/src/test/java/cn/reghao/tnb/content/app/vod/service/VideoPostTest.java
  62. 0 5
      eureka/eureka-server/pom.xml
  63. 2 2
      file/file-service/src/main/java/cn/reghao/tnb/file/app/config/AppProperties.java
  64. 1 2
      file/file-service/src/main/java/cn/reghao/tnb/file/app/config/SpringDocConfig.java
  65. 6 5
      file/file-service/src/main/java/cn/reghao/tnb/file/app/rpc/FileServiceImpl.java
  66. 0 2
      file/file-service/src/main/resources/application.yml
  67. 1 2
      user/user-service/src/main/java/cn/reghao/tnb/user/app/config/SpringDocConfig.java
  68. 2 4
      user/user-service/src/main/java/cn/reghao/tnb/user/app/service/ContactService.java
  69. 1 2
      user/user-service/src/main/java/cn/reghao/tnb/user/app/service/CrawledUserService.java
  70. 0 50
      user/user-service/src/main/java/cn/reghao/tnb/user/app/service/UserProfileService.java
  71. 0 61
      zzz/schema/file_store_config.sql
  72. 0 59
      zzz/schema/msg_email_account.sql
  73. 0 509
      zzz/schema/tnb_account_tdb.sql
  74. 0 1039
      zzz/schema/tnb_content_tdb.sql
  75. 0 60
      zzz/schema/user_registry.sql
  76. 0 58
      zzz/schema/user_vip_plan.sql
  77. 0 170
      zzz/schema/vod_video_category.sql

+ 2 - 1
account/account-api/src/main/java/cn/reghao/tnb/account/api/dto/AccountInfo.java

@@ -15,7 +15,8 @@ import java.io.Serializable;
 public class AccountInfo implements Serializable {
     private static final long serialVersionUID = 1L;
 
-    private String userId;
+    private long userId;
+    private String userIdStr;
     private String screenName;
     private String avatarUrl;
     private String username;

+ 0 - 5
account/account-service/pom.xml

@@ -103,11 +103,6 @@
             <version>2.1.1</version>
         </dependency>
 
-        <dependency>
-            <groupId>org.aspectj</groupId>
-            <artifactId>aspectjweaver</artifactId>
-        </dependency>
-
         <dependency>
             <groupId>org.springframework.cloud</groupId>
             <artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>

+ 0 - 11
account/account-service/src/main/java/cn/reghao/tnb/account/app/aop/AuthException.java

@@ -1,11 +0,0 @@
-package cn.reghao.tnb.account.app.aop;
-
-/**
- * @author reghao
- * @date 2023-07-18 15:25:00
- */
-public class AuthException extends Throwable {
-    public AuthException(String msg) {
-        super(msg);
-    }
-}

+ 0 - 15
account/account-service/src/main/java/cn/reghao/tnb/account/app/aop/AuthUser.java

@@ -1,15 +0,0 @@
-package cn.reghao.tnb.account.app.aop;
-
-import java.lang.annotation.*;
-
-/**
- * @author reghao
- * @date 2023-07-18 15:15:10
- */
-@Target(ElementType.METHOD)
-@Retention(RetentionPolicy.RUNTIME)
-@Documented
-@Deprecated
-public @interface AuthUser {
-    boolean value() default true;
-}

+ 0 - 67
account/account-service/src/main/java/cn/reghao/tnb/account/app/aop/AuthUserAspect.java

@@ -1,67 +0,0 @@
-package cn.reghao.tnb.account.app.aop;
-
-import cn.reghao.jutil.web.ServletUtil;
-import cn.reghao.tnb.account.api.constant.TokenType;
-import cn.reghao.tnb.account.app.security.form.AccountAuthToken;
-import cn.reghao.tnb.account.app.service.AccountTokenService;
-import org.aspectj.lang.ProceedingJoinPoint;
-import org.aspectj.lang.annotation.Around;
-import org.aspectj.lang.annotation.Aspect;
-import org.aspectj.lang.annotation.Pointcut;
-import org.aspectj.lang.reflect.MethodSignature;
-import org.springframework.security.core.Authentication;
-import org.springframework.security.core.context.SecurityContext;
-import org.springframework.security.core.context.SecurityContextHolder;
-import org.springframework.stereotype.Component;
-
-import java.lang.reflect.Method;
-
-/**
- * @author reghao
- * @date 2023-07-18 15:17:35
- */
-@Component
-@Aspect
-@Deprecated
-public class AuthUserAspect {
-    private final String cookieName = "USERDATA";
-    private final AccountTokenService accountTokenService;
-
-    public AuthUserAspect(AccountTokenService accountTokenService) {
-        this.accountTokenService = accountTokenService;
-    }
-
-    @Pointcut("@annotation(cn.reghao.tnb.account.app.aop.AuthUser)")
-    public void loginPointCut(){
-    }
-
-    @Around("loginPointCut()")
-    public Object tokenHandler(ProceedingJoinPoint point) throws Throwable {
-        Class<?> aClass = point.getTarget().getClass();
-        MethodSignature ms = (MethodSignature)point.getSignature();
-        Method method = aClass.getDeclaredMethod(ms.getName(),ms.getParameterTypes());
-        AuthUser authUser = method.getAnnotation(AuthUser.class);
-
-        String userdata = ServletUtil.getCookie(cookieName);
-        if (userdata != null) {
-            AccountAuthToken authToken = accountTokenService.getAuthToken(TokenType.cookie.getValue(), userdata);
-            if (authToken != null) {
-                SecurityContext context = SecurityContextHolder.createEmptyContext();
-                context.setAuthentication(authToken);
-            } else {
-                SecurityContextHolder.createEmptyContext();
-                accountTokenService.clearCookie();
-            }
-        } else {
-            SecurityContextHolder.createEmptyContext();
-        }
-
-        Authentication authentication = SecurityContextHolder.getContext().getAuthentication();
-        boolean auth = authUser.value();
-        if (auth && authentication instanceof AccountAuthToken) {
-            return point.proceed(point.getArgs());
-        }
-
-        throw new AuthException("接口需要认证后才可访问");
-    }
-}

+ 1 - 2
account/account-service/src/main/java/cn/reghao/tnb/account/app/config/SpringDocConfig.java

@@ -24,7 +24,6 @@ public class SpringDocConfig {
                         .version("v0.0.1")
                         .license(new License().name("Apache 2.0").url("https://www.apache.org/licenses/LICENSE-2.0")))
                 .externalDocs(new ExternalDocumentation()
-                        .description("account api")
-                        .url("https://git.reghao.cn/reghao/tnb"));
+                        .description("account api"));
     }
 }

+ 2 - 9
account/account-service/src/main/java/cn/reghao/tnb/account/app/config/web/AccountInterceptor.java

@@ -1,9 +1,7 @@
 package cn.reghao.tnb.account.app.config.web;
 
-import cn.reghao.tnb.account.api.dto.AccountInfo;
 import cn.reghao.tnb.account.app.security.form.AccountAuthToken;
 import cn.reghao.tnb.account.app.service.AccountTokenService;
-import cn.reghao.tnb.account.app.db.mapper.UserAccountMapper;
 import cn.reghao.jutil.web.ServletUtil;
 import lombok.extern.slf4j.Slf4j;
 import org.springframework.lang.Nullable;
@@ -23,11 +21,9 @@ import javax.servlet.http.HttpServletResponse;
 @Slf4j
 @Component
 public class AccountInterceptor implements HandlerInterceptor {
-    private final UserAccountMapper userAccountMapper;
     private final AccountTokenService accountTokenService;
 
-    public AccountInterceptor(UserAccountMapper userAccountMapper, AccountTokenService accountTokenService) {
-        this.userAccountMapper = userAccountMapper;
+    public AccountInterceptor(AccountTokenService accountTokenService) {
         this.accountTokenService = accountTokenService;
     }
 
@@ -44,10 +40,7 @@ public class AccountInterceptor implements HandlerInterceptor {
         AccountAuthToken authToken = accountTokenService.getAuthedToken();
         if (authToken != null) {
             long userId = authToken.getUserId();
-            AccountInfo accountInfo = userAccountMapper.findAccountInfo(userId);
-            ServletUtil.getSession().setAttribute("profile", accountInfo);
-        } else {
-            ServletUtil.getSession().setAttribute("profile", null);
+            ServletUtil.getSession().setAttribute("userId", userId);
         }
     }
 

+ 2 - 3
account/account-service/src/main/java/cn/reghao/tnb/account/app/config/web/exception/ControllerExceptionHandler.java

@@ -2,7 +2,6 @@ package cn.reghao.tnb.account.app.config.web.exception;
 
 import cn.reghao.jutil.jdk.exception.ExceptionUtil;
 import cn.reghao.jutil.web.WebResult;
-import cn.reghao.tnb.account.app.aop.AuthException;
 import lombok.extern.slf4j.Slf4j;
 import org.springframework.http.HttpHeaders;
 import org.springframework.http.HttpStatus;
@@ -62,9 +61,9 @@ public class ControllerExceptionHandler {
         } else if (e instanceof IllegalStateException) {
             IllegalStateException exception = (IllegalStateException) e;
             Throwable throwable = exception.getCause();
-            if (throwable instanceof AuthException) {
+            /*if (throwable instanceof AuthException) {
                 status = HttpStatus.UNAUTHORIZED.value();
-            }
+            }*/
 
             body = WebResult.errorWithMsg(throwable.getMessage());
         }

+ 37 - 0
account/account-service/src/main/java/cn/reghao/tnb/account/app/controller/AccountAdminController.java

@@ -0,0 +1,37 @@
+package cn.reghao.tnb.account.app.controller;
+
+import cn.reghao.jutil.web.WebResult;
+import cn.reghao.tnb.account.app.redis.RedisKeys;
+import cn.reghao.tnb.account.app.redis.ds.RedisOps;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+import java.util.Set;
+
+/**
+ * @author reghao
+ * @date 2025-08-27 11:17:24
+ */
+@Tag(name = "帐号管理接口")
+@RestController
+@RequestMapping("/api/account/admin")
+public class AccountAdminController {
+    private RedisOps redisOps;
+
+    public AccountAdminController(RedisOps redisOps) {
+        this.redisOps = redisOps;
+    }
+
+    @Operation(summary = "获取当前在线用户", description = "N")
+    @GetMapping("/online_users")
+    public String getOnlineUsers() {
+        long userId = 1L;
+        String keyPattern = RedisKeys.getLoginSuccessKeyPattern(userId);
+        Set<String> keys = redisOps.keys(keyPattern);
+
+        return WebResult.success();
+    }
+}

+ 1 - 1
account/account-service/src/main/java/cn/reghao/tnb/account/app/controller/AccountAuthController.java

@@ -39,7 +39,7 @@ public class AccountAuthController {
     @Operation(summary = "帐号登出接口", description = "N")
     @GetMapping("/logout")
     public String logoutPage() {
-        // 注销当前登的设备
+        // 注销当前登的设备
         accountTokenService.logout();
         return "redirect:/login";
     }

+ 1 - 1
account/account-service/src/main/java/cn/reghao/tnb/account/app/controller/AccountProfileController.java

@@ -41,7 +41,7 @@ public class AccountProfileController {
         return WebResult.result(result);
     }
 
-    @Operation(summary = "修改密码(已登)", description = "N")
+    @Operation(summary = "修改密码(已登)", description = "N")
     @PostMapping(value = "/password", produces = MediaType.APPLICATION_JSON_VALUE)
     public String updateUserPassword(@RequestBody @Validated PasswordUpdateDto passwordUpdateDto) {
         Result result = accountProfileService.updatePassword(passwordUpdateDto);

+ 5 - 5
account/account-service/src/main/java/cn/reghao/tnb/account/app/controller/AccountRecordController.java

@@ -14,12 +14,12 @@ import org.springframework.web.bind.annotation.*;
 import java.util.List;
 
 /**
- * 账号登日志接口
+ * 账号登日志接口
  *
  * @author reghao
  * @date 2023-07-31 10:34:41
  */
-@Tag(name = "帐号登日志接口")
+@Tag(name = "帐号登日志接口")
 @RestController
 @RequestMapping("/api/account")
 public class AccountRecordController {
@@ -32,20 +32,20 @@ public class AccountRecordController {
 		this.accountTokenService = accountTokenService;
 	}
 
-	@Operation(summary = "获取登日志列表", description = "N")
+	@Operation(summary = "获取登日志列表", description = "N")
 	@GetMapping("/record/list")
 	public String list(ModelMap model) {
 		List<LoginRecordVo> list = loginAttemptService.getActiveLogin();
 		return WebResult.success(list);
 	}
 
-	@Operation(summary = "注销某次登", description = "N")
+	@Operation(summary = "注销某次登", description = "N")
 	@PostMapping(value = "/deactivate/{loginId}", produces = MediaType.APPLICATION_JSON_VALUE)
 	public String deactivateLogin(@PathVariable("loginId") String loginId) {
 		AccountAuthToken authToken = accountTokenService.getAuthedToken();
 		String currentLoginId = authToken.getLoginId();
 		if (loginId.equals(currentLoginId)) {
-			// 注销当前登的设备
+			// 注销当前登的设备
 			accountTokenService.logout();
 			return WebResult.success("/login");
 		} else {

+ 1 - 2
account/account-service/src/main/java/cn/reghao/tnb/account/app/controller/AccountResourceController.java

@@ -42,8 +42,7 @@ public class AccountResourceController {
             log.info("principal -> {}", principal);
             AccountInfo accountInfo = getAccountInfo(principal);
             if (accountInfo != null) {
-                String userIdStr = accountInfo.getUserId();
-                long userId = accountQuery.getUserIdLong(userIdStr);
+                long userId = accountInfo.getUserId();
                 OAuthAccountInfo oAuthAccountInfo = new OAuthAccountInfo(userId, accountInfo.getScreenName());
                 return WebResult.success(oAuthAccountInfo);
             }

+ 1 - 8
account/account-service/src/main/java/cn/reghao/tnb/account/app/db/mapper/UserAccountMapper.java

@@ -3,7 +3,6 @@ package cn.reghao.tnb.account.app.db.mapper;
 import cn.reghao.jutil.jdk.db.BaseMapper;
 import cn.reghao.jutil.jdk.db.Page;
 import cn.reghao.tnb.account.api.dto.AccountInfo;
-import cn.reghao.tnb.account.app.model.dto.AccountDetail;
 import cn.reghao.tnb.account.app.model.po.UserAccount;
 import org.apache.ibatis.annotations.Mapper;
 import org.apache.ibatis.annotations.Param;
@@ -29,22 +28,16 @@ public interface UserAccountMapper extends BaseMapper<UserAccount> {
     void updateUserAvatar(@Param("userId") long userId, @Param("avatarUrl") String avatarUrl);
 
     Long findMaxUserId();
+    UserAccount findByUsername(String username);
     UserAccount findByEmail(String email);
     UserAccount findByMobile(String mobile);
     Long findUserIdByUsername(String username);
     UserAccount findByUserId(long userId);
-    AccountDetail findByUsername(String username);
-    AccountDetail findByEmail1(String email);
-    AccountDetail findByMobile1(String mobile);
     int count();
-
     AccountInfo findAccountInfo(long userId);
     List<AccountInfo> findAccountInfos(List<Long> list);
     AccountInfo findAccountInfoByMobile(String mobile);
     AccountInfo findAccountInfoByEmail(String email);
     AccountInfo findAccountInfoByUsername(String username);
-
-    int countByScreenName(String screenName);
-    List<AccountInfo> findScreenNameByPage(Page page, String screenName);
     List<AccountInfo> findAccountInfoByPage(Page page);
 }

+ 1 - 0
account/account-service/src/main/java/cn/reghao/tnb/account/app/db/mapper/UserAccountRoleMapper.java

@@ -12,5 +12,6 @@ import java.util.List;
  */
 @Mapper
 public interface UserAccountRoleMapper extends BaseMapper<UserAccountRole> {
+    List<UserAccountRole> findByUserId(long userId);
     List<UserAccountRole> findByIds(List<Integer> list);
 }

+ 0 - 15
account/account-service/src/main/java/cn/reghao/tnb/account/app/db/query/UserAuthQuery.java

@@ -1,15 +0,0 @@
-package cn.reghao.tnb.account.app.db.query;
-
-import cn.reghao.jutil.jdk.db.BaseQuery;
-import cn.reghao.tnb.account.app.model.dto.AccountDetail;
-import cn.reghao.tnb.account.app.model.po.UserAccount;
-
-/**
- * @author reghao
- * @date 2021-11-16 09:22:13
- */
-public interface UserAuthQuery extends BaseQuery<UserAccount> {
-    AccountDetail findByUsername(String username);
-    AccountDetail findByEmail(String email);
-    AccountDetail findByMobile(String mobile);
-}

+ 0 - 34
account/account-service/src/main/java/cn/reghao/tnb/account/app/db/query/impl/UserAuthQueryImpl.java

@@ -1,34 +0,0 @@
-package cn.reghao.tnb.account.app.db.query.impl;
-
-import cn.reghao.tnb.account.app.db.mapper.UserAccountMapper;
-import cn.reghao.tnb.account.app.db.query.UserAuthQuery;
-import cn.reghao.tnb.account.app.model.dto.AccountDetail;
-import org.springframework.stereotype.Service;
-
-/**
- * @author reghao
- * @date 2021-11-16 09:22:35
- */
-@Service
-public class UserAuthQueryImpl implements UserAuthQuery {
-    private final UserAccountMapper userAccountMapper;
-
-    public UserAuthQueryImpl(UserAccountMapper userAccountMapper) {
-        this.userAccountMapper = userAccountMapper;
-    }
-
-    @Override
-    public AccountDetail findByUsername(String username) {
-        return userAccountMapper.findByUsername(username);
-    }
-
-    @Override
-    public AccountDetail findByEmail(String email) {
-        return userAccountMapper.findByEmail1(email);
-    }
-
-    @Override
-    public AccountDetail findByMobile(String mobile) {
-        return userAccountMapper.findByMobile1(mobile);
-    }
-}

+ 27 - 46
account/account-service/src/main/java/cn/reghao/tnb/account/app/db/repository/AccountRepository.java

@@ -1,15 +1,12 @@
 package cn.reghao.tnb.account.app.db.repository;
 
-import cn.reghao.jutil.jdk.db.Page;
 import cn.reghao.tnb.account.api.dto.AccountInfo;
 import cn.reghao.tnb.account.app.db.mapper.UserAccountMapper;
 import cn.reghao.tnb.account.app.db.mapper.UserAccountRoleMapper;
 import cn.reghao.tnb.account.app.db.mapper.UserRegistryMapper;
-import cn.reghao.tnb.account.app.model.dto.AccountDetail;
 import cn.reghao.tnb.account.app.model.po.UserAccount;
 import cn.reghao.tnb.account.app.model.po.UserAccountRole;
 import cn.reghao.tnb.account.app.model.po.UserRegistry;
-import cn.reghao.tnb.message.api.constant.NotifyType;
 import org.springframework.cache.annotation.CacheEvict;
 import org.springframework.cache.annotation.Cacheable;
 import org.springframework.stereotype.Repository;
@@ -24,10 +21,9 @@ import java.util.stream.Collectors;
  */
 @Repository
 public class AccountRepository {
-    private final int pageSize = 100;
     private final UserAccountMapper userAccountMapper;
     private final UserRegistryMapper userRegistryMapper;
-    private UserAccountRoleMapper userAccountRoleMapper;
+    private final UserAccountRoleMapper userAccountRoleMapper;
 
     public AccountRepository(UserAccountMapper userAccountMapper, UserRegistryMapper userRegistryMapper,
                              UserAccountRoleMapper userAccountRoleMapper) {
@@ -56,34 +52,37 @@ public class AccountRepository {
         userAccountMapper.updateUserAvatar(userId, avatarUrl);
     }
 
-    public AccountDetail getUserDetailByEmail(String email) {
-        return userAccountMapper.findByEmail1(email);
+    public Long getMaxUserId() {
+        return userAccountMapper.findMaxUserId();
     }
 
-    public AccountDetail getUserDetailByMobile(String email) {
-        return userAccountMapper.findByMobile1(email);
+    @Cacheable(cacheNames = "tnb:account:info", key = "#userId", unless = "#result == null")
+    public AccountInfo getAccountInfo(long userId) {
+        AccountInfo accountInfo = userAccountMapper.findAccountInfo(userId);
+        return accountInfo;
     }
 
-    public Long getMaxUserId() {
-        return userAccountMapper.findMaxUserId();
+    public void updateUserRegistry() {
+        UserRegistry userRegistry = getUserRegistry();
+        userRegistryMapper.update(userRegistry);
     }
 
-    public UserAccount findByEmail(int type, String email) {
-        if (type == NotifyType.email.getValue()) {
-            return userAccountMapper.findByEmail(email);
+    public UserRegistry getUserRegistry() {
+        List<UserRegistry> list = userRegistryMapper.findAll();
+        if (list.isEmpty()) {
+            userRegistryMapper.save(new UserRegistry());
         }
 
-        return userAccountMapper.findByMobile(email);
+        return userRegistryMapper.findAll().get(0);
     }
 
-    public Long getUserId(String username) {
-        return userAccountMapper.findUserIdByUsername(username);
+    public List<String> getRoles(List<Integer> roleIds) {
+        List<UserAccountRole> roles = userAccountRoleMapper.findByIds(roleIds);
+        return roles.stream().map(UserAccountRole::getName).collect(Collectors.toList());
     }
 
-    @Cacheable(cacheNames = "tnb:account:info", key = "#userId", unless = "#result == null")
-    public AccountInfo getAccountInfo(long userId) {
-        AccountInfo accountInfo = userAccountMapper.findAccountInfo(userId);
-        return accountInfo;
+    public long getUserIdByUsername(String username) {
+        return userAccountMapper.findUserIdByUsername(username);
     }
 
     public List<AccountInfo> getAccountInfos(List<Long> userIds) {
@@ -100,37 +99,19 @@ public class AccountRepository {
         return accountInfo;
     }
 
-    public int countByScreenName(String screenName) {
-        int total = userAccountMapper.countByScreenName(screenName);
-        return total;
-    }
-
-    public List<AccountInfo> getPageByScreenName(String screenName, int pageNumber) {
-        Page page1 = new Page(pageNumber, pageSize);
-        List<AccountInfo> list = userAccountMapper.findScreenNameByPage(page1, screenName);
-        return list;
-    }
-
-    public UserAccount getUserAccount(long userId) {
+    public UserAccount getUserAccountByUserId(long userId) {
         return userAccountMapper.findByUserId(userId);
     }
 
-    public UserRegistry getUserRegistry() {
-        List<UserRegistry> list = userRegistryMapper.findAll();
-        if (list.isEmpty()) {
-            userRegistryMapper.save(new UserRegistry());
-        }
-
-        return userRegistryMapper.findAll().get(0);
+    public UserAccount getUserAccountByUsername(String username) {
+        return userAccountMapper.findByUsername(username);
     }
 
-    public void updateUserRegistry() {
-        UserRegistry userRegistry = getUserRegistry();
-        userRegistryMapper.update(userRegistry);
+    public UserAccount getUserAccountByEmail(String email) {
+        return userAccountMapper.findByEmail(email);
     }
 
-    public List<String> getRoles(List<Integer> roleIds) {
-        List<UserAccountRole> roles = userAccountRoleMapper.findByIds(roleIds);
-        return roles.stream().map(UserAccountRole::getName).collect(Collectors.toList());
+    public UserAccount getUserAccountByMobile(String mobile) {
+        return userAccountMapper.findByMobile(mobile);
     }
 }

+ 6 - 10
account/account-service/src/main/java/cn/reghao/tnb/account/app/model/constant/LoginPlat.java

@@ -1,22 +1,18 @@
 package cn.reghao.tnb.account.app.model.constant;
 
 /**
- * 登平台类型
+ * 登平台类型
  *
  * @author reghao
  * @date 2023-02-15 16:39:47
  */
 public enum LoginPlat {
-    // web 端登
+    // web 端登
     web(1),
-    // android 端登录
-    android(2),
-    // pc 端登录
-    pc(3),
-    // iOS 端登录
-    ios(4),
-    // 其他端登录
-    other(5);
+    // REST 接口登入
+    rest(2),
+    // 其他端登入
+    other(3);
 
     private final int value;
     LoginPlat(int value) {

+ 4 - 4
account/account-service/src/main/java/cn/reghao/tnb/account/app/model/constant/LoginType.java

@@ -1,19 +1,19 @@
 package cn.reghao.tnb.account.app.model.constant;
 
 /**
- * 登类型
+ * 登类型
  *
  * @author reghao
  * @date 2021-11-17 16:54:00
  */
 public enum LoginType {
-    // 手机号/验证码登
+    // 手机号/验证码登
     mobileCode(1),
-    // 邮箱/密码登
+    // 邮箱/密码登
     usernamePassword(2),
     // 双因子验证
     twoFactor(3),
-    // 第三方登
+    // 第三方登
     thirdParty(4);
 
     private final int value;

+ 0 - 18
account/account-service/src/main/java/cn/reghao/tnb/account/app/model/dto/AccountDetail.java

@@ -1,18 +0,0 @@
-package cn.reghao.tnb.account.app.model.dto;
-
-import lombok.Getter;
-
-/**
- * @author reghao
- * @date 2023-10-19 13:40:54
- */
-@Getter
-public class AccountDetail {
-    private Long userId;
-    private String username;
-    private String encodedPassword;
-    private String salt;
-    private String role;
-    private Boolean enabled;
-    private Boolean locked;
-}

+ 3 - 3
account/account-service/src/main/java/cn/reghao/tnb/account/app/model/dto/AccountLoginDto.java

@@ -11,7 +11,7 @@ import javax.validation.constraints.NotBlank;
 import java.io.Serializable;
 
 /**
- * 用户登提交的数据
+ * 用户登提交的数据
  *
  * @author reghao
  * @date 2021-11-17 16:36:05
@@ -21,7 +21,7 @@ import java.io.Serializable;
 public class AccountLoginDto implements Serializable {
     private static final long serialVersionUID = 1L;
 
-    @ValidEnum(value = LoginType.class, message = "登类型不正确")
+    @ValidEnum(value = LoginType.class, message = "登类型不正确")
     private Integer loginType;
     @NotBlank
     private String principal;
@@ -29,7 +29,7 @@ public class AccountLoginDto implements Serializable {
     private String credential;
     @Length(min = 5, max = 5, message = "图形验证码应是 5 个字符")
     private String captchaCode;
-    @ValidEnum(value = LoginPlat.class, message = "登平台类型不正确")
+    @ValidEnum(value = LoginPlat.class, message = "登平台类型不正确")
     private Integer plat;
     private Boolean rememberMe;
 

+ 1 - 1
account/account-service/src/main/java/cn/reghao/tnb/account/app/model/dto/AccountLoginRet.java

@@ -6,7 +6,7 @@ import lombok.Getter;
 import java.io.Serializable;
 
 /**
- * 用户登成功(/api/auth/signin 接口)返回的数据
+ * 用户登成功(/api/auth/signin 接口)返回的数据
  *
  * @author reghao
  * @date 2022-07-08 16:27:04

+ 1 - 1
account/account-service/src/main/java/cn/reghao/tnb/account/app/model/po/LoginAttempts.java

@@ -6,7 +6,7 @@ import lombok.*;
 import java.time.LocalDateTime;
 
 /**
- * 用户登日志
+ * 用户登日志
  *
  * @author reghao
  * @date 2022-07-08 10:27:55

+ 81 - 4
account/account-service/src/main/java/cn/reghao/tnb/account/app/model/po/UserAccount.java

@@ -14,11 +14,13 @@ import javax.validation.constraints.NotBlank;
 import javax.validation.constraints.NotNull;
 import java.time.LocalDateTime;
 import java.util.Collection;
+import java.util.HashSet;
 import java.util.Set;
 import java.util.stream.Collectors;
 
 /**
  * 用户账号
+ * 实现的 UserDetails 接口提供了 Spring Security 需要的用户认证信息
  *
  * @author reghao
  * @date 2021-10-30 17:49:07
@@ -26,7 +28,7 @@ import java.util.stream.Collectors;
 @NoArgsConstructor
 @EqualsAndHashCode(callSuper = true)
 @Data
-public class UserAccount extends BaseObject<Integer> {
+public class UserAccount extends BaseObject<Integer> implements UserDetails {
     @NotNull
     private Long userId;
     private Integer accountType;
@@ -41,9 +43,14 @@ public class UserAccount extends BaseObject<Integer> {
     private String salt;
     private LocalDateTime createAt;
     private Boolean notify;
+    @Deprecated
     private String roles;
 
+    private transient int loginType;
+    private transient int plat;
     // Spring Security 使用的字段
+    private transient Set<UserAuthority> authorities = new HashSet<>();
+    @Deprecated
     private String role;
     private Boolean enabled;
     private Boolean locked;
@@ -63,7 +70,7 @@ public class UserAccount extends BaseObject<Integer> {
         this.salt = "";
         this.createAt = LocalDateTime.now();
         this.notify = false;
-        this.role = AccountRole.user.getValue();
+        //this.role = AccountRole.user.getValue();
         this.enabled = true;
         this.locked = false;
         this.screenName = this.username;
@@ -81,7 +88,7 @@ public class UserAccount extends BaseObject<Integer> {
         this.salt = salt;
         this.createAt = LocalDateTime.now();
         this.notify = false;
-        this.role = AccountRole.user.getValue();
+        //this.role = AccountRole.user.getValue();
         this.enabled = true;
         this.locked = false;
         this.screenName = this.username;
@@ -96,10 +103,80 @@ public class UserAccount extends BaseObject<Integer> {
         this.username = username;
         this.email = email;
         this.createAt = LocalDateTime.now();
-        this.role = AccountRole.user.getValue();
+        //this.role = AccountRole.user.getValue();
         this.enabled = true;
         this.locked = false;
         this.screenName = screenName;
         this.avatarUrl = avatarUrl;
     }
+
+    @Override
+    public String getUsername() {
+        return this.username;
+    }
+
+    @Override
+    public String getPassword() {
+        return this.encodedPassword;
+    }
+
+    /**
+     * 账号是否未过期
+     *
+     * @param
+     * @return
+     * @date 2021-11-16 上午9:56
+     */
+    @Override
+    public boolean isAccountNonExpired() {
+        return true;
+    }
+
+    /**
+     * 密码是否未过期
+     *
+     * @param
+     * @return
+     * @date 2021-11-16 上午9:56
+     */
+    @Override
+    public boolean isCredentialsNonExpired() {
+        return true;
+    }
+
+    /**
+     * 账号是否可用
+     *
+     * @param
+     * @return
+     * @date 2021-11-16 上午9:56
+     */
+    @Override
+    public boolean isEnabled() {
+        return this.enabled;
+    }
+
+    /**
+     * 账号是否锁定
+     *
+     * @param
+     * @return
+     * @date 2021-11-16 上午9:56
+     */
+    @Override
+    public boolean isAccountNonLocked() {
+        return !this.locked;
+    }
+
+    /**
+     * 权限列表
+     *
+     * @param
+     * @return
+     * @date 2021-11-16 上午9:56
+     */
+    @Override
+    public Collection<? extends GrantedAuthority> getAuthorities() {
+        return authorities;
+    }
 }

+ 1 - 0
account/account-service/src/main/java/cn/reghao/tnb/account/app/model/po/UserAccountRole.java

@@ -9,5 +9,6 @@ import lombok.Getter;
  */
 @Getter
 public class UserAccountRole extends BaseObject<Integer> {
+    private Long userId;
     private String name;
 }

+ 1 - 1
account/account-service/src/main/java/cn/reghao/tnb/account/app/model/vo/UserAuthority.java → account/account-service/src/main/java/cn/reghao/tnb/account/app/model/po/UserAuthority.java

@@ -1,4 +1,4 @@
-package cn.reghao.tnb.account.app.model.vo;
+package cn.reghao.tnb.account.app.model.po;
 
 import cn.reghao.tnb.account.app.model.constant.AccountRole;
 import org.springframework.security.core.GrantedAuthority;

+ 0 - 22
account/account-service/src/main/java/cn/reghao/tnb/account/app/model/vo/AccessLog.java

@@ -1,22 +0,0 @@
-package cn.reghao.tnb.account.app.model.vo;
-
-import lombok.AllArgsConstructor;
-import lombok.Getter;
-import lombok.NoArgsConstructor;
-
-/**
- * @author reghao
- * @date 2023-04-19 15:22:44
- */
-@AllArgsConstructor
-@NoArgsConstructor
-@Getter
-public class AccessLog {
-    private String uri;
-    private String method;
-    private String remoteAddr;
-    private Integer remotePort;
-    private String userAgent;
-    private String sessionId;
-    private Long userId;
-}

+ 0 - 17
account/account-service/src/main/java/cn/reghao/tnb/account/app/model/vo/SiteOption.java

@@ -1,17 +0,0 @@
-package cn.reghao.tnb.account.app.model.vo;
-
-import lombok.Getter;
-import lombok.Setter;
-
-/**
- * 站点配置项
- *
- * @author reghao
- * @date 2023-04-18 08:31:24
- */
-@Setter
-@Getter
-public class SiteOption {
-    private String propKey;
-    private String propValue;
-}

+ 0 - 16
account/account-service/src/main/java/cn/reghao/tnb/account/app/model/vo/SystemInfo.java

@@ -1,16 +0,0 @@
-package cn.reghao.tnb.account.app.model.vo;
-
-import lombok.AllArgsConstructor;
-import lombok.Getter;
-
-/**
- * @author reghao
- * @date 2023-11-14 17:21:04
- */
-@AllArgsConstructor
-@Getter
-public class SystemInfo {
-    private String osInfo;
-    private String jvmInfo;
-    private String procInfo;
-}

+ 0 - 118
account/account-service/src/main/java/cn/reghao/tnb/account/app/model/vo/UserDetail.java

@@ -1,118 +0,0 @@
-package cn.reghao.tnb.account.app.model.vo;
-
-import cn.reghao.tnb.account.app.model.dto.AccountDetail;
-import lombok.Getter;
-import lombok.Setter;
-import org.springframework.security.core.GrantedAuthority;
-import org.springframework.security.core.userdetails.UserDetails;
-
-import java.util.Collection;
-import java.util.Set;
-
-/**
- * 仅供 Spring Security 使用的用户认证信息
- *
- * @author reghao
- * @date 2021/11/16 09:12:48
- */
-@Setter
-@Getter
-public class UserDetail implements UserDetails {
-    private Long userId;
-    private String username;
-    private String encodedPassword;
-    private String salt;
-    private Boolean enabled;
-    private Boolean locked;
-    private final Set<GrantedAuthority> authorities;
-    private int loginType;
-    private int plat;
-
-    public UserDetail(AccountDetail accountDetail) {
-        this.userId = accountDetail.getUserId();
-        this.username = accountDetail.getUsername();
-        this.encodedPassword = accountDetail.getEncodedPassword();
-        this.salt = accountDetail.getSalt();
-        this.enabled = accountDetail.getEnabled();
-        this.locked = accountDetail.getLocked();
-        this.authorities = Set.of(new UserAuthority());
-    }
-
-    public UserDetail() {
-        this.authorities = Set.of(new UserAuthority());
-    }
-
-    public String getSalt() {
-        return this.salt;
-    }
-
-    @Override
-    public String getUsername() {
-        return this.username;
-    }
-
-    @Override
-    public String getPassword() {
-        return this.encodedPassword;
-    }
-
-    /**
-     * 账号是否未过期
-     *
-     * @param
-     * @return
-     * @date 2021-11-16 上午9:56
-     */
-    @Override
-    public boolean isAccountNonExpired() {
-        return true;
-    }
-
-    /**
-     * 密码是否未过期
-     *
-     * @param
-     * @return
-     * @date 2021-11-16 上午9:56
-     */
-    @Override
-    public boolean isCredentialsNonExpired() {
-        return true;
-    }
-
-    /**
-     * 账号是否可用
-     *
-     * @param
-     * @return
-     * @date 2021-11-16 上午9:56
-     */
-    @Override
-    public boolean isEnabled() {
-        return this.enabled;
-    }
-
-    /**
-     * 账号是否锁定
-     *
-     * @param
-     * @return
-     * @date 2021-11-16 上午9:56
-     */
-    @Override
-    public boolean isAccountNonLocked() {
-        return !this.locked;
-    }
-
-    /**
-     * 权限列表
-     *
-     * @param
-     * @return
-     * @date 2021-11-16 上午9:56
-     */
-    @Override
-    public Collection<? extends GrantedAuthority> getAuthorities() {
-        return authorities;
-    }
-}

+ 5 - 6
account/account-service/src/main/java/cn/reghao/tnb/account/app/rpc/AccountQueryImpl.java

@@ -41,11 +41,10 @@ public class AccountQueryImpl implements AccountQuery {
     public AuthedAccount getAuthedAccount(int type, String sessId) {
         AccountInfo accountInfo = accountTokenService.getAccountInfo(type, sessId);
         if (accountInfo != null) {
-            String userIdStr = accountInfo.getUserId();
             //long userId = userIdObfuscation.restore(userIdStr);
-            long userId = Long.parseLong(userIdStr);
-            UserAccount userAccount = accountRepository.getUserAccount(userId);
-            String role = userAccount.getRole();
+            long userId = accountInfo.getUserId();
+            UserAccount userAccount = accountRepository.getUserAccountByUserId(userId);
+            //String role = userAccount.getRole();
             return new AuthedAccount(userAccount.getUserId());
         }
 
@@ -54,7 +53,7 @@ public class AccountQueryImpl implements AccountQuery {
 
     @Override
     public Long getUserId(String username) {
-        return accountRepository.getUserId(username);
+        return accountRepository.getUserIdByUsername(username);
     }
 
     @Override
@@ -132,7 +131,7 @@ public class AccountQueryImpl implements AccountQuery {
      */
     @Override
     public ExamAccount getExamAccount(long userId) {
-        UserAccount userAccount = accountRepository.getUserAccount(userId);
+        UserAccount userAccount = accountRepository.getUserAccountByUserId(userId);
         List<Integer> roleIds = Arrays.stream(userAccount.getRoles().split(","))
                 .map(Integer::parseInt)
                 .collect(Collectors.toList());

+ 1 - 1
account/account-service/src/main/java/cn/reghao/tnb/account/app/security/OAuth2AuthorizationConfig.java

@@ -65,7 +65,7 @@ public class OAuth2AuthorizationConfig extends AuthorizationServerConfigurerAdap
     @Override
     public void configure(AuthorizationServerEndpointsConfigurer endpoints) {
         endpoints
-                // 用户表单登认证
+                // 用户表单登认证
                 .authenticationManager(authenticationManager)
                 // refresh_token 时需要加载用户信息
                 .userDetailsService(userDetailsService)

+ 3 - 3
account/account-service/src/main/java/cn/reghao/tnb/account/app/security/WebSecurityConfig.java

@@ -104,7 +104,7 @@ public class WebSecurityConfig extends WebSecurityConfigurerAdapter {
                 //.logoutSuccessUrl(loginPage)
                 .logoutSuccessHandler(logoutSuccessHandler);
 
-        // 配置 ExceptionTranslationFilter, 登认证接口失败时的处理, 不会重定向到 loginPage
+        // 配置 ExceptionTranslationFilter, 登认证接口失败时的处理, 不会重定向到 loginPage
         http.exceptionHandling()
                 .authenticationEntryPoint(new ExceptionAuthenticationEntryPoint());
 
@@ -158,7 +158,7 @@ public class WebSecurityConfig extends WebSecurityConfigurerAdapter {
     }
 
     /**
-     * 配置账号密码登 filter
+     * 配置账号密码登 filter
      *
      * @param
      * @return
@@ -173,7 +173,7 @@ public class WebSecurityConfig extends WebSecurityConfigurerAdapter {
     }
 
     /**
-     * 配置第三方 OAuth 登 filter
+     * 配置第三方 OAuth 登 filter
      *
      * @param
      * @return

+ 2 - 2
account/account-service/src/main/java/cn/reghao/tnb/account/app/security/filter/LoginRedirectFilter.java

@@ -11,7 +11,7 @@ import java.io.IOException;
 
 /**
  * 用于 Web 应用
- * 已登状态下,访问认证页面/接口自动跳转到首页
+ * 已登状态下,访问认证页面/接口自动跳转到首页
  *
  * @author reghao
  * @date 2019-06-04 23:06:50
@@ -26,7 +26,7 @@ public class LoginRedirectFilter extends GenericFilterBean {
         SecurityContext securityContext = SecurityContextHolder.getContext();
         String url = httpRequest.getRequestURI().substring(httpRequest.getContextPath().length());
         if (securityContext != null && securityContext.getAuthentication() != null && "/login".equals(url)) {
-            // 将登页面重定向到主页
+            // 将登页面重定向到主页
             httpResponse.sendRedirect("/");
         } else {
             chain.doFilter(request, response);

+ 1 - 1
account/account-service/src/main/java/cn/reghao/tnb/account/app/security/form/AccountAuthFilter.java

@@ -14,7 +14,7 @@ import javax.servlet.http.HttpServletResponse;
 import java.io.IOException;
 
 /**
- * 账号密码登 filter
+ * 账号密码登 filter
  * 替换 UsernamePasswordAuthenticationFilter,用于认证用户,匹配指定 URL 才会进行处理
  *
  * @author reghao

+ 1 - 1
account/account-service/src/main/java/cn/reghao/tnb/account/app/security/form/AccountAuthProvider.java

@@ -38,7 +38,7 @@ public class AccountAuthProvider implements AuthenticationProvider {
         } else if (loginType == LoginType.usernamePassword.getValue()) {
             authToken = accountLoginService.authByPassword(preAuthToken);
         } else {
-            throw new DisabledException("登类型错误");
+            throw new DisabledException("登类型错误");
         }
         return authToken;
     }

+ 2 - 2
account/account-service/src/main/java/cn/reghao/tnb/account/app/security/form/AccountAuthToken.java

@@ -1,6 +1,6 @@
 package cn.reghao.tnb.account.app.security.form;
 
-import cn.reghao.tnb.account.app.model.vo.UserDetail;
+import cn.reghao.tnb.account.app.model.po.UserAccount;
 import org.springframework.security.authentication.AbstractAuthenticationToken;
 import org.springframework.security.core.GrantedAuthority;
 import org.springframework.security.core.SpringSecurityCoreVersion;
@@ -60,7 +60,7 @@ public class AccountAuthToken extends AbstractAuthenticationToken {
      * @param authToken
      * @param accountDetail
      */
-    public AccountAuthToken(AccountAuthToken authToken, UserDetail userDetail) {
+    public AccountAuthToken(AccountAuthToken authToken, UserAccount userDetail) {
         super(userDetail.getAuthorities());
         super.setAuthenticated(true); // must use super, as we override
         super.setDetails(userDetail);

+ 1 - 1
account/account-service/src/main/java/cn/reghao/tnb/account/app/security/form/ThirdPartyAuthFilter.java

@@ -15,7 +15,7 @@ import javax.servlet.http.HttpServletResponse;
 import java.io.IOException;
 
 /**
- * 第三方登 filter
+ * 第三方登 filter
  *
  * @author reghao
  * @date 2023-07-31 15:55:59

+ 15 - 14
account/account-service/src/main/java/cn/reghao/tnb/account/app/security/handler/AuthSuccessHandlerImpl.java

@@ -4,7 +4,8 @@ import cn.reghao.jutil.jdk.converter.DateTimeConverter;
 import cn.reghao.jutil.web.WebResult;
 import cn.reghao.jutil.web.ServletUtil;
 import cn.reghao.tnb.account.api.iface.AccountQuery;
-import cn.reghao.tnb.account.app.middleware.RabbitProducer;
+import cn.reghao.tnb.account.app.db.repository.AccountRepository;
+import cn.reghao.tnb.account.app.util.RabbitProducer;
 import cn.reghao.tnb.account.app.model.constant.LoginPlat;
 import cn.reghao.tnb.account.api.dto.AccountInfo;
 import cn.reghao.tnb.account.app.model.dto.AccountLoginRet;
@@ -39,16 +40,16 @@ import java.time.LocalDateTime;
 public class AuthSuccessHandlerImpl implements AuthenticationSuccessHandler {
     private final RabbitProducer rabbitProducer;
     private final LoginAttemptService loginAttemptService;
-    private final UserAccountMapper userAccountMapper;
+    private final AccountRepository accountRepository;
     private final AccountTokenService accountTokenService;
     private final AccountQuery accountQuery;
 
     public AuthSuccessHandlerImpl(RabbitProducer rabbitProducer, LoginAttemptService loginAttemptService,
-                                  UserAccountMapper userAccountMapper, AccountTokenService accountTokenService,
+                                  AccountRepository accountRepository, AccountTokenService accountTokenService,
                                   AccountQuery accountQuery) {
         this.rabbitProducer = rabbitProducer;
         this.loginAttemptService = loginAttemptService;
-        this.userAccountMapper = userAccountMapper;
+        this.accountRepository = accountRepository;
         this.accountTokenService = accountTokenService;
         this.accountQuery = accountQuery;
     }
@@ -69,7 +70,7 @@ public class AuthSuccessHandlerImpl implements AuthenticationSuccessHandler {
         boolean rememberMe = authToken.isRememberMe();
         String redirectPath = getRedirectPath();
 
-        UserAccount userAccount = userAccountMapper.findByUserId(userId);
+        UserAccount userAccount = accountRepository.getUserAccountByUserId(userId);
         if (userAccount.getNotify()) {
             int notifyType = NotifyType.email.getValue();
             String receiver = userAccount.getEmail();
@@ -90,23 +91,23 @@ public class AuthSuccessHandlerImpl implements AuthenticationSuccessHandler {
         long timeout = rememberMe ? 3600*24*30 : 0;
         String uri = ServletUtil.getRequest().getRequestURI();
         if (uri.startsWith("/oauth/redirect")) {
-            // 第三方 oauth 登录
+            // 使用第三方帐号的 oauth 方式登入
             accountTokenService.setCookie(authToken, timeout);
             response.sendRedirect(redirectPath);
             return;
         }
 
         AccountLoginRet accountLoginRet = new AccountLoginRet(redirectPath);
-        if (LoginPlat.web.getValue() == plat) {
+        if (LoginPlat.rest.getValue() == plat) {
+            AccountInfo accountInfo = accountRepository.getAccountInfo(userId);
+            String userIdStr = accountQuery.getUserIdStr(accountInfo.getUserId());
+            accountInfo.setUserIdStr(userIdStr);
+            AccountToken accountToken = accountTokenService.grantUserToken(authToken);
+            accountLoginRet = new AccountLoginRet(accountInfo, accountToken, redirectPath);
+        } else if (LoginPlat.web.getValue() == plat) {
             accountTokenService.setCookie(authToken, timeout);
             String userIdStr = accountQuery.getUserIdStr(userId);
             accountLoginRet = new AccountLoginRet(userIdStr, loginId, plat, redirectPath);
-        } else if (LoginPlat.android.getValue() == plat) {
-            AccountInfo accountInfo = userAccountMapper.findAccountInfo(userId);
-            String userIdStr = accountQuery.getUserIdStr(Long.parseLong(accountInfo.getUserId()));
-            accountInfo.setUserId(userIdStr);
-            AccountToken accountToken = accountTokenService.grantUserToken(authToken);
-            accountLoginRet = new AccountLoginRet(accountInfo, accountToken, redirectPath);
         }
 
         String body = WebResult.success(accountLoginRet);
@@ -114,7 +115,7 @@ public class AuthSuccessHandlerImpl implements AuthenticationSuccessHandler {
     }
 
     /**
-     * 认证成功后, 重定向到登前的地址, 需要 session 的支持
+     * 认证成功后, 重定向到登前的地址, 需要 session 的支持
      *
      * @param
      * @return

+ 5 - 5
account/account-service/src/main/java/cn/reghao/tnb/account/app/service/AccountProfileService.java

@@ -112,7 +112,7 @@ public class AccountProfileService {
             String captchaCode = passwordResetDto.getCaptchaCode();
             String savedCaptchaCode = codeService.getCaptcha();
             if (savedCaptchaCode == null) {
-                return Result.fail("当前会话已过期, 请刷新页面后重新登. 或者检查浏览器是否禁用了 cookie");
+                return Result.fail("当前会话已过期, 请刷新页面后重新登. 或者检查浏览器是否禁用了 cookie");
             } else if (!captchaCode.equalsIgnoreCase(savedCaptchaCode)) {
                 return Result.fail("图形验证码不正确, 请刷新页面后重新获取");
             }
@@ -121,13 +121,13 @@ public class AccountProfileService {
             String verifyCode = passwordResetDto.getVerifyCode();
             String savedVerifyCode = codeService.getVerifyCode(VerifyChannel.passwordChannel.getValue(), email);
             if (savedVerifyCode == null) {
-                return Result.fail("当前会话已过期, 请刷新页面后重新登. 或者检查浏览器是否禁用了 cookie");
+                return Result.fail("当前会话已过期, 请刷新页面后重新登. 或者检查浏览器是否禁用了 cookie");
             } else if (!verifyCode.equalsIgnoreCase(savedVerifyCode)) {
                 return Result.fail("短信验证码不正确, 请重新获取");
             }
 
-            AccountDetail accountDetail = userAccountMapper.findByEmail1(email);
-            if (accountDetail == null) {
+            UserAccount userAccount = userAccountMapper.findByEmail(email);
+            if (userAccount == null) {
                 return Result.fail("帐号不存在");
             }
 
@@ -135,7 +135,7 @@ public class AccountProfileService {
             String decryptNewPassword = pubkeyService.decrypt(newPassword);
             String newSalt = RandomString.getSalt(64);
             String encodedNewPasswd = passwordEncoder.encode(decryptNewPassword + newSalt);
-            userAccountMapper.updateSetPassword(accountDetail.getUserId(), encodedNewPasswd, newSalt);
+            userAccountMapper.updateSetPassword(userAccount.getUserId(), encodedNewPasswd, newSalt);
         } catch (Exception e) {
             return Result.fail(e.getMessage());
         }

+ 2 - 3
account/account-service/src/main/java/cn/reghao/tnb/account/app/service/AccountRegistryService.java

@@ -2,8 +2,8 @@ package cn.reghao.tnb.account.app.service;
 
 import cn.reghao.jutil.jdk.result.Result;
 import cn.reghao.tnb.account.api.dto.AdminCreateAccount;
-import cn.reghao.tnb.account.app.model.dto.AccountDetail;
 import cn.reghao.tnb.account.app.model.dto.UserRegisterDto;
+import cn.reghao.tnb.account.app.model.po.UserAccount;
 
 /**
  * @author reghao
@@ -11,7 +11,6 @@ import cn.reghao.tnb.account.app.model.dto.UserRegisterDto;
  */
 public interface AccountRegistryService {
     Result createAccount(UserRegisterDto userRegisterDto);
-    AccountDetail createAccount(String principal, String password);
+    UserAccount createAccount(String principal, String password);
     void createAccount(AdminCreateAccount adminCreateAccount);
-    Result getRegistryStatus();
 }

+ 1 - 1
account/account-service/src/main/java/cn/reghao/tnb/account/app/service/AccountTokenService.java

@@ -40,7 +40,7 @@ public interface AccountTokenService {
     void clearCookie();
 
     /**
-     * 删除与与用户关联的所有设备的登数据
+     * 删除与与用户关联的所有设备的登数据
      *
      * @param
      * @return

+ 3 - 3
account/account-service/src/main/java/cn/reghao/tnb/account/app/service/CodeService.java

@@ -6,7 +6,7 @@ import cn.reghao.jutil.jdk.string.StringRegexp;
 import cn.reghao.tnb.account.api.constant.VerifyChannel;
 import cn.reghao.tnb.account.api.dto.VerifyCode;
 import cn.reghao.tnb.account.app.db.repository.AccountRepository;
-import cn.reghao.tnb.account.app.middleware.RabbitProducer;
+import cn.reghao.tnb.account.app.util.RabbitProducer;
 import cn.reghao.tnb.account.app.model.po.UserAccount;
 import cn.reghao.tnb.account.app.model.po.UserRegistry;
 import cn.reghao.tnb.account.app.util.CaptchaUtil;
@@ -81,9 +81,9 @@ public class CodeService {
             } else {
                 UserAccount userAccount = null;
                 if (type == NotifyType.email.getValue()) {
-                    userAccount = accountRepository.findByEmail(type, receiver);
+                    userAccount = accountRepository.getUserAccountByEmail(receiver);
                 } else if (type == NotifyType.mobile.getValue()) {
-                    userAccount = accountRepository.findByEmail(type, receiver);
+                    userAccount = accountRepository.getUserAccountByMobile(receiver);
                 }
 
                 if (userAccount != null) {

+ 1 - 1
account/account-service/src/main/java/cn/reghao/tnb/account/app/service/PubkeyService.java

@@ -50,7 +50,7 @@ public class PubkeyService {
 
         String r = redisString.get(RedisKeys.getPubkeyRKey());
         if (r == null) {
-            String msg = "当前会话已过期, 请刷新页面后重新登. 或者检查浏览器是否禁用了 cookie";
+            String msg = "当前会话已过期, 请刷新页面后重新登. 或者检查浏览器是否禁用了 cookie";
             throw new Exception(msg);
         }
 

+ 18 - 20
account/account-service/src/main/java/cn/reghao/tnb/account/app/service/impl/AccountLoginServiceImpl.java

@@ -1,15 +1,14 @@
 package cn.reghao.tnb.account.app.service.impl;
 
 import cn.reghao.tnb.account.api.constant.VerifyChannel;
+import cn.reghao.tnb.account.app.db.repository.AccountRepository;
 import cn.reghao.tnb.account.app.model.constant.LoginType;
 import cn.reghao.tnb.account.app.model.dto.AccountLoginDto;
-import cn.reghao.tnb.account.app.model.vo.UserDetail;
+import cn.reghao.tnb.account.app.model.po.UserAccount;
 import cn.reghao.tnb.account.app.service.AccountLoginService;
 import cn.reghao.tnb.account.app.service.LoginAttemptService;
-import cn.reghao.tnb.account.app.db.query.UserAuthQuery;
 import cn.reghao.tnb.account.app.security.exception.AccountLoginException;
 import cn.reghao.tnb.account.app.security.form.AccountAuthToken;
-import cn.reghao.tnb.account.app.model.dto.AccountDetail;
 import cn.reghao.tnb.account.app.service.*;
 import cn.reghao.jutil.jdk.string.StringRegexp;
 import org.springframework.security.authentication.DisabledException;
@@ -27,17 +26,17 @@ import java.util.UUID;
  */
 @Service
 public class AccountLoginServiceImpl implements AccountLoginService {
-    private final UserAuthQuery userAuthQuery;
+    private final AccountRepository accountRepository;
     private final CodeService codeService;
     private final PubkeyService pubkeyService;
     private final AccountRegistryService accountRegistryService;
     private final LoginAttemptService loginAttemptService;
     private final PasswordEncoder passwordEncoder;
 
-    public AccountLoginServiceImpl(UserAuthQuery userAuthQuery, CodeService codeService, PubkeyService pubkeyService,
+    public AccountLoginServiceImpl(AccountRepository accountRepository, CodeService codeService, PubkeyService pubkeyService,
                                    AccountRegistryService accountRegistryService, LoginAttemptService loginAttemptService,
                                    PasswordEncoder passwordEncoder) {
-        this.userAuthQuery = userAuthQuery;
+        this.accountRepository = accountRepository;
         this.codeService = codeService;
         this.pubkeyService = pubkeyService;
         this.accountRegistryService = accountRegistryService;
@@ -56,7 +55,7 @@ public class AccountLoginServiceImpl implements AccountLoginService {
 
         String savedCaptchaCode = codeService.getCaptcha();
         if (savedCaptchaCode == null) {
-            String errMsg = "当前会话已过期, 请刷新页面后重新登. 或者检查浏览器是否禁用了 cookie";
+            String errMsg = "当前会话已过期, 请刷新页面后重新登. 或者检查浏览器是否禁用了 cookie";
             throw new PreAuthenticatedCredentialsNotFoundException(errMsg);
         } else if (!savedCaptchaCode.equalsIgnoreCase(captchaCode)) {
             String errMsg = "图形验证码不正确...";
@@ -76,26 +75,26 @@ public class AccountLoginServiceImpl implements AccountLoginService {
 
     @Override
     public UserDetails loadUserByUsername(String username) throws UsernameNotFoundException {
-        AccountDetail accountDetail;
+        UserAccount userAccount;
         if (StringRegexp.matchEmail(username)) {
-            accountDetail = userAuthQuery.findByEmail(username);
+            userAccount = accountRepository.getUserAccountByEmail(username);
         } else if (StringRegexp.matchMobile(username)) {
-            accountDetail = userAuthQuery.findByMobile(username);
+            userAccount = accountRepository.getUserAccountByMobile(username);
         } else {
-            accountDetail = userAuthQuery.findByUsername(username);
+            userAccount = accountRepository.getUserAccountByUsername(username);
         }
 
-        if (accountDetail == null) {
+        if (userAccount == null) {
             String errMsg = String.format("帐号 %s 未注册", username);
             throw new UsernameNotFoundException(errMsg);
         }
-        return new UserDetail(accountDetail);
+        return userAccount;
     }
 
     @Override
     public AccountAuthToken authByPassword(AccountAuthToken authToken) {
         String username = (String) authToken.getPrincipal();
-        UserDetail userDetail = (UserDetail) loadUserByUsername(username);
+        UserAccount userDetail = (UserAccount) loadUserByUsername(username);
         long userId = userDetail.getUserId();
         int plat = authToken.getPlat();
         loginAttemptService.check(userId, plat);
@@ -112,7 +111,7 @@ public class AccountLoginServiceImpl implements AccountLoginService {
     }
 
     /**
-     * TODO 手机号验证码登, 手机号不存在则自动注册
+     * TODO 手机号验证码登, 手机号不存在则自动注册
      *
      * @param
      * @return
@@ -124,12 +123,12 @@ public class AccountLoginServiceImpl implements AccountLoginService {
         String principal = (String) authToken.getPrincipal();
         String credential = (String) authToken.getCredentials();
 
-        UserDetail userDetail;
+        UserAccount userDetail;
         try {
-            userDetail = (UserDetail) loadUserByUsername(principal);
+            userDetail = (UserAccount) loadUserByUsername(principal);
             String savedCredential = codeService.getVerifyCode(VerifyChannel.loginChannel.getValue(), principal);
             if (savedCredential == null) {
-                String errMsg = "当前会话已过期, 请刷新页面后重新登. 或者检查浏览器是否禁用了 cookie";
+                String errMsg = "当前会话已过期, 请刷新页面后重新登. 或者检查浏览器是否禁用了 cookie";
                 throw new DisabledException(errMsg);
             } else if (!credential.equals(savedCredential)) {
                 String errMsg = "短信验证码不正确";
@@ -143,8 +142,7 @@ public class AccountLoginServiceImpl implements AccountLoginService {
             }
         } catch (UsernameNotFoundException e) {
             // 验证码方式登入时帐号不存在则自动注册
-            AccountDetail accountDetail = accountRegistryService.createAccount(principal, "");
-            userDetail = new UserDetail(accountDetail);
+            userDetail = accountRegistryService.createAccount(principal, "");
         }
 
         userDetail.setLoginType(LoginType.mobileCode.getValue());

+ 4 - 5
account/account-service/src/main/java/cn/reghao/tnb/account/app/service/impl/AccountRegistryServiceImpl.java

@@ -6,7 +6,6 @@ import cn.reghao.jutil.jdk.security.RandomString;
 import cn.reghao.jutil.jdk.string.StringRegexp;
 import cn.reghao.tnb.account.api.constant.VerifyChannel;
 import cn.reghao.tnb.account.api.dto.AdminCreateAccount;
-import cn.reghao.tnb.account.app.model.dto.AccountDetail;
 import cn.reghao.tnb.account.app.model.dto.UserRegisterDto;
 import cn.reghao.tnb.account.app.db.repository.AccountRepository;
 import cn.reghao.tnb.account.app.model.po.UserRegistry;
@@ -53,7 +52,7 @@ public class AccountRegistryServiceImpl implements AccountRegistryService {
         String captchaCode = userRegisterDto.getCaptchaCode();
         String savedCaptchaCode = codeService.getCaptcha();
         if (savedCaptchaCode == null) {
-            return Result.fail("当前会话已过期, 请刷新页面后重新登. 或者检查浏览器是否禁用了 cookie");
+            return Result.fail("当前会话已过期, 请刷新页面后重新登. 或者检查浏览器是否禁用了 cookie");
         } else if (!captchaCode.equalsIgnoreCase(savedCaptchaCode)) {
             return Result.fail("图形验证码不正确, 请刷新页面后重新获取");
         }
@@ -62,7 +61,7 @@ public class AccountRegistryServiceImpl implements AccountRegistryService {
         String verifyCode = userRegisterDto.getVerifyCode();
         String savedVerifyCode = codeService.getVerifyCode(VerifyChannel.registryChannel.getValue(), principal);
         if (savedVerifyCode == null) {
-            return Result.fail("当前会话已过期, 请刷新页面后重新登. 或者检查浏览器是否禁用了 cookie");
+            return Result.fail("当前会话已过期, 请刷新页面后重新登. 或者检查浏览器是否禁用了 cookie");
         } else if (!verifyCode.equalsIgnoreCase(savedVerifyCode)) {
             return Result.fail("短信验证码不正确, 请重新获取");
         }
@@ -123,7 +122,7 @@ public class AccountRegistryServiceImpl implements AccountRegistryService {
     }
 
     @Override
-    public AccountDetail createAccount(String principal, String password) {
+    public UserAccount createAccount(String principal, String password) {
         String email = null;
         String mobile = null;
         if (StringRegexp.matchEmail(principal)) {
@@ -135,7 +134,7 @@ public class AccountRegistryServiceImpl implements AccountRegistryService {
         long userId = getNextUserId();
         UserAccount userAccount = new UserAccount(userId, email, mobile, avatarUrl);
         accountRepository.saveAccount(userAccount);
-        return accountRepository.getUserDetailByMobile(mobile);
+        return accountRepository.getUserAccountByMobile(mobile);
     }
 
     public Result getRegistryStatus() {

+ 3 - 5
account/account-service/src/main/java/cn/reghao/tnb/account/app/service/impl/AccountTokenServiceImpl.java

@@ -4,7 +4,6 @@ import cn.reghao.jutil.jdk.security.RandomString;
 import cn.reghao.jutil.jdk.security.RsaCryptor;
 import cn.reghao.jutil.jdk.string.IDObfuscation;
 import cn.reghao.tnb.account.api.constant.TokenType;
-import cn.reghao.tnb.account.api.iface.AccountQuery;
 import cn.reghao.tnb.account.app.db.mapper.LoginAttemptsMapper;
 import cn.reghao.tnb.account.app.model.constant.LoginPlat;
 import cn.reghao.tnb.account.api.dto.AccountInfo;
@@ -82,8 +81,7 @@ public class AccountTokenServiceImpl implements AccountTokenService {
     public AccountAuthToken getAuthedToken() {
         Authentication authentication = SecurityContextHolder.getContext().getAuthentication();
         if (authentication instanceof AccountAuthToken) {
-            AccountAuthToken authToken = (AccountAuthToken) SecurityContextHolder.getContext().getAuthentication();
-            return authToken;
+            return (AccountAuthToken) SecurityContextHolder.getContext().getAuthentication();
         }
 
         return null;
@@ -217,7 +215,7 @@ public class AccountTokenServiceImpl implements AccountTokenService {
     }
 
     private void deleteSession(long userId, int plat, String loginId, boolean deleteSession) {
-        if (LoginPlat.android.getValue() == plat) {
+        if (LoginPlat.rest.getValue() == plat) {
             revokeUserToken(userId, plat, loginId);
         }
 
@@ -243,7 +241,7 @@ public class AccountTokenServiceImpl implements AccountTokenService {
             String loginId = authToken.getLoginId();
             if (LoginPlat.web.getValue() == plat) {
                 clearCookie();
-            } else if (LoginPlat.android.getValue() == plat) {
+            } else if (LoginPlat.rest.getValue() == plat) {
                 revokeUserToken(userId, plat, loginId);
             }
 

+ 3 - 3
account/account-service/src/main/java/cn/reghao/tnb/account/app/service/impl/LoginAttemptServiceImpl.java

@@ -47,7 +47,7 @@ public class LoginAttemptServiceImpl implements LoginAttemptService {
         String redisKey = RedisKeys.getLoginFailedLockKey(String.valueOf(userId), plat);
         boolean exist = redisOps.exists(redisKey);
         if (exist) {
-            String errMsg = "登录错误次数超过限制,请一个小时后再尝试登录";
+            String errMsg = "登入错误次数超过限制,请一个小时后再尝试登入";
             throw new PreAuthenticatedCredentialsNotFoundException(errMsg);
         }
     }
@@ -65,7 +65,7 @@ public class LoginAttemptServiceImpl implements LoginAttemptService {
 
             String oldestSession = sortedMap.get(sortedMap.firstKey());
             redisOps.del(oldestSession);
-            //String errMsg = "您在本平台登录的设备数量已超过最大限制, 请注销一些设备后再尝试登录";
+            //String errMsg = "您在本平台登入的设备数量已超过最大限制, 请注销一些设备后再尝试登入";
             //throw new PreAuthenticatedCredentialsNotFoundException(errMsg);
         }
     }
@@ -83,7 +83,7 @@ public class LoginAttemptServiceImpl implements LoginAttemptService {
             if (failedCount >= 3) {
                 long timeout = 600;
                 redisString.setWithTimeout(RedisKeys.getLoginFailedLockKey(userIdStr, plat), "failed-lock", timeout);
-                String errMsg = "登录错误次数超过限制,请一个小时后再尝试登录";
+                String errMsg = "登入错误次数超过限制,请一个小时后再尝试登入";
                 return Result.fail(errMsg);
             }
         }

+ 1 - 1
account/account-service/src/main/java/cn/reghao/tnb/account/app/middleware/RabbitProducer.java → account/account-service/src/main/java/cn/reghao/tnb/account/app/util/RabbitProducer.java

@@ -1,4 +1,4 @@
-package cn.reghao.tnb.account.app.middleware;
+package cn.reghao.tnb.account.app.util;
 
 import cn.reghao.jutil.jdk.serializer.JsonConverter;
 import cn.reghao.tnb.message.api.dto.msg.LoginMessage;

+ 14 - 18
account/account-service/src/main/resources/mapper/UserAccountMapper.xml

@@ -62,14 +62,25 @@
         select max(mobile) from user_account
         where mobile like '129%'
     </select>
+    <select id="findByUsername" resultType="cn.reghao.tnb.account.app.model.po.UserAccount">
+        select *
+        from user_account
+        where username=#{username}
+    </select>
     <select id="findByEmail" resultType="cn.reghao.tnb.account.app.model.po.UserAccount">
-        select * from user_account where email=#{email}
+        select *
+        from user_account
+        where email=#{email}
     </select>
     <select id="findByMobile" resultType="cn.reghao.tnb.account.app.model.po.UserAccount">
-        select * from user_account where mobile=#{mobile}
+        select *
+        from user_account
+        where mobile=#{mobile}
     </select>
     <select id="findUserIdByUsername" resultType="java.lang.Long">
-        select user_id from user_account where username=#{username}
+        select user_id
+        from user_account
+        where username=#{username}
     </select>
     <select id="findAccountInfo" resultType="cn.reghao.tnb.account.api.dto.AccountInfo">
         select user_id,screen_name,avatar_url,username,mobile,email
@@ -81,21 +92,6 @@
         from user_account
         where user_id=#{userId}
     </select>
-    <select id="findByUsername" resultType="cn.reghao.tnb.account.app.model.dto.AccountDetail">
-        select *
-        from user_account
-        where username=#{username}
-    </select>
-    <select id="findByEmail1" resultType="cn.reghao.tnb.account.app.model.dto.AccountDetail">
-        select *
-        from user_account
-        where email=#{email}
-    </select>
-    <select id="findByMobile1" resultType="cn.reghao.tnb.account.app.model.dto.AccountDetail">
-        select *
-        from user_account
-        where mobile=#{mobile}
-    </select>
     <select id="findUserInfo" resultType="cn.reghao.tnb.account.api.dto.AccountInfo">
         select user_id,screen_name,avatar_url,username,mobile,email
         from user_account

+ 20 - 0
account/account-service/src/main/resources/mapper/UserAccountRoleMapper.xml

@@ -2,6 +2,26 @@
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 
 <mapper namespace="cn.reghao.tnb.account.app.db.mapper.UserAccountRoleMapper">
+    <insert id="save">
+        insert into user_account_role
+        (`user_id`,`name`)
+        values
+        (#{userId},#{name})
+    </insert>
+    <insert id="saveAll" useGeneratedKeys="true" keyProperty="id">
+        insert into user_account_role
+        (`user_id`,`name`)
+        values
+        <foreach collection="list" item="item" index="index" separator=",">
+            (#{item.userId},#{item.name})
+        </foreach>
+    </insert>
+
+    <select id="findByUserId" resultType="cn.reghao.tnb.account.app.model.po.UserAccountRole">
+        select *
+        from user_account_role
+        where user_id=#{userId}
+    </select>
     <select id="findByIds" resultType="cn.reghao.tnb.account.app.model.po.UserAccountRole">
         select *
         from user_account_role

+ 0 - 12
account/account-service/src/main/resources/menu.json

@@ -1,12 +0,0 @@
-[
-  {
-    "icon": "fa fa-tags icon-xlarge",
-    "name": "登录历史",
-    "url": "admin/account/record/list"
-  },
-  {
-    "icon": "fa fa-clone icon-xlarge",
-    "name": "OAuthApp",
-    "url": "admin/account/oauth/list"
-  }
-]

+ 3 - 4
account/account-service/src/main/resources/templates/auth/login.ftl

@@ -1,6 +1,6 @@
 <@layout.extends name="/inc/layout.ftl">
     <@layout.put block="title">
-        <title>登</title>
+        <title>登</title>
     </@layout.put>
 
     <@layout.put block="contents">
@@ -31,7 +31,7 @@
                             </div>
                             <div class="form-group">
                                 <label>
-                                    <input type="checkbox" name="rememberMe" value="1"> 记住登
+                                    <input type="checkbox" name="rememberMe" value="1"> 记住登
                                 </label>
                             </div>
                             <div class="form-group">
@@ -101,8 +101,7 @@
                     success: function(resp) {
                         // 处理表单提交成功后的响应
                         if (resp.code === 0) {
-                            let redirectPath = resp.data.redirectPath
-                            window.location.replace(redirectPath)
+                            window.location.replace('/')
                         } else {
                             layer.msg(resp.msg, {icon: 2});
                         }

+ 1 - 1
account/account-service/src/main/resources/templates/inc/footer.ftl

@@ -7,7 +7,7 @@
                 </a>
             </nav>
             <div class="gh-foot-min-back hidden-xs hidden-sm">
-                <span class="footer-nav-item">Powered by <a href="https://git.reghao.cn/reghao" target="_blank">reghao</a></span>
+                <span class="footer-nav-item">Powered by <a href="#" target="_blank">reghao</a></span>
             </div>
         </div>
     </div>

+ 2 - 2
account/account-service/src/main/resources/templates/inc/header.ftl

@@ -26,8 +26,8 @@
             </div>
             <div class="collapse navbar-collapse">
                 <ul class="navbar-button list-inline" id="header_user">
-                    <#if profile != null>
-                        <li><a href="/logout" class="btn btn-default btn-sm signup">登出</a></li>
+                    <#if userId != null>
+                        <li><a href="/api/auth/signout" class="btn btn-default btn-sm signup">登出</a></li>
                     <#else>
                         <li><a href="/login" class="btn btn-default btn-sm signup">登入</a></li>
                     </#if>

+ 3 - 3
account/account-service/src/main/resources/templates/index.ftl

@@ -8,9 +8,9 @@
             <div class="col-md-4 col-md-offset-4 floating-box">
                 <div class="panel panel-default">
                     <div class="panel-heading">
-                        <h3 class="panel-title">登状态</h3>
-                        <#if profile != null>
-                            <h3>用户 ${profile.username} 登入</h3>
+                        <h3 class="panel-title">登状态</h3>
+                        <#if userId != null>
+                            <h3>当登入用户 ID: <span style="color: red">${userId}</span></h3>
                         <#else>
                             <h3>匿名访问</h3>
                         </#if>

+ 2 - 2
account/account-service/src/test/java/UserAccountTest.java

@@ -60,8 +60,8 @@ public class UserAccountTest {
     public void oauthTest() {
         OAuthAppDto authAppDto = new OAuthAppDto();
         authAppDto.setName("gateway");
-        authAppDto.setHomeUrl("https://cili.reghao.cn");
-        authAppDto.setCallbackUrl("https://cili.reghao.cn/callback");
+        authAppDto.setHomeUrl("");
+        authAppDto.setCallbackUrl("");
         oAuthAppService.create(authAppDto);
     }
 }

+ 1 - 2
content/content-service/src/main/java/cn/reghao/tnb/content/app/config/SpringDocConfig.java

@@ -24,7 +24,6 @@ public class SpringDocConfig {
                         .version("v0.0.1")
                         .license(new License().name("Apache 2.0").url("https://www.apache.org/licenses/LICENSE-2.0")))
                 .externalDocs(new ExternalDocumentation()
-                        .description("content api")
-                        .url("https://git.reghao.cn/reghao/tnb"));
+                        .description("content api"));
     }
 }

+ 0 - 17
content/content-service/src/test/java/cn/reghao/tnb/content/app/geo/service/GeoTest.java

@@ -121,23 +121,6 @@ public class GeoTest {
         return sb.toString().trim();
     }
 
-
-    OssConsoleClient getOssConsoleClient() {
-        String consoleUrl = "http://bnt.reghao.cn";
-        String accessKeyId = "ESCKn3Cd";
-        String accessKeySecret = "OL9SIOLoOqUjhMiQMv";
-        int videoChannelId = 101;
-        OssConsoleConfig ossConsoleConfig = new OssConsoleConfig(consoleUrl, accessKeyId, accessKeySecret);
-        try {
-            OssConsoleClient ossConsoleClient = new OssConsoleClient(ossConsoleConfig);
-            return ossConsoleClient;
-        } catch (Exception e) {
-            e.printStackTrace();
-        }
-
-        return null;
-    }
-
     @Autowired
     CameraPhotoMapper cameraPhotoMapper;
     @Test

+ 0 - 8
content/content-service/src/test/java/cn/reghao/tnb/content/app/vod/service/VideoPostTest.java

@@ -247,14 +247,6 @@ public class VideoPostTest {
                         break;
                     }
                 }
-
-                if (contain) {
-                    for (VideoPost  videoPost : v) {
-                        String url = String.format("https://reghao.cn/video/%s", videoPost.getVideoId());
-                        sb.append(url).append(" - ");
-                    }
-                    urls.add(sb.toString());
-                }
             }
         });
 

+ 0 - 5
eureka/eureka-server/pom.xml

@@ -24,11 +24,6 @@
             <version>1.0.0-SNAPSHOT</version>
         </dependency>
 
-        <dependency>
-            <groupId>org.springframework.boot</groupId>
-            <artifactId>spring-boot-starter-web</artifactId>
-        </dependency>
-
         <dependency>
             <groupId>org.springframework.cloud</groupId>
             <artifactId>spring-cloud-starter-netflix-eureka-server</artifactId>

+ 2 - 2
file/file-service/src/main/java/cn/reghao/tnb/file/app/config/AppProperties.java

@@ -15,9 +15,9 @@ import org.springframework.context.annotation.Configuration;
 @Setter
 @Getter
 public class AppProperties {
-    private String siteAddress;
     private Integer ossType;
-    private Integer avatarChannelCode;
+    //private String siteAddress;
+    //private Integer avatarChannelCode;
 
     public AppProperties() {
         this.ossType = OssType.localOss.getCode();

+ 1 - 2
file/file-service/src/main/java/cn/reghao/tnb/file/app/config/SpringDocConfig.java

@@ -24,7 +24,6 @@ public class SpringDocConfig {
                         .version("v0.0.1")
                         .license(new License().name("Apache 2.0").url("https://www.apache.org/licenses/LICENSE-2.0")))
                 .externalDocs(new ExternalDocumentation()
-                        .description("file api")
-                        .url("https://git.reghao.cn/reghao/tnb"));
+                        .description("file api"));
     }
 }

+ 6 - 5
file/file-service/src/main/java/cn/reghao/tnb/file/app/rpc/FileServiceImpl.java

@@ -48,18 +48,19 @@ public class FileServiceImpl implements FileService {
     }
 
     public String getAccountAvatar(long userId) {
-        String text = String.format("%s/user/%s", appProperties.getSiteAddress(), userId);
-        int width = 256;
-        int height = 256;
+        String siteAddr = "";
+        int avatarChannelCode = 0;
+        String text = String.format("%s/user/%s", siteAddr, userId);
+        int width = 128;
+        int height = 128;
         String filePath = String.format("%s/%s.jpg", baseDir, userId);
         String avatarUrl = "";
         try {
             ByteArrayOutputStream baos = ImageUtil.createQRCode(text, width, height);
-            int channelCode = appProperties.getAvatarChannelCode();
             File file = new File(filePath);
             FileUtils.writeByteArrayToFile(file, baos.toByteArray());
             if (ossType == OssType.localOss.getCode()) {
-                avatarUrl = getImageUrl(channelCode, file);
+                avatarUrl = getImageUrl(avatarChannelCode, file);
             }
         } catch (Exception e) {
             e.printStackTrace();

+ 0 - 2
file/file-service/src/main/resources/application.yml

@@ -43,8 +43,6 @@ mybatis:
   mapper-locations: classpath*:mapper/**.xml
   type-aliases-package: cn.reghao.tnb.file.app.model.po
 app:
-  siteAddress: http://tnb.reghao.cn
-  avatarChannelCode: 104
   ossType: 1
 eureka:
   instance:

+ 1 - 2
user/user-service/src/main/java/cn/reghao/tnb/user/app/config/SpringDocConfig.java

@@ -24,7 +24,6 @@ public class SpringDocConfig {
                         .version("v0.0.1")
                         .license(new License().name("Apache 2.0").url("https://www.apache.org/licenses/LICENSE-2.0")))
                 .externalDocs(new ExternalDocumentation()
-                        .description("user api")
-                        .url("https://git.reghao.cn/reghao/tnb"));
+                        .description("user api"));
     }
 }

+ 2 - 4
user/user-service/src/main/java/cn/reghao/tnb/user/app/service/ContactService.java

@@ -44,8 +44,7 @@ public class ContactService {
     public SearchContactResult searchUser(String mobile) {
         AccountInfo accountInfo = accountQuery.getByMobile(mobile);
         if (accountInfo != null) {
-            String userIdStr = accountInfo.getUserId();
-            long userId = accountQuery.getUserIdLong(userIdStr);
+            long userId = accountInfo.getUserId();
             UserInfo userInfo = userProfileService.getUserInfo(userId);
             return new SearchContactResult(userInfo);
         }
@@ -55,8 +54,7 @@ public class ContactService {
 
     public ContactInfoResult getContactInfoResult(long friendId) {
         AccountInfo accountInfo = accountQuery.getAccountInfo(friendId);
-        String userIdStr = accountInfo.getUserId();
-        long userId = accountQuery.getUserIdLong(userIdStr);
+        long userId = accountInfo.getUserId();
         UserInfo userInfo = userProfileService.getUserInfo(userId);
         ContactInfoResult contactInfoResult = new ContactInfoResult(userInfo);
 

+ 1 - 2
user/user-service/src/main/java/cn/reghao/tnb/user/app/service/CrawledUserService.java

@@ -25,8 +25,7 @@ public class CrawledUserService {
     public Long getUserId(String username) {
         AccountInfo accountInfo = accountQuery.getByUsername(username);
         if (accountInfo != null) {
-            String userIdStr = accountInfo.getUserId();
-            long userId = accountQuery.getUserIdLong(userIdStr);
+            long userId = accountInfo.getUserId();
             return userId;
         }
 

+ 0 - 50
user/user-service/src/main/java/cn/reghao/tnb/user/app/service/UserProfileService.java

@@ -1,7 +1,5 @@
 package cn.reghao.tnb.user.app.service;
 
-import cn.reghao.jutil.jdk.db.Page;
-import cn.reghao.jutil.jdk.db.PageList;
 import cn.reghao.tnb.account.api.dto.AccountInfo;
 import cn.reghao.tnb.account.api.iface.AccountQuery;
 import cn.reghao.tnb.common.auth.UserContext;
@@ -15,10 +13,6 @@ import cn.reghao.tnb.user.app.model.po.UserProfile;
 import org.apache.dubbo.config.annotation.DubboReference;
 import org.springframework.stereotype.Service;
 
-import java.util.Collections;
-import java.util.List;
-import java.util.stream.Collectors;
-
 /**
  * @author reghao
  * @date 2022-07-08 17:52:21
@@ -75,36 +69,6 @@ public class UserProfileService {
         return userInfo;
     }
 
-    public PageList<UserInfo> getUsers(int page) {
-        int total = 0;
-        Page page1 = new Page(page, pageSize);
-        List<UserInfo> list = Collections.emptyList();
-        return PageList.pageList(page, pageSize, total, list);
-    }
-
-    public List<UserInfo> getRandomUsers() {
-        List<Long> userIds = userContentService.getContentUser(1);
-        List<AccountInfo> list = accountQuery.getAccountInfos(userIds);
-        return list.stream()
-                .map(accountInfo -> {
-                    String userIdStr = accountInfo.getUserId();
-                    long userId = accountQuery.getUserIdLong(userIdStr);
-                    UserProfile userProfile = userProfileMapper.findByUserId(userId);
-                    if (userProfile == null) {
-                        userProfile = new UserProfile(userId);
-                        userProfileMapper.save(userProfile);
-                    }
-
-                    int gender = userProfile.getGender();
-                    String signature = userProfile.getSignature();
-                    int following = userProfile.getFollowing();
-                    int follower = userProfile.getFollower();
-                    boolean vip = userVipService.isVip(userId);
-                    return new UserInfo(accountInfo, userIdStr, gender, signature, following, follower, vip);
-                })
-                .collect(Collectors.toList());
-    }
-
     public UserCard getUserCard(long userId) {
         long loginUser = UserContext.getUser();
         UserInfo userInfo = getUserInfo(userId);
@@ -113,20 +77,6 @@ public class UserProfileService {
         return new UserCard(userInfo, userIdStr, followed);
     }
 
-    public List<UserCard> getUserCards(List<Long> list) {
-        long loginUser = UserContext.getUser();
-        if (loginUser == -1) {
-            return Collections.emptyList();
-        }
-
-        return list.stream().map(userId -> {
-            UserInfo userInfo = getUserInfo(userId);
-            boolean followed = isFollowing(loginUser, userId);
-            String userIdStr = accountQuery.getUserIdStr(userId);
-            return new UserCard(userInfo, userIdStr, followed);
-        }).collect(Collectors.toList());
-    }
-
     private boolean isFollowing(long loginUserId, long userId) {
         return userRelationMapper.findRelation(loginUserId, userId) != null;
     }

+ 0 - 61
zzz/schema/file_store_config.sql

@@ -1,61 +0,0 @@
--- MySQL dump 10.13  Distrib 5.7.42, for Linux (x86_64)
---
--- Host: 192.168.0.210    Database: tnb_content_tdb
--- ------------------------------------------------------
--- Server version	5.7.36
-
-/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
-/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
-/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
-/*!40101 SET NAMES utf8 */;
-/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
-/*!40103 SET TIME_ZONE='+00:00' */;
-/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
-/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
-/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
-/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
-
---
--- Table structure for table `file_store_config`
---
-
-DROP TABLE IF EXISTS `file_store_config`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `file_store_config` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `oss_type` int(11) NOT NULL,
-  `endpoint` varchar(255) NOT NULL,
-  `access_key_id` varchar(255) NOT NULL,
-  `access_key_secret` varchar(255) NOT NULL,
-  `region` varchar(255) DEFAULT NULL,
-  `bucket_name` varchar(255) DEFAULT NULL,
-  `role_arn` varchar(255) DEFAULT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `oss_type` (`oss_type`)
-) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COMMENT='OSS 存储节点配置';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `file_store_config`
---
-
-LOCK TABLES `file_store_config` WRITE;
-/*!40000 ALTER TABLE `file_store_config` DISABLE KEYS */;
-INSERT INTO `file_store_config` VALUES (1,_binary '\0','2024-11-06 19:12:04.117976','2024-11-06 19:12:04.117976',1,'http://bnt.reghao.cn','ESCKn3Cd','OL9SIOLoOqUjhMiQMv',NULL,NULL,NULL);
-/*!40000 ALTER TABLE `file_store_config` ENABLE KEYS */;
-UNLOCK TABLES;
-/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
-
-/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
-/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
-/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
-/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-
--- Dump completed on 2024-12-15 22:47:21

+ 0 - 59
zzz/schema/msg_email_account.sql

@@ -1,59 +0,0 @@
--- MySQL dump 10.13  Distrib 5.7.42, for Linux (x86_64)
---
--- Host: 192.168.0.210    Database: tnb_account_tdb
--- ------------------------------------------------------
--- Server version	5.7.36
-
-/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
-/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
-/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
-/*!40101 SET NAMES utf8 */;
-/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
-/*!40103 SET TIME_ZONE='+00:00' */;
-/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
-/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
-/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
-/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
-
---
--- Table structure for table `msg_email_account`
---
-
-DROP TABLE IF EXISTS `msg_email_account`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `msg_email_account` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `smtp` varchar(255) NOT NULL,
-  `username` varchar(255) NOT NULL,
-  `password` varchar(255) NOT NULL,
-  `personal` varchar(255) NOT NULL,
-  `default_sender` bit(1) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `username` (`username`)
-) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb4;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `msg_email_account`
---
-
-LOCK TABLES `msg_email_account` WRITE;
-/*!40000 ALTER TABLE `msg_email_account` DISABLE KEYS */;
-INSERT INTO `msg_email_account` VALUES (1,_binary '\0','2024-09-25 15:01:18.832444','2024-09-25 17:18:25.000000','smtp.163.com','gisgit@163.com','sirHdeKYn4PHcMP9','admin@tnb',_binary ''),(2,_binary '\0','2024-09-25 16:08:09.714839','2024-09-25 17:18:51.000000','smtp.gmail.com','reghaodev@gmail.com','122334452525325323','admin@tnb',_binary '\0');
-/*!40000 ALTER TABLE `msg_email_account` ENABLE KEYS */;
-UNLOCK TABLES;
-/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
-
-/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
-/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
-/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
-/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-
--- Dump completed on 2024-12-15 22:47:21

+ 0 - 509
zzz/schema/tnb_account_tdb.sql

@@ -1,509 +0,0 @@
--- MySQL dump 10.13  Distrib 5.7.42, for Linux (x86_64)
---
--- Host: 192.168.0.210    Database: tnb_account_tdb
--- ------------------------------------------------------
--- Server version	5.7.36
-
-/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
-/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
-/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
-/*!40101 SET NAMES utf8 */;
-/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
-/*!40103 SET TIME_ZONE='+00:00' */;
-/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
-/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
-/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
-/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
-
---
--- Table structure for table `chat_group_info`
---
-
-DROP TABLE IF EXISTS `chat_group_info`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `chat_group_info` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL,
-  `create_time` datetime(6) NOT NULL,
-  `update_time` datetime(6) NOT NULL,
-  `group_id` bigint(20) NOT NULL,
-  `name` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
-  `avatar` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
-  `profile` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
-  `owner_id` bigint(20) NOT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `chat_group_member`
---
-
-DROP TABLE IF EXISTS `chat_group_member`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `chat_group_member` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL,
-  `create_time` datetime(6) NOT NULL,
-  `update_time` datetime(6) NOT NULL,
-  `group_id` bigint(20) NOT NULL,
-  `user_id` bigint(20) NOT NULL,
-  `nickname` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
-  `owner` bit(1) DEFAULT NULL,
-  `disturb` bit(1) DEFAULT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `chat_group_notice`
---
-
-DROP TABLE IF EXISTS `chat_group_notice`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `chat_group_notice` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL,
-  `create_time` datetime(6) NOT NULL,
-  `update_time` datetime(6) NOT NULL,
-  `notice_id` int(11) NOT NULL,
-  `group_id` int(11) NOT NULL,
-  `title` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
-  `content` text COLLATE utf8mb4_unicode_ci NOT NULL,
-  `top` bit(1) NOT NULL,
-  `confirmed` bit(1) NOT NULL,
-  `create_by` bigint(20) NOT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `msg_email_account`
---
-
-DROP TABLE IF EXISTS `msg_email_account`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `msg_email_account` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `smtp` varchar(255) NOT NULL,
-  `username` varchar(255) NOT NULL,
-  `password` varchar(255) NOT NULL,
-  `personal` varchar(255) NOT NULL,
-  `default_sender` bit(1) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `username` (`username`)
-) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb4;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `msg_login_attempts`
---
-
-DROP TABLE IF EXISTS `msg_login_attempts`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `msg_login_attempts` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL,
-  `create_time` datetime(6) NOT NULL,
-  `update_time` datetime(6) NOT NULL,
-  `login_id` varchar(255) DEFAULT NULL,
-  `user_id` bigint(20) NOT NULL,
-  `login_type` int(11) DEFAULT NULL,
-  `user_agent` text,
-  `login_ip` varchar(255) DEFAULT NULL,
-  `login_at` datetime(6) DEFAULT NULL,
-  `plat` int(11) DEFAULT NULL,
-  `succeed` bit(1) DEFAULT NULL,
-  `remember_me` bit(1) DEFAULT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `login_id` (`login_id`),
-  KEY `user_id` (`user_id`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=44 DEFAULT CHARSET=utf8mb4 COMMENT='用户登录记录';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `oauth_access_token`
---
-
-DROP TABLE IF EXISTS `oauth_access_token`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `oauth_access_token` (
-  `token_id` varchar(255) DEFAULT NULL COMMENT '加密的access_token的值',
-  `token` longblob COMMENT 'OAuth2AccessToken.java对象序列化后的二进制数据',
-  `authentication_id` varchar(255) DEFAULT NULL COMMENT '加密过的username,client_id,scope',
-  `user_name` varchar(255) DEFAULT NULL COMMENT '登录的用户名',
-  `client_id` varchar(255) DEFAULT NULL COMMENT '客户端ID',
-  `authentication` longblob COMMENT 'OAuth2Authentication.java对象序列化后的二进制数据',
-  `refresh_token` varchar(255) DEFAULT NULL COMMENT '加密的refresh_token的值'
-) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='访问令牌';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `oauth_approvals`
---
-
-DROP TABLE IF EXISTS `oauth_approvals`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `oauth_approvals` (
-  `userId` varchar(255) DEFAULT NULL COMMENT '登录的用户名',
-  `clientId` varchar(255) DEFAULT NULL COMMENT '客户端ID',
-  `scope` varchar(255) DEFAULT NULL COMMENT '申请的权限范围',
-  `status` varchar(10) DEFAULT NULL COMMENT '状态(Approve或Deny)',
-  `expiresAt` datetime DEFAULT NULL COMMENT '过期时间',
-  `lastModifiedAt` datetime DEFAULT NULL COMMENT '最终修改时间'
-) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='授权记录';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `oauth_client_details`
---
-
-DROP TABLE IF EXISTS `oauth_client_details`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `oauth_client_details` (
-  `client_id` varchar(255) NOT NULL COMMENT '客户端 ID',
-  `resource_ids` varchar(255) DEFAULT NULL COMMENT '客户端可访问的资源服务器集合, 使用 '','' 分隔多个资源',
-  `client_secret` varchar(255) DEFAULT NULL COMMENT '客户端密匙',
-  `scope` varchar(255) DEFAULT NULL COMMENT '客户端可访问的资源服务器范围, 空值表示可访问资源服务器上的所有资源',
-  `authorized_grant_types` varchar(255) DEFAULT NULL COMMENT '客户端支持的 OAuth2.0 授权类型',
-  `web_server_redirect_uri` varchar(255) DEFAULT NULL COMMENT '授权服务器认证通过后重定向到客户端的 URI',
-  `authorities` varchar(255) DEFAULT NULL COMMENT '客户端拥有的 Spring Security 权限, 使用 '','' 分隔多个权限',
-  `access_token_validity` int(11) DEFAULT NULL COMMENT '访问令牌有效时间值(单位:秒)',
-  `refresh_token_validity` int(11) DEFAULT NULL COMMENT '更新令牌有效时间值(单位:秒)',
-  `additional_information` varchar(255) DEFAULT NULL COMMENT '预留字段',
-  `autoapprove` varchar(255) DEFAULT NULL COMMENT '用户是否自动 Approval 操作'
-) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='客户端信息';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `oauth_client_token`
---
-
-DROP TABLE IF EXISTS `oauth_client_token`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `oauth_client_token` (
-  `token_id` varchar(255) DEFAULT NULL COMMENT '加密的access_token值',
-  `token` longblob COMMENT 'OAuth2AccessToken.java对象序列化后的二进制数据',
-  `authentication_id` varchar(255) DEFAULT NULL COMMENT '加密过的username,client_id,scope',
-  `user_name` varchar(255) DEFAULT NULL COMMENT '登录的用户名',
-  `client_id` varchar(255) DEFAULT NULL COMMENT '客户端ID'
-) ENGINE=InnoDB DEFAULT CHARSET=utf8;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `oauth_code`
---
-
-DROP TABLE IF EXISTS `oauth_code`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `oauth_code` (
-  `code` varchar(255) DEFAULT NULL COMMENT '授权码(未加密)',
-  `authentication` varbinary(255) DEFAULT NULL COMMENT 'AuthorizationRequestHolder.java对象序列化后的二进制数据'
-) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='授权码';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `oauth_refresh_token`
---
-
-DROP TABLE IF EXISTS `oauth_refresh_token`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `oauth_refresh_token` (
-  `token_id` varchar(255) DEFAULT NULL COMMENT '加密过的refresh_token的值',
-  `token` longblob COMMENT 'OAuth2RefreshToken.java对象序列化后的二进制数据 ',
-  `authentication` longblob COMMENT 'OAuth2Authentication.java对象序列化后的二进制数据'
-) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='更新令牌';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `oauth_user_oauth_app`
---
-
-DROP TABLE IF EXISTS `oauth_user_oauth_app`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `oauth_user_oauth_app` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL,
-  `create_time` datetime(6) NOT NULL,
-  `update_time` datetime(6) NOT NULL,
-  `user_id` bigint(20) NOT NULL,
-  `app_name` varchar(255) NOT NULL,
-  `home_url` varchar(255) NOT NULL,
-  `client_id` varchar(255) NOT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `user_account`
---
-
-DROP TABLE IF EXISTS `user_account`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `user_account` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `user_id` bigint(20) NOT NULL COMMENT '用户 ID, 全局唯一',
-  `account_type` tinyint(11) NOT NULL COMMENT '帐号类型, AccountType 枚举类',
-  `username` varchar(255) NOT NULL COMMENT '用户名, 全局唯一',
-  `mobile` varchar(13) DEFAULT NULL COMMENT '手机号, 全局唯一',
-  `email` varchar(255) DEFAULT NULL COMMENT '邮箱, 全局唯一',
-  `encoded_password` varchar(255) DEFAULT NULL,
-  `salt` varchar(255) DEFAULT NULL,
-  `create_at` datetime(6) NOT NULL COMMENT '帐号创建时间',
-  `role` varchar(255) DEFAULT NULL,
-  `enabled` bit(1) NOT NULL COMMENT 'spring-security 字段',
-  `locked` bit(1) NOT NULL COMMENT 'spring-security 字段',
-  `screen_name` varchar(255) DEFAULT NULL,
-  `avatar_url` varchar(255) DEFAULT NULL,
-  `notify` bit(1) DEFAULT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `user_id` (`user_id`) USING BTREE,
-  UNIQUE KEY `username` (`username`) USING BTREE,
-  UNIQUE KEY `email` (`email`) USING BTREE,
-  UNIQUE KEY `mobile` (`mobile`) USING BTREE,
-  UNIQUE KEY `index_screen_name` (`screen_name`),
-  KEY `account_type` (`account_type`)
-) ENGINE=InnoDB AUTO_INCREMENT=2057872 DEFAULT CHARSET=utf8mb4 COMMENT='用户帐号';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `user_contact`
---
-
-DROP TABLE IF EXISTS `user_contact`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `user_contact` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `friend_id` bigint(20) NOT NULL,
-  `remark_name` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '备注名',
-  `status` int(10) NOT NULL COMMENT '关系状态',
-  `owner` bigint(20) NOT NULL,
-  PRIMARY KEY (`id`),
-  KEY `user_id` (`owner`) USING BTREE,
-  KEY `friend_id` (`friend_id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='联系人';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `user_contact_record`
---
-
-DROP TABLE IF EXISTS `user_contact_record`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `user_contact_record` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `apply_id` bigint(20) DEFAULT NULL,
-  `apply_user` bigint(20) NOT NULL,
-  `applied_user` bigint(20) NOT NULL,
-  `friend_status` int(10) DEFAULT NULL,
-  `apply_status` int(10) NOT NULL,
-  `remark` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
-  PRIMARY KEY (`id`),
-  KEY `user_id` (`apply_user`) USING BTREE,
-  KEY `friend_id` (`applied_user`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='联系人申请记录';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `user_message`
---
-
-DROP TABLE IF EXISTS `user_message`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `user_message` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `msg_type` int(11) DEFAULT NULL,
-  `message_id` bigint(20) NOT NULL,
-  `title` varchar(255) NOT NULL,
-  `content` varchar(255) NOT NULL,
-  `unread` bit(1) NOT NULL,
-  `user_id` bigint(20) NOT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb4 COMMENT='用户消息';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `user_profile`
---
-
-DROP TABLE IF EXISTS `user_profile`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `user_profile` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `user_id` bigint(20) NOT NULL,
-  `gender` varchar(255) NOT NULL,
-  `signature` varchar(255) DEFAULT NULL COMMENT '用户自我介绍',
-  `following` int(11) NOT NULL,
-  `follower` int(11) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `user_id` (`user_id`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=263920 DEFAULT CHARSET=utf8mb4 COMMENT='用户信息';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `user_registry`
---
-
-DROP TABLE IF EXISTS `user_registry`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `user_registry` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `enabled` bit(1) NOT NULL COMMENT '是否开放注册',
-  `rule` varchar(255) NOT NULL COMMENT '开放注册规则',
-  `captcha_code` varchar(255) NOT NULL,
-  `verify_code` varchar(255) NOT NULL,
-  `enable_code` bit(1) NOT NULL,
-  `domain` varchar(255) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `user_id` (`enabled`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COMMENT='帐号开放注册规则';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `user_relation`
---
-
-DROP TABLE IF EXISTS `user_relation`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `user_relation` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL,
-  `create_time` datetime(6) NOT NULL ON UPDATE CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL ON UPDATE CURRENT_TIMESTAMP(6),
-  `user_id` bigint(20) NOT NULL,
-  `following_id` bigint(20) NOT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='用户关系';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `user_vip`
---
-
-DROP TABLE IF EXISTS `user_vip`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `user_vip` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `user_id` bigint(20) NOT NULL COMMENT '用户 ID',
-  `expire_at` bigint(20) NOT NULL COMMENT 'VIP 用户过期时间',
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `user_id` (`user_id`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb4 COMMENT='小会员用户';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `user_vip_plan`
---
-
-DROP TABLE IF EXISTS `user_vip_plan`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `user_vip_plan` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `plan_id` int(11) NOT NULL,
-  `name` varchar(255) NOT NULL,
-  `price` double NOT NULL,
-  `duration` int(11) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `owner` (`plan_id`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb4 COMMENT='小会员计划';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `user_wallet_bill`
---
-
-DROP TABLE IF EXISTS `user_wallet_bill`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `user_wallet_bill` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `type` int(11) NOT NULL COMMENT '1 - 收入, 2 - 支出',
-  `quantity` double NOT NULL,
-  `create_at` datetime(6) NOT NULL,
-  `owner` bigint(20) NOT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8mb4 COMMENT='用户钱包账单';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `user_wallet_charge`
---
-
-DROP TABLE IF EXISTS `user_wallet_charge`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `user_wallet_charge` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `charge_id` bigint(20) NOT NULL,
-  `quantity` double NOT NULL,
-  `owner` bigint(20) NOT NULL,
-  `status` int(11) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `owner` (`charge_id`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb4 COMMENT='用户钱包充值';
-/*!40101 SET character_set_client = @saved_cs_client */;
-/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
-
-/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
-/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
-/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
-/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-
--- Dump completed on 2024-12-15 22:47:20

+ 0 - 1039
zzz/schema/tnb_content_tdb.sql

@@ -1,1039 +0,0 @@
--- MySQL dump 10.13  Distrib 5.7.42, for Linux (x86_64)
---
--- Host: 192.168.0.210    Database: tnb_content_tdb
--- ------------------------------------------------------
--- Server version	5.7.36
-
-/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
-/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
-/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
-/*!40101 SET NAMES utf8 */;
-/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
-/*!40103 SET TIME_ZONE='+00:00' */;
-/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
-/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
-/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
-/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
-
---
--- Table structure for table `audio_file`
---
-
-DROP TABLE IF EXISTS `audio_file`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `audio_file` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `audio_file_id` varchar(255) NOT NULL,
-  `object_id` varchar(255) NOT NULL,
-  `duration` int(11) NOT NULL,
-  `codec` varchar(255) NOT NULL,
-  `bit_rate` bigint(20) NOT NULL,
-  `url` varchar(255) NOT NULL,
-  PRIMARY KEY (`id`),
-  KEY `object_id` (`object_id`)
-) ENGINE=InnoDB AUTO_INCREMENT=537 DEFAULT CHARSET=utf8mb4 COMMENT='音频文件';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `audio_post`
---
-
-DROP TABLE IF EXISTS `audio_post`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `audio_post` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `audio_id` varchar(255) NOT NULL,
-  `audio_file_id` varchar(255) NOT NULL,
-  `audio_url` varchar(255) NOT NULL,
-  `codec` varchar(255) DEFAULT NULL,
-  `title` varchar(255) NOT NULL,
-  `duration` int(11) NOT NULL,
-  `scope` int(11) NOT NULL,
-  `publish_at` datetime NOT NULL,
-  `publish_by` bigint(20) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `UK_rfuvf3osnlaakifjdao0a8e2x` (`audio_id`) USING BTREE,
-  KEY `file_id` (`audio_file_id`) USING BTREE,
-  KEY `user_id` (`publish_by`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=465 DEFAULT CHARSET=utf8mb4 COMMENT='音频稿件';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `chat_chat_dialog`
---
-
-DROP TABLE IF EXISTS `chat_chat_dialog`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `chat_chat_dialog` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `chat_id` bigint(20) NOT NULL,
-  `chat_type` int(10) NOT NULL,
-  `user_id` bigint(20) NOT NULL COMMENT '消息发送者',
-  `receiver_id` bigint(20) NOT NULL COMMENT '消息接收者',
-  `disturb` bit(1) NOT NULL COMMENT '对话框是否免打扰',
-  `top` bit(1) NOT NULL COMMENT '对话框是否置顶',
-  `display` bit(1) NOT NULL COMMENT '对话框是否显示',
-  `robot` bit(1) NOT NULL,
-  `unread_num` int(11) NOT NULL,
-  PRIMARY KEY (`id`) USING BTREE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='聊天窗口';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `chat_chat_record`
---
-
-DROP TABLE IF EXISTS `chat_chat_record`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `chat_chat_record` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `record_id` bigint(20) DEFAULT NULL,
-  `chat_id` bigint(20) NOT NULL,
-  `chat_type` int(11) NOT NULL,
-  `sender_id` bigint(20) NOT NULL,
-  `receiver_id` bigint(20) NOT NULL,
-  `msg_type` int(10) NOT NULL,
-  `read` bit(1) NOT NULL,
-  `revoke` bit(1) NOT NULL,
-  PRIMARY KEY (`id`),
-  KEY `sender_id` (`sender_id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `chat_code_block_message`
---
-
-DROP TABLE IF EXISTS `chat_code_block_message`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `chat_code_block_message` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL,
-  `create_time` datetime(6) NOT NULL,
-  `update_time` datetime(6) NOT NULL,
-  `record_id` bigint(20) NOT NULL,
-  `lang` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
-  `code` text COLLATE utf8mb4_unicode_ci NOT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `chat_file_message`
---
-
-DROP TABLE IF EXISTS `chat_file_message`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `chat_file_message` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `file_type` int(11) DEFAULT NULL,
-  `record_id` bigint(20) NOT NULL,
-  `upload_id` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
-  `url` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
-  `filename` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
-  `width` int(11) DEFAULT NULL,
-  `height` int(11) DEFAULT NULL,
-  `channel_id` int(11) DEFAULT NULL,
-  PRIMARY KEY (`id`),
-  KEY `sender_id` (`upload_id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `chat_hongbao`
---
-
-DROP TABLE IF EXISTS `chat_hongbao`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `chat_hongbao` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `hongbao_id` bigint(20) NOT NULL,
-  `reciever_type` int(11) NOT NULL,
-  `reciever_id` bigint(20) NOT NULL,
-  `amount` double NOT NULL,
-  `num` int(11) NOT NULL,
-  `remain` int(11) NOT NULL,
-  `remark` varchar(255) NOT NULL,
-  `create_by` bigint(20) NOT NULL,
-  `create_at` datetime NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `UK_rfuvf3osnlaakifjdao0a8e2x` (`hongbao_id`) USING BTREE,
-  KEY `user_id` (`create_by`) USING BTREE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='红包';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `chat_hongbao_receiver`
---
-
-DROP TABLE IF EXISTS `chat_hongbao_receiver`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `chat_hongbao_receiver` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `hongbao_id` bigint(20) NOT NULL,
-  `reciever_id` bigint(20) NOT NULL,
-  `amount` double NOT NULL,
-  `remark` varchar(255) NOT NULL,
-  `create_at` datetime NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `UK_rfuvf3osnlaakifjdao0a8e2x` (`hongbao_id`) USING BTREE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='红包';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `chat_setting`
---
-
-DROP TABLE IF EXISTS `chat_setting`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `chat_setting` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL,
-  `create_time` datetime(6) NOT NULL,
-  `update_time` datetime(6) NOT NULL,
-  `user_id` bigint(20) NOT NULL,
-  `keyboard_event_notify` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
-  `notify_cue_tone` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
-  `theme_bag_img` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
-  `theme_color` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
-  `theme_mode` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `UK_p0dbxwvogoamsrntdo066xlhj` (`user_id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `chat_text_message`
---
-
-DROP TABLE IF EXISTS `chat_text_message`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `chat_text_message` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL,
-  `create_time` datetime(6) NOT NULL,
-  `update_time` datetime(6) NOT NULL,
-  `record_id` bigint(20) NOT NULL,
-  `content` text COLLATE utf8mb4_unicode_ci NOT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `file_job_detail`
---
-
-DROP TABLE IF EXISTS `file_job_detail`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `file_job_detail` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `job_id` bigint(20) NOT NULL,
-  `job_name` varchar(255) NOT NULL,
-  `status` int(11) NOT NULL,
-  `start_at` datetime(6) NOT NULL,
-  `end_at` datetime(6) DEFAULT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `oss_type` (`job_id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='任务详情';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `file_store_config`
---
-
-DROP TABLE IF EXISTS `file_store_config`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `file_store_config` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `oss_type` int(11) NOT NULL,
-  `endpoint` varchar(255) NOT NULL,
-  `access_key_id` varchar(255) NOT NULL,
-  `access_key_secret` varchar(255) NOT NULL,
-  `region` varchar(255) DEFAULT NULL,
-  `bucket_name` varchar(255) DEFAULT NULL,
-  `role_arn` varchar(255) DEFAULT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `oss_type` (`oss_type`)
-) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COMMENT='OSS 存储节点配置';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `geo_area`
---
-
-DROP TABLE IF EXISTS `geo_area`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `geo_area` (
-  `id` int(11) NOT NULL,
-  `pid` int(11) NOT NULL,
-  `deep` int(11) NOT NULL,
-  `name` varchar(250) NOT NULL,
-  `ext_path` varchar(255) NOT NULL,
-  `geo` geometry DEFAULT NULL,
-  `polygon` geometry NOT NULL,
-  `polygon_envelope` geometry DEFAULT NULL,
-  PRIMARY KEY (`id`),
-  SPATIAL KEY `polygon` (`polygon`)
-) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `geo_bus_station`
---
-
-DROP TABLE IF EXISTS `geo_bus_station`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `geo_bus_station` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `lng` bigint(20) NOT NULL,
-  `lat` bigint(20) NOT NULL,
-  `station_name` varchar(255) NOT NULL,
-  `pm` int(11) NOT NULL,
-  `tid` int(11) NOT NULL,
-  `line_name` varchar(255) DEFAULT NULL,
-  `type` int(11) DEFAULT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB AUTO_INCREMENT=19165 DEFAULT CHARSET=utf8mb4;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `geo_camera_photo`
---
-
-DROP TABLE IF EXISTS `geo_camera_photo`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `geo_camera_photo` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `album_id` bigint(20) NOT NULL,
-  `object_id` varchar(255) NOT NULL,
-  `channel_id` int(11) NOT NULL,
-  `photo_url` varchar(255) NOT NULL,
-  `manufacturer` varchar(255) DEFAULT NULL,
-  `model` varchar(255) DEFAULT NULL,
-  `software` varchar(255) DEFAULT NULL,
-  `shot_at` datetime(6) DEFAULT NULL,
-  `geo` geometry NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `photo_url` (`photo_url`)
-) ENGINE=InnoDB AUTO_INCREMENT=44909 DEFAULT CHARSET=utf8mb4 COMMENT=' 相册中照片的位置';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `geo_earth`
---
-
-DROP TABLE IF EXISTS `geo_earth`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `geo_earth` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `name` varchar(255) NOT NULL,
-  `template` text NOT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='GoogleEarth kml 模板';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `geo_item`
---
-
-DROP TABLE IF EXISTS `geo_item`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `geo_item` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `name` varchar(255) NOT NULL,
-  `total` int(11) NOT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB AUTO_INCREMENT=8 DEFAULT CHARSET=utf8mb4;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `geo_job_location`
---
-
-DROP TABLE IF EXISTS `geo_job_location`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `geo_job_location` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `company_name` varchar(255) NOT NULL,
-  `issue_date` datetime(6) NOT NULL,
-  `job_href` varchar(255) NOT NULL,
-  `job_describe` text NOT NULL,
-  `salary_min` int(11) NOT NULL,
-  `salary_max` int(11) NOT NULL,
-  `salary_str` varchar(255) NOT NULL,
-  `geo` geometry NOT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB AUTO_INCREMENT=401 DEFAULT CHARSET=utf8mb4 COMMENT='工作位置';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `geo_mall_reply`
---
-
-DROP TABLE IF EXISTS `geo_mall_reply`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `geo_mall_reply` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL,
-  `create_time` datetime(6) NOT NULL,
-  `update_time` datetime(6) NOT NULL,
-  `item_type` int(11) NOT NULL COMMENT '商品类型',
-  `item_id` varchar(255) NOT NULL,
-  `reply_id` varchar(255) NOT NULL,
-  `reply_content` text NOT NULL,
-  `append_content` text,
-  `extra` text,
-  `username` varchar(255) NOT NULL,
-  `avatar_url` text NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `reply_id` (`reply_id`),
-  KEY `item_id` (`item_id`)
-) ENGINE=InnoDB AUTO_INCREMENT=113 DEFAULT CHARSET=utf8mb4 COMMENT='天猫商品评论';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `geo_mall_reply_photo`
---
-
-DROP TABLE IF EXISTS `geo_mall_reply_photo`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `geo_mall_reply_photo` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `reply_id` varchar(255) NOT NULL,
-  `upload_id` varchar(255) NOT NULL,
-  `channel_id` int(11) NOT NULL,
-  `photo_url` varchar(255) NOT NULL,
-  `manufacturer` varchar(255) DEFAULT NULL,
-  `model` varchar(255) DEFAULT NULL,
-  `software` varchar(255) DEFAULT NULL,
-  `shot_at` datetime(6) DEFAULT NULL,
-  `geo` geometry NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `photo_url` (`photo_url`),
-  KEY `reply_id` (`reply_id`)
-) ENGINE=InnoDB AUTO_INCREMENT=281 DEFAULT CHARSET=utf8mb4 COMMENT='天猫商品评论中的照片';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `geo_point`
---
-
-DROP TABLE IF EXISTS `geo_point`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `geo_point` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `geo` geometry NOT NULL,
-  `create_by` bigint(20) DEFAULT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB AUTO_INCREMENT=91 DEFAULT CHARSET=utf8mb4;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `geo_polygon`
---
-
-DROP TABLE IF EXISTS `geo_polygon`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `geo_polygon` (
-  `id` int(11) NOT NULL,
-  `pid` int(11) NOT NULL,
-  `deep` int(11) NOT NULL,
-  `name` varchar(255) NOT NULL,
-  `ext_name` varchar(255) DEFAULT NULL,
-  `geo` geometry DEFAULT NULL,
-  `polygon` polygon DEFAULT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `geo_scope`
---
-
-DROP TABLE IF EXISTS `geo_scope`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `geo_scope` (
-  `id` int(11) NOT NULL,
-  `pid` int(11) NOT NULL,
-  `name` varchar(255) NOT NULL,
-  `lng_east` decimal(10,6) NOT NULL,
-  `lng_west` decimal(10,6) NOT NULL,
-  `lat_north` decimal(10,6) NOT NULL,
-  `lat_south` decimal(10,6) NOT NULL,
-  UNIQUE KEY `id` (`id`),
-  KEY `name` (`name`) USING BTREE,
-  KEY `pid` (`pid`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='省市县地理坐标';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `image_file`
---
-
-DROP TABLE IF EXISTS `image_file`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `image_file` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `album_id` bigint(20) NOT NULL,
-  `channel_code` int(11) DEFAULT NULL,
-  `image_file_id` varchar(255) NOT NULL COMMENT '原始对象的 objectId',
-  `object_id` varchar(255) NOT NULL,
-  `format` varchar(255) NOT NULL,
-  `url` varchar(255) NOT NULL,
-  `width` int(11) NOT NULL,
-  `height` int(11) NOT NULL,
-  `horizontal` bit(1) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `object_id` (`object_id`) USING BTREE,
-  KEY `image_file_id` (`image_file_id`),
-  KEY `url` (`url`),
-  KEY `album_id` (`album_id`)
-) ENGINE=InnoDB AUTO_INCREMENT=9505274 DEFAULT CHARSET=utf8mb4 COMMENT='图片文件';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `image_post`
---
-
-DROP TABLE IF EXISTS `image_post`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `image_post` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL,
-  `create_time` datetime(6) NOT NULL,
-  `update_time` datetime(6) NOT NULL,
-  `album_id` bigint(20) NOT NULL,
-  `album_name` varchar(255) NOT NULL,
-  `channel_id` int(11) DEFAULT NULL,
-  `cover_url` varchar(255) NOT NULL,
-  `total` int(11) NOT NULL,
-  `scope` int(11) NOT NULL,
-  `created_at` datetime(6) NOT NULL,
-  `user_id` bigint(20) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `UK_rfuvf3osnlaakifjdao0a8e2x` (`album_id`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=17923 DEFAULT CHARSET=utf8mb4 COMMENT='相册';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `mall_delivery`
---
-
-DROP TABLE IF EXISTS `mall_delivery`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `mall_delivery` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `delivery_id` bigint(20) NOT NULL,
-  `address` varchar(2048) NOT NULL,
-  `owner` bigint(20) NOT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='收货地址';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `mall_logistics`
---
-
-DROP TABLE IF EXISTS `mall_logistics`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `mall_logistics` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `order_id` bigint(20) NOT NULL,
-  `tpl` varchar(2048) NOT NULL COMMENT 'third party logistics',
-  `logistics_id` bigint(20) NOT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='订单物流';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `mall_logistics_progress`
---
-
-DROP TABLE IF EXISTS `mall_logistics_progress`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `mall_logistics_progress` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `logistics_id` bigint(20) NOT NULL,
-  `status` varchar(255) DEFAULT NULL,
-  `current` varchar(255) NOT NULL,
-  `create_at` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `location` geometry DEFAULT NULL,
-  PRIMARY KEY (`id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='订单物流进度';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `mall_order`
---
-
-DROP TABLE IF EXISTS `mall_order`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `mall_order` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `order_id` bigint(20) NOT NULL,
-  `product_id` bigint(20) NOT NULL,
-  `delivery_id` bigint(20) NOT NULL,
-  `price` double NOT NULL,
-  `amount` int(11) NOT NULL,
-  `owner` bigint(20) NOT NULL,
-  `status` int(11) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `order_id` (`order_id`)
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='用户订单';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `mall_product`
---
-
-DROP TABLE IF EXISTS `mall_product`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `mall_product` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `item_id` bigint(20) NOT NULL COMMENT '商品类型',
-  `item_url` varchar(255) NOT NULL,
-  `title` varchar(255) NOT NULL,
-  `pic_url` varchar(255) NOT NULL,
-  `price` double NOT NULL,
-  `month_sale` varchar(255) DEFAULT NULL,
-  `stock` int(11) DEFAULT NULL,
-  `shop_id` bigint(20) DEFAULT NULL,
-  `seller_id` bigint(20) DEFAULT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `item_id` (`item_id`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=61 DEFAULT CHARSET=utf8mb4 COMMENT='淘宝商品';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `mall_product_snapshot`
---
-
-DROP TABLE IF EXISTS `mall_product_snapshot`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `mall_product_snapshot` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `order_id` bigint(20) NOT NULL,
-  `item_id` bigint(20) NOT NULL COMMENT '商品类型',
-  `title` varchar(255) NOT NULL,
-  `pic_url` varchar(255) NOT NULL,
-  `price` double NOT NULL,
-  `amount` int(11) DEFAULT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `order_id` (`order_id`) USING BTREE
-) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='订单商品快照';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `vod_play_record`
---
-
-DROP TABLE IF EXISTS `vod_play_record`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `vod_play_record` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL,
-  `create_time` datetime(6) NOT NULL,
-  `update_time` datetime(6) NOT NULL,
-  `video_id` varchar(255) NOT NULL,
-  `user_id` bigint(20) NOT NULL,
-  `current_time` double NOT NULL,
-  `create_at` bigint(20) DEFAULT NULL,
-  `ended` bit(1) DEFAULT NULL,
-  PRIMARY KEY (`id`),
-  KEY `user_id` (`user_id`),
-  KEY `video_id` (`video_id`)
-) ENGINE=InnoDB AUTO_INCREMENT=21468 DEFAULT CHARSET=utf8mb4 COMMENT='视频播放记录';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `vod_post_album`
---
-
-DROP TABLE IF EXISTS `vod_post_album`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `vod_post_album` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `album_id` bigint(20) NOT NULL,
-  `album_name` varchar(255) NOT NULL,
-  `cover_url` varchar(255) DEFAULT NULL,
-  `post_type` int(11) NOT NULL,
-  `total` int(11) DEFAULT NULL,
-  `scope` int(11) DEFAULT NULL,
-  `create_by` bigint(20) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `favlist_id` (`album_id`)
-) ENGINE=InnoDB AUTO_INCREMENT=7 DEFAULT CHARSET=utf8mb4 COMMENT='用户收藏夹';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `vod_post_item`
---
-
-DROP TABLE IF EXISTS `vod_post_item`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `vod_post_item` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `album_id` bigint(20) NOT NULL,
-  `post_id` varchar(255) NOT NULL,
-  `pos` int(11) DEFAULT NULL,
-  `added_at` datetime(6) DEFAULT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `favlist_id` (`album_id`,`post_id`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=4501 DEFAULT CHARSET=utf8mb4 COMMENT='用户收藏夹的内容';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `vod_search_record`
---
-
-DROP TABLE IF EXISTS `vod_search_record`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `vod_search_record` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL,
-  `create_time` datetime(6) NOT NULL,
-  `update_time` datetime(6) NOT NULL,
-  `user_id` int(11) NOT NULL,
-  `keyword` varchar(255) NOT NULL,
-  PRIMARY KEY (`id`),
-  KEY `user_id` (`user_id`),
-  KEY `keyword` (`keyword`)
-) ENGINE=InnoDB AUTO_INCREMENT=461 DEFAULT CHARSET=utf8mb4 COMMENT='搜索记录';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `vod_site_notice`
---
-
-DROP TABLE IF EXISTS `vod_site_notice`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `vod_site_notice` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `content` text NOT NULL,
-  `create_by` bigint(20) NOT NULL,
-  PRIMARY KEY (`id`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='站点公告';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `vod_video_category`
---
-
-DROP TABLE IF EXISTS `vod_video_category`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `vod_video_category` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6) ON UPDATE CURRENT_TIMESTAMP(6),
-  `pid` int(11) NOT NULL COMMENT '分区级别【1 一级分区, 2 二级分区】',
-  `region_id` int(11) DEFAULT NULL COMMENT 'bilibili region id',
-  `name` varchar(255) NOT NULL COMMENT '分区名',
-  `icon` varchar(255) DEFAULT NULL COMMENT '前端图标',
-  `sort` int(11) NOT NULL DEFAULT '0' COMMENT '排序',
-  `desc` varchar(255) DEFAULT NULL,
-  PRIMARY KEY (`id`) USING BTREE,
-  KEY `name` (`name`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=137 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='视频分类';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `vod_video_category_post`
---
-
-DROP TABLE IF EXISTS `vod_video_category_post`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `vod_video_category_post` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `video_id` varchar(255) CHARACTER SET utf8mb4 NOT NULL,
-  `video_file_id` varchar(255) CHARACTER SET utf8mb4 DEFAULT NULL,
-  `channel_id` int(11) DEFAULT NULL,
-  `title` varchar(255) CHARACTER SET utf8mb4 DEFAULT NULL,
-  `description` text CHARACTER SET utf8mb4,
-  `category_pid` int(11) NOT NULL,
-  `category_id` int(11) NOT NULL,
-  `duration` int(11) DEFAULT NULL,
-  `quality` varchar(255) CHARACTER SET utf8mb4 DEFAULT NULL,
-  `codec` varchar(255) CHARACTER SET utf8mb4 DEFAULT NULL,
-  `horizontal` bit(1) DEFAULT NULL,
-  `cover_url` varchar(255) CHARACTER SET utf8mb4 DEFAULT NULL,
-  `scope` int(11) NOT NULL COMMENT '视频可见范围',
-  `status` int(11) DEFAULT NULL COMMENT '视频贴状态',
-  `publish_at` datetime NOT NULL,
-  `publish_by` bigint(20) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `UK_rfuvf3osnlaakifjdao0a8e2x` (`category_id`,`publish_by`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=171212 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin COMMENT='视频分区稿件';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `vod_video_error`
---
-
-DROP TABLE IF EXISTS `vod_video_error`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `vod_video_error` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL,
-  `create_time` datetime(6) NOT NULL,
-  `update_time` datetime(6) NOT NULL,
-  `video_id` varchar(255) NOT NULL,
-  `error_code` int(11) NOT NULL,
-  `error_info` varchar(255) NOT NULL,
-  `solved` bit(1) NOT NULL,
-  PRIMARY KEY (`id`) USING BTREE,
-  KEY `name` (`video_id`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=191 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='视频稿件错误';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `vod_video_file`
---
-
-DROP TABLE IF EXISTS `vod_video_file`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `vod_video_file` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `video_file_id` varchar(255) NOT NULL,
-  `object_id` varchar(255) NOT NULL,
-  `video_codec` varchar(255) DEFAULT NULL,
-  `vbit_rate` bigint(20) NOT NULL,
-  `audio_codec` varchar(255) DEFAULT NULL,
-  `abit_rate` bigint(20) NOT NULL,
-  `url_type` varchar(255) NOT NULL,
-  `url` varchar(255) NOT NULL,
-  `format` varchar(255) DEFAULT NULL,
-  `format_name` varchar(255) DEFAULT NULL,
-  `quality` varchar(255) NOT NULL,
-  `width` int(11) NOT NULL,
-  `height` int(11) NOT NULL,
-  `horizontal` bit(1) NOT NULL,
-  `duration` int(11) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `object_id` (`object_id`) USING BTREE,
-  KEY `video_file_id` (`video_file_id`)
-) ENGINE=InnoDB AUTO_INCREMENT=698558 DEFAULT CHARSET=utf8mb4 COMMENT='视频文件';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `vod_video_post`
---
-
-DROP TABLE IF EXISTS `vod_video_post`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `vod_video_post` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `video_id` varchar(255) CHARACTER SET utf8mb4 NOT NULL,
-  `video_file_id` varchar(255) CHARACTER SET utf8mb4 NOT NULL,
-  `channel_id` int(11) DEFAULT NULL,
-  `title` varchar(255) CHARACTER SET utf8mb4 NOT NULL,
-  `description` text CHARACTER SET utf8mb4,
-  `category_pid` int(11) NOT NULL,
-  `category_id` int(11) NOT NULL,
-  `duration` int(11) NOT NULL,
-  `quality` varchar(255) CHARACTER SET utf8mb4 DEFAULT NULL,
-  `codec` varchar(255) CHARACTER SET utf8mb4 DEFAULT NULL,
-  `horizontal` bit(1) NOT NULL,
-  `cover_url` varchar(255) CHARACTER SET utf8mb4 NOT NULL,
-  `scope` int(11) NOT NULL COMMENT '视频可见范围',
-  `status` int(11) NOT NULL COMMENT '视频贴状态',
-  `publish_at` datetime NOT NULL,
-  `publish_by` bigint(20) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `UK_rfuvf3osnlaakifjdao0a8e2x` (`video_id`) USING BTREE,
-  UNIQUE KEY `video_file_id` (`video_file_id`) USING BTREE,
-  KEY `user_id` (`publish_by`) USING BTREE,
-  KEY `status` (`status`),
-  KEY `scope` (`scope`),
-  KEY `category_pid` (`category_pid`),
-  KEY `category_id` (`category_id`),
-  KEY `duration` (`duration`),
-  KEY `pub_date` (`publish_at`),
-  KEY `query_max` (`category_pid`,`category_id`,`scope`,`status`) USING BTREE,
-  FULLTEXT KEY `index_title` (`title`) /*!50100 WITH PARSER `ngram` */ 
-) ENGINE=InnoDB AUTO_INCREMENT=3043505 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin COMMENT='视频稿件';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `vod_video_statistic`
---
-
-DROP TABLE IF EXISTS `vod_video_statistic`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `vod_video_statistic` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `video_id` varchar(255) NOT NULL,
-  `view` int(11) NOT NULL,
-  `danmaku` int(11) NOT NULL,
-  `comment` int(11) NOT NULL,
-  `favorite` int(11) NOT NULL,
-  `share` int(11) NOT NULL,
-  `thumb_up` int(11) NOT NULL,
-  `thumb_down` int(11) NOT NULL,
-  `coin` int(11) DEFAULT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `UK_rfuvf3osnlaakifjdao0a8e2x` (`video_id`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=3027544 DEFAULT CHARSET=utf8mb4 COMMENT='视频稿件数据';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `vod_video_tag`
---
-
-DROP TABLE IF EXISTS `vod_video_tag`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `vod_video_tag` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `tag_id` varchar(255) NOT NULL,
-  `tag_name` varchar(255) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `name` (`tag_name`),
-  UNIQUE KEY `tag_id` (`tag_id`)
-) ENGINE=InnoDB AUTO_INCREMENT=1102652 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='视频标签';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Table structure for table `vod_video_tags`
---
-
-DROP TABLE IF EXISTS `vod_video_tags`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `vod_video_tags` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `video_id` varchar(255) NOT NULL,
-  `tag_id` varchar(255) NOT NULL,
-  PRIMARY KEY (`id`),
-  KEY `tag_id` (`tag_id`),
-  KEY `video_id` (`video_id`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=29207972 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='视频稿件包含的标签';
-/*!40101 SET character_set_client = @saved_cs_client */;
-/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
-
-/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
-/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
-/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
-/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-
--- Dump completed on 2024-12-15 22:47:21

+ 0 - 60
zzz/schema/user_registry.sql

@@ -1,60 +0,0 @@
--- MySQL dump 10.13  Distrib 5.7.42, for Linux (x86_64)
---
--- Host: 192.168.0.210    Database: tnb_account_tdb
--- ------------------------------------------------------
--- Server version	5.7.36
-
-/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
-/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
-/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
-/*!40101 SET NAMES utf8 */;
-/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
-/*!40103 SET TIME_ZONE='+00:00' */;
-/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
-/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
-/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
-/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
-
---
--- Table structure for table `user_registry`
---
-
-DROP TABLE IF EXISTS `user_registry`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `user_registry` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `enabled` bit(1) NOT NULL COMMENT '是否开放注册',
-  `rule` varchar(255) NOT NULL COMMENT '开放注册规则',
-  `captcha_code` varchar(255) NOT NULL,
-  `verify_code` varchar(255) NOT NULL,
-  `enable_code` bit(1) NOT NULL,
-  `domain` varchar(255) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `user_id` (`enabled`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COMMENT='帐号开放注册规则';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `user_registry`
---
-
-LOCK TABLES `user_registry` WRITE;
-/*!40000 ALTER TABLE `user_registry` DISABLE KEYS */;
-INSERT INTO `user_registry` VALUES (1,_binary '\0','2024-11-01 11:20:14.512622','2024-11-01 11:20:14.512622',_binary '','*','ab8il','220233',_binary '\0','api.reghao.cn');
-/*!40000 ALTER TABLE `user_registry` ENABLE KEYS */;
-UNLOCK TABLES;
-/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
-
-/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
-/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
-/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
-/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-
--- Dump completed on 2024-12-15 22:47:21

+ 0 - 58
zzz/schema/user_vip_plan.sql

@@ -1,58 +0,0 @@
--- MySQL dump 10.13  Distrib 5.7.42, for Linux (x86_64)
---
--- Host: 192.168.0.210    Database: tnb_account_tdb
--- ------------------------------------------------------
--- Server version	5.7.36
-
-/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
-/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
-/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
-/*!40101 SET NAMES utf8 */;
-/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
-/*!40103 SET TIME_ZONE='+00:00' */;
-/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
-/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
-/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
-/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
-
---
--- Table structure for table `user_vip_plan`
---
-
-DROP TABLE IF EXISTS `user_vip_plan`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `user_vip_plan` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `plan_id` int(11) NOT NULL,
-  `name` varchar(255) NOT NULL,
-  `price` double NOT NULL,
-  `duration` int(11) NOT NULL,
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `owner` (`plan_id`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb4 COMMENT='小会员计划';
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `user_vip_plan`
---
-
-LOCK TABLES `user_vip_plan` WRITE;
-/*!40000 ALTER TABLE `user_vip_plan` DISABLE KEYS */;
-INSERT INTO `user_vip_plan` VALUES (1,_binary '\0','2024-07-06 16:44:39.534750','2024-07-06 16:44:39.534750',1,'月度会员',9.9,30),(3,_binary '\0','2024-07-06 16:48:17.682984','2024-07-06 16:48:17.682984',2,'季度会员',28.9,90),(4,_binary '\0','2024-07-06 16:48:26.567033','2024-07-06 16:48:26.567033',3,'年度会员',99.9,365);
-/*!40000 ALTER TABLE `user_vip_plan` ENABLE KEYS */;
-UNLOCK TABLES;
-/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
-
-/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
-/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
-/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
-/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-
--- Dump completed on 2024-12-15 22:47:21

+ 0 - 170
zzz/schema/vod_video_category.sql

@@ -1,170 +0,0 @@
-/*
- Navicat Premium Data Transfer
-
- Source Server         : localhost-mysql
- Source Server Type    : MySQL
- Source Server Version : 50732
- Source Host           : 127.0.0.1:3306
- Source Schema         : tnb_content_rdb
-
- Target Server Type    : MySQL
- Target Server Version : 50732
- File Encoding         : 65001
-
- Date: 18/12/2024 09:34:47
-*/
-
-SET NAMES utf8mb4;
-SET FOREIGN_KEY_CHECKS = 0;
-
--- ----------------------------
--- Table structure for vod_video_category
--- ----------------------------
-DROP TABLE IF EXISTS `vod_video_category`;
-CREATE TABLE `vod_video_category` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
-  `deleted` bit(1) NOT NULL DEFAULT b'0',
-  `create_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6),
-  `update_time` datetime(6) NOT NULL DEFAULT CURRENT_TIMESTAMP(6) ON UPDATE CURRENT_TIMESTAMP(6),
-  `pid` int(11) NOT NULL COMMENT '分区级别【1 一级分区, 2 二级分区】',
-  `region_id` int(11) DEFAULT NULL COMMENT 'bilibili region id',
-  `name` varchar(255) NOT NULL COMMENT '分区名',
-  `icon` varchar(255) DEFAULT NULL COMMENT '前端图标',
-  `sort` int(11) NOT NULL DEFAULT '0' COMMENT '排序',
-  `desc` varchar(255) DEFAULT NULL,
-  PRIMARY KEY (`id`) USING BTREE,
-  KEY `name` (`name`) USING BTREE
-) ENGINE=InnoDB AUTO_INCREMENT=137 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='视频分类';
-
--- ----------------------------
--- Records of vod_video_category
--- ----------------------------
-BEGIN;
-INSERT INTO `vod_video_category` VALUES (1, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:51.735836', 0, 0, '资讯', NULL, 5, NULL);
-INSERT INTO `vod_video_category` VALUES (2, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 1, 205, '社会', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (3, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:52:02.676209', 0, 0, '大杂烩', NULL, 1, NULL);
-INSERT INTO `vod_video_category` VALUES (4, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:52:22.616170', 3, 0, 'B站', 'el-icon-lollipop', 1, NULL);
-INSERT INTO `vod_video_category` VALUES (5, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 23:00:35.220360', 3, 0, '擦边', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (6, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 23:34:19.301846', 3, 0, '美女', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (7, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:50.403026', 0, 0, '舞蹈', NULL, 6, NULL);
-INSERT INTO `vod_video_category` VALUES (9, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 7, 20, '宅舞', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (10, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 7, 198, '街舞', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (11, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:52.780109', 0, 0, '18+', NULL, 2, NULL);
-INSERT INTO `vod_video_category` VALUES (12, b'0', '2021-12-05 04:13:55.948304', '2024-12-18 09:34:04.846004', 11, 0, '个人风采', 'el-icon-lollipop', 1, NULL);
-INSERT INTO `vod_video_category` VALUES (13, b'0', '2021-12-05 04:13:55.948304', '2024-12-18 09:34:04.851342', 11, 0, '黑暗之眼', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (14, b'0', '2021-12-05 04:13:55.948304', '2024-12-18 09:34:04.853990', 11, 0, '苍天可见', 'el-icon-lollipop', 5, NULL);
-INSERT INTO `vod_video_category` VALUES (15, b'0', '2021-12-05 04:13:55.948304', '2024-12-18 09:34:04.855791', 11, 0, '寻花问柳', 'el-icon-lollipop', 7, NULL);
-INSERT INTO `vod_video_category` VALUES (16, b'0', '2021-12-05 04:13:55.948304', '2024-12-18 09:34:04.858568', 11, 0, '赛博青楼', 'el-icon-lollipop', 9, NULL);
-INSERT INTO `vod_video_category` VALUES (17, b'0', '2021-12-05 04:13:55.948304', '2024-12-18 09:34:04.860981', 11, 0, '情节精彩', 'el-icon-lollipop', 11, NULL);
-INSERT INTO `vod_video_category` VALUES (18, b'0', '2021-12-05 04:13:55.948304', '2024-12-18 09:34:04.863525', 11, 0, '异域风情', 'el-icon-lollipop', 12, NULL);
-INSERT INTO `vod_video_category` VALUES (20, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 1, 203, '热点', 'el-icon-lollipop', 1, NULL);
-INSERT INTO `vod_video_category` VALUES (21, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:47.784569', 0, 0, '科技', NULL, 8, NULL);
-INSERT INTO `vod_video_category` VALUES (22, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 1, 204, '环球', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (23, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:34.655391', 0, 0, '音乐', NULL, 17, NULL);
-INSERT INTO `vod_video_category` VALUES (24, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:45.419394', 0, 0, '生活', NULL, 10, NULL);
-INSERT INTO `vod_video_category` VALUES (25, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:33.347059', 0, 0, '汽车', NULL, 18, NULL);
-INSERT INTO `vod_video_category` VALUES (26, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:46.628065', 0, 0, '知识', NULL, 9, NULL);
-INSERT INTO `vod_video_category` VALUES (28, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 24, 138, '搞笑', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (29, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 24, 254, '亲子', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (31, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 26, 201, '科学科普', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (33, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 23, 31, '翻唱', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (34, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 23, 59, '演奏', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (36, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 25, 245, '赛车', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (37, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 25, 247, '新能源车', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (39, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:41.995766', 0, 0, '运动', NULL, 13, NULL);
-INSERT INTO `vod_video_category` VALUES (40, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:43.048666', 0, 0, '时尚', NULL, 12, NULL);
-INSERT INTO `vod_video_category` VALUES (41, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 1, 206, '综合', 'el-icon-lollipop', 4, NULL);
-INSERT INTO `vod_video_category` VALUES (42, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 26, 228, '人文历史', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (43, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 26, 207, '财经商业', 'el-icon-lollipop', 4, NULL);
-INSERT INTO `vod_video_category` VALUES (44, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 26, 209, '职业职场', 'el-icon-lollipop', 5, NULL);
-INSERT INTO `vod_video_category` VALUES (45, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 26, 229, '设计创意', 'el-icon-lollipop', 6, NULL);
-INSERT INTO `vod_video_category` VALUES (46, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 26, 122, '野生技能协会', 'el-icon-lollipop', 7, NULL);
-INSERT INTO `vod_video_category` VALUES (47, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 23, 29, '音乐现场', 'el-icon-lollipop', 4, NULL);
-INSERT INTO `vod_video_category` VALUES (48, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 23, 30, 'VOCAL', 'el-icon-lollipop', 5, NULL);
-INSERT INTO `vod_video_category` VALUES (49, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 23, 193, 'MV', 'el-icon-lollipop', 6, NULL);
-INSERT INTO `vod_video_category` VALUES (50, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 7, 200, '国风舞蹈', 'el-icon-lollipop', 4, NULL);
-INSERT INTO `vod_video_category` VALUES (51, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 7, 199, '明星舞蹈', 'el-icon-lollipop', 5, NULL);
-INSERT INTO `vod_video_category` VALUES (52, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 7, 255, '手势网红舞', 'el-icon-lollipop', 6, NULL);
-INSERT INTO `vod_video_category` VALUES (53, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 7, 154, '舞蹈综合', 'el-icon-lollipop', 7, NULL);
-INSERT INTO `vod_video_category` VALUES (54, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 7, 156, '舞蹈教程', 'el-icon-lollipop', 8, NULL);
-INSERT INTO `vod_video_category` VALUES (55, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 25, 248, '房车', 'el-icon-lollipop', 4, NULL);
-INSERT INTO `vod_video_category` VALUES (56, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 25, 240, '摩托车', 'el-icon-lollipop', 5, NULL);
-INSERT INTO `vod_video_category` VALUES (57, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 25, 246, '改装玩车', 'el-icon-lollipop', 6, NULL);
-INSERT INTO `vod_video_category` VALUES (58, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 25, 227, '购车攻略', 'el-icon-lollipop', 7, NULL);
-INSERT INTO `vod_video_category` VALUES (59, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 25, 176, '汽车生活', 'el-icon-lollipop', 8, NULL);
-INSERT INTO `vod_video_category` VALUES (60, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 24, 250, '出行', 'el-icon-lollipop', 4, NULL);
-INSERT INTO `vod_video_category` VALUES (61, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 24, 251, '三农', 'el-icon-lollipop', 5, NULL);
-INSERT INTO `vod_video_category` VALUES (62, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 24, 239, '家居房产', 'el-icon-lollipop', 6, NULL);
-INSERT INTO `vod_video_category` VALUES (63, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 24, 161, '手工', 'el-icon-lollipop', 7, NULL);
-INSERT INTO `vod_video_category` VALUES (64, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 24, 162, '绘画', 'el-icon-lollipop', 8, NULL);
-INSERT INTO `vod_video_category` VALUES (65, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 24, 21, '日常', 'el-icon-lollipop', 9, NULL);
-INSERT INTO `vod_video_category` VALUES (66, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 21, 95, '数码', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (67, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 21, 230, '软件应用', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (68, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 21, 231, '计算机技术', 'el-icon-lollipop', 4, NULL);
-INSERT INTO `vod_video_category` VALUES (69, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 21, 232, '科工机械', 'el-icon-lollipop', 5, NULL);
-INSERT INTO `vod_video_category` VALUES (70, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 21, 233, '极客DIY', 'el-icon-lollipop', 6, NULL);
-INSERT INTO `vod_video_category` VALUES (72, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 39, 235, '篮球', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (73, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 39, 249, '足球', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (74, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 39, 164, '健身', 'el-icon-lollipop', 4, NULL);
-INSERT INTO `vod_video_category` VALUES (75, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 39, 236, '竞技体育', 'el-icon-lollipop', 5, NULL);
-INSERT INTO `vod_video_category` VALUES (76, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 39, 237, '运动文化', 'el-icon-lollipop', 6, NULL);
-INSERT INTO `vod_video_category` VALUES (77, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 39, 238, '运动综合', 'el-icon-lollipop', 7, NULL);
-INSERT INTO `vod_video_category` VALUES (79, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 40, 157, '美妆护肤', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (80, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 40, 252, '仿妆cos', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (81, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 40, 158, '穿搭', 'el-icon-lollipop', 4, NULL);
-INSERT INTO `vod_video_category` VALUES (82, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 40, 159, '时尚潮流', 'el-icon-lollipop', 5, NULL);
-INSERT INTO `vod_video_category` VALUES (83, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:48.996545', 0, 0, '动物圈', NULL, 7, NULL);
-INSERT INTO `vod_video_category` VALUES (84, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:30.627827', 0, 0, '影视', NULL, 20, NULL);
-INSERT INTO `vod_video_category` VALUES (85, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:40.475739', 0, 0, '动画', NULL, 14, NULL);
-INSERT INTO `vod_video_category` VALUES (86, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:38.779866', 0, 0, '娱乐', NULL, 15, NULL);
-INSERT INTO `vod_video_category` VALUES (87, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:36.031463', 0, 0, '鬼畜', NULL, 16, NULL);
-INSERT INTO `vod_video_category` VALUES (88, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:32.039168', 0, 0, '游戏', NULL, 19, NULL);
-INSERT INTO `vod_video_category` VALUES (89, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 83, 218, '喵星人', 'el-icon-lollipop', 1, NULL);
-INSERT INTO `vod_video_category` VALUES (90, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 83, 219, '汪星人', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (91, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 83, 222, '小宠异宠', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (92, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 83, 221, '野生动物', 'el-icon-lollipop', 4, NULL);
-INSERT INTO `vod_video_category` VALUES (93, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 83, 75, '动物综合', 'el-icon-lollipop', 5, NULL);
-INSERT INTO `vod_video_category` VALUES (94, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 84, 183, '影视剪辑', 'el-icon-lollipop', 1, NULL);
-INSERT INTO `vod_video_category` VALUES (95, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 84, 256, '短片', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (96, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 85, 253, '动漫杂谈', 'el-icon-lollipop', 1, NULL);
-INSERT INTO `vod_video_category` VALUES (97, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 85, 210, '手办模玩', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (98, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 85, 24, 'MAD.AMV', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (99, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 85, 25, 'MMD.3D', 'el-icon-lollipop', 4, NULL);
-INSERT INTO `vod_video_category` VALUES (100, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 85, 27, '综合', 'el-icon-lollipop', 5, NULL);
-INSERT INTO `vod_video_category` VALUES (101, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 85, 86, '特摄', 'el-icon-lollipop', 6, NULL);
-INSERT INTO `vod_video_category` VALUES (102, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 85, 257, '配音', 'el-icon-lollipop', 7, NULL);
-INSERT INTO `vod_video_category` VALUES (103, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 86, 137, '明星综合', 'el-icon-lollipop', 1, NULL);
-INSERT INTO `vod_video_category` VALUES (104, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 86, 241, '娱乐杂谈', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (105, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 86, 242, '粉丝创作', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (106, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 86, 71, '综艺', 'el-icon-lollipop', 4, NULL);
-INSERT INTO `vod_video_category` VALUES (107, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 88, 173, '桌游棋牌', 'el-icon-lollipop', 1, NULL);
-INSERT INTO `vod_video_category` VALUES (108, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 88, 171, '电子竞技', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (109, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 88, 121, 'GMV', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (110, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 88, 172, '手机游戏', 'el-icon-lollipop', 4, NULL);
-INSERT INTO `vod_video_category` VALUES (111, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 88, 19, 'Mugen', 'el-icon-lollipop', 5, NULL);
-INSERT INTO `vod_video_category` VALUES (112, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 88, 136, '音游', 'el-icon-lollipop', 6, NULL);
-INSERT INTO `vod_video_category` VALUES (113, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 88, 65, '网络游戏', 'el-icon-lollipop', 7, NULL);
-INSERT INTO `vod_video_category` VALUES (114, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 88, 17, '单机游戏', 'el-icon-lollipop', 8, NULL);
-INSERT INTO `vod_video_category` VALUES (115, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 87, 127, '教程演示', 'el-icon-lollipop', 1, NULL);
-INSERT INTO `vod_video_category` VALUES (116, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 87, 22, '鬼畜调教', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (117, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 87, 26, '音MAD', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (118, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 87, 126, '人力VOCALOID', 'el-icon-lollipop', 4, NULL);
-INSERT INTO `vod_video_category` VALUES (119, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 87, 216, '鬼畜剧场', 'el-icon-lollipop', 5, NULL);
-INSERT INTO `vod_video_category` VALUES (120, b'0', '2021-12-05 04:13:55.948304', '2023-12-05 22:51:44.115458', 0, 0, '美食', NULL, 11, NULL);
-INSERT INTO `vod_video_category` VALUES (121, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 120, 212, '美食侦探', 'el-icon-lollipop', 1, NULL);
-INSERT INTO `vod_video_category` VALUES (122, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 120, 76, '美食制作', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (123, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 120, 213, '美食测评', 'el-icon-lollipop', 3, NULL);
-INSERT INTO `vod_video_category` VALUES (124, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 120, 215, '美食记录', 'el-icon-lollipop', 4, NULL);
-INSERT INTO `vod_video_category` VALUES (125, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 120, 214, '田园美食', 'el-icon-lollipop', 5, NULL);
-INSERT INTO `vod_video_category` VALUES (126, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 26, 124, '社科法律心理', 'el-icon-lollipop', 8, NULL);
-INSERT INTO `vod_video_category` VALUES (127, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 26, 208, '校园学习', 'el-icon-lollipop', 9, NULL);
-INSERT INTO `vod_video_category` VALUES (128, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 23, 28, '原创音乐', 'el-icon-lollipop', 6, NULL);
-INSERT INTO `vod_video_category` VALUES (129, b'0', '2021-12-05 04:13:55.948304', '2021-12-05 04:13:55.948304', 23, 130, '音乐综合', 'el-icon-lollipop', 6, NULL);
-INSERT INTO `vod_video_category` VALUES (130, b'0', '2023-11-19 03:52:18.182625', '2024-12-18 09:34:27.143495', 11, 0, '91porn', 'el-icon-lollipop', 15, NULL);
-INSERT INTO `vod_video_category` VALUES (133, b'0', '2023-12-04 21:42:53.204444', '2024-12-18 09:34:27.147643', 11, 0, '海角社区', 'el-icon-lollipop', 21, NULL);
-INSERT INTO `vod_video_category` VALUES (134, b'0', '2023-12-05 21:16:05.441348', '2024-12-18 09:34:27.150225', 11, 0, '生活所迫', 'el-icon-lollipop', 2, NULL);
-INSERT INTO `vod_video_category` VALUES (135, b'0', '2023-12-09 00:59:49.709481', '2023-12-09 01:00:08.278946', 3, 0, '杂', 'el-icon-lollipop', 4, NULL);
-INSERT INTO `vod_video_category` VALUES (136, b'0', '2023-12-10 15:40:10.137171', '2024-12-18 09:34:27.151784', 11, 0, '未分类', 'el-icon-lollipop', 99, NULL);
-COMMIT;
-
-SET FOREIGN_KEY_CHECKS = 1;