调整部分前端布局和后端增删改逻辑

This commit is contained in:
焦龙言
2026-09-26 23:11:05 +08:00
parent 977e7f996e
commit 17d991a74a
117 changed files with 311994 additions and 3192 deletions
@@ -11,7 +11,6 @@ from openpyxl.utils import get_column_letter
from openpyxl.worksheet.datavalidation import DataValidation
from sqlalchemy.engine.row import Row
from sqlalchemy.orm.collections import InstrumentedList
from sqlalchemy.sql.expression import TextClause, null
from config.database import Base
from config.env import CachePathConfig
@@ -153,17 +152,14 @@ class SqlalchemyUtil:
return result
@classmethod
def get_server_default_null(cls, dialect_name: str, need_explicit_null: bool = True) -> TextClause | None:
def get_server_default_null(cls, dialect_name: str, need_explicit_null: bool = True) -> None:
"""
根据数据库方言动态返回值为null的server_default
:param dialect_name: 数据库方言名称
:param need_explicit_null: 是否需要显式DEFAULT NULL
:return: 不同数据库方言对应的null_server_default
:return: MySQL 使用隐式 NULL,不设置显式默认值
"""
if need_explicit_null and dialect_name == 'postgresql':
return null()
return None
class CamelCaseUtil: