fix: 菜单种子自动补全假单管理页
检测 product.fake-orders 缺失时自动执行 seed_kefu_menu。 Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -83,7 +83,9 @@ def _load_menu_pages():
|
|||||||
logger.warning('KefuMenuPage.query 读取失败: %s', e)
|
logger.warning('KefuMenuPage.query 读取失败: %s', e)
|
||||||
pages = []
|
pages = []
|
||||||
|
|
||||||
need_seed = not pages or not any(p.page_id == 'miniapp.assets' for p in pages)
|
need_seed = not pages or not any(
|
||||||
|
p.page_id in ('miniapp.assets', 'product.fake-orders') for p in pages
|
||||||
|
)
|
||||||
if need_seed:
|
if need_seed:
|
||||||
try:
|
try:
|
||||||
from django.core.management import call_command
|
from django.core.management import call_command
|
||||||
|
|||||||
Reference in New Issue
Block a user