完成店铺创建

This commit is contained in:
2026-03-13 16:32:37 +08:00
parent 3617a6a086
commit b180aeabd8
7 changed files with 1713 additions and 40 deletions

View File

@@ -98,11 +98,11 @@ export async function refreshAdminRole(): Promise<string> {
export function getVisibleTopMenuIds(role: string): string[] {
const normRole = normalizeRole(role)
if (normRole === 'admin') {
return ['home', 'user', 'order', 'product', 'marketing', 'distribution', 'kefu', 'finance', 'cms', 'decoration', 'app', 'setting', 'maintain']
return ['home', 'shop', 'user', 'order', 'product', 'marketing', 'distribution', 'kefu', 'finance', 'cms', 'decoration', 'app', 'setting', 'maintain']
}
if (normRole === 'merchant') {
return ['home', 'order', 'product', 'marketing', 'finance']
return ['home', 'shop', 'order', 'product', 'marketing', 'finance']
}
return ['home']
@@ -123,7 +123,7 @@ export function hasAdminModuleAccess(moduleId: string | undefined): boolean {
}
if (normRole === 'merchant') {
const allowed = ['home', 'order', 'product', 'marketing', 'finance']
const allowed = ['home', 'shop', 'order', 'product', 'marketing', 'finance']
return allowed.includes(moduleId)
}