业务全部在独立模块仓库(foms / dbbackup / filesync / hostwatch), 本仓只做:入口组装、build、conf、start/stop、首页、RBAC 权限注册。 内容: · app/foms.py 入口,按序 load 全部模块 · app/global_func.py get_module_dbname(统一库 foms) · build.sh clone+安装全部模块、生成 DDL/CRUD、挂载 wwwroot · conf/config.json website.paths:foms 根路径 + 三模块前缀 · init/data.yaml 全部 codes(含拆分后新增的 codes) · scripts/load_path.py 重写为新 URL 布局 · wwwroot/index.ui 首页(指向各模块前缀路径) 从 foms 仓库迁出的应用层文件(app/build/conf/start/stop/index.ui/data.yaml/ init_rbac/load_path)在 foms 侧已删除。
13 lines
297 B
Python
13 lines
297 B
Python
"""FOMS_APP global functions — injected into dspy context"""
|
|
from ahserver.serverenv import ServerEnv
|
|
|
|
|
|
def get_module_dbname(mname):
|
|
"""All FOMS modules share one database."""
|
|
return 'foms'
|
|
|
|
|
|
def set_globalvariable():
|
|
env = ServerEnv()
|
|
env.get_module_dbname = get_module_dbname
|