忽略租户概念,作为全局表。

This commit is contained in:
2026-04-19 22:00:53 +08:00
parent 18ecd2f78f
commit 78a5e5ae0e
3 changed files with 8 additions and 0 deletions

View File

@@ -59,6 +59,7 @@ public class MybatisPlusConfig {
ignoreTables.add("tenant"); // 租户表本身
ignoreTables.add("industry_tags"); // 行业标签(示例:如认为是公共字典)
ignoreTables.add("menu"); // 菜单表(不需要租户隔离)
ignoreTables.add("ai_prompts"); // AI 提示词全局配置,表无 tenant_id 字段
return new TenantLineHandler() {

View File

@@ -93,6 +93,7 @@ public class AiPromptsController {
@RequestParam(required = false) String sceneCode,
@RequestParam(required = false) String categoryCode,
@RequestParam(required = false) String fieldCode,
@RequestParam(required = false) String promptType,
@RequestParam(required = false) String promptKeyword,
@RequestParam(required = false) String createStartTime,
@RequestParam(required = false) String createEndTime) {
@@ -109,6 +110,9 @@ public class AiPromptsController {
if (fieldCode != null && !fieldCode.trim().isEmpty()) {
q.eq(AiPrompts::getFieldCode, fieldCode);
}
if (promptType != null && !promptType.trim().isEmpty()) {
q.eq(AiPrompts::getPromptType, promptType);
}
if (promptKeyword != null && !promptKeyword.trim().isEmpty()) {
q.like(AiPrompts::getPromptText, promptKeyword);
}

View File

@@ -36,6 +36,9 @@ public class AiPrompts implements Serializable {
@Schema(description = "字段编码")
private String fieldCode;
@Schema(description = "提示词类型")
private String promptType;
@Schema(description = "提示词")
private String promptText;