feat(shop-role): 实现店铺角色继承功能和权限检查优化
All checks were successful
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 6m39s
All checks were successful
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 6m39s
- 新增店铺角色管理 API 和数据模型 - 实现角色继承和权限检查逻辑 - 添加流程测试框架和集成测试 - 更新权限服务和账号管理逻辑 - 添加数据库迁移脚本 - 归档 OpenSpec 变更文档 Ultraworked with Sisyphus
This commit is contained in:
@@ -24,9 +24,10 @@ func TestAccountRoleAssociation_AssignRoles(t *testing.T) {
|
||||
accountRoleStore := postgresStore.NewAccountRoleStore(env.TX, env.Redis)
|
||||
shopStore := postgresStore.NewShopStore(env.TX, env.Redis)
|
||||
enterpriseStore := postgresStore.NewEnterpriseStore(env.TX, env.Redis)
|
||||
shopRoleStore := postgresStore.NewShopRoleStore(env.TX, env.Redis)
|
||||
auditLogStore := postgresStore.NewAccountOperationLogStore(env.TX)
|
||||
auditService := accountAuditService.NewService(auditLogStore)
|
||||
accService := accountService.New(accountStore, roleStore, accountRoleStore, shopStore, enterpriseStore, auditService)
|
||||
accService := accountService.New(accountStore, roleStore, accountRoleStore, shopRoleStore, shopStore, enterpriseStore, auditService)
|
||||
|
||||
// 获取超级管理员上下文
|
||||
userCtx := env.GetSuperAdminContext()
|
||||
@@ -219,10 +220,11 @@ func TestAccountRoleAssociation_SoftDelete(t *testing.T) {
|
||||
roleStore := postgresStore.NewRoleStore(env.TX)
|
||||
accountRoleStore := postgresStore.NewAccountRoleStore(env.TX, env.Redis)
|
||||
shopStore := postgresStore.NewShopStore(env.TX, env.Redis)
|
||||
shopRoleStore := postgresStore.NewShopRoleStore(env.TX, env.Redis)
|
||||
enterpriseStore := postgresStore.NewEnterpriseStore(env.TX, env.Redis)
|
||||
auditLogStore := postgresStore.NewAccountOperationLogStore(env.TX)
|
||||
auditService := accountAuditService.NewService(auditLogStore)
|
||||
accService := accountService.New(accountStore, roleStore, accountRoleStore, shopStore, enterpriseStore, auditService)
|
||||
accService := accountService.New(accountStore, roleStore, accountRoleStore, shopRoleStore, shopStore, enterpriseStore, auditService)
|
||||
|
||||
// 获取超级管理员上下文
|
||||
userCtx := env.GetSuperAdminContext()
|
||||
|
||||
Reference in New Issue
Block a user