mirror of
https://github.com/YFGaia/dify-plus.git
synced 2026-07-06 16:12:11 +08:00
fix: 修正后台注册的用户权限默认是超级管理员问题
This commit is contained in:
@@ -1,11 +1,12 @@
|
||||
package system
|
||||
|
||||
import (
|
||||
"github.com/flipped-aurora/gin-vue-admin/server/model/common"
|
||||
"github.com/flipped-aurora/gin-vue-admin/server/service/gaia"
|
||||
"strconv"
|
||||
"time"
|
||||
|
||||
"github.com/flipped-aurora/gin-vue-admin/server/model/common"
|
||||
"github.com/flipped-aurora/gin-vue-admin/server/service/gaia"
|
||||
|
||||
"github.com/flipped-aurora/gin-vue-admin/server/global"
|
||||
"github.com/flipped-aurora/gin-vue-admin/server/model/common/request"
|
||||
"github.com/flipped-aurora/gin-vue-admin/server/model/common/response"
|
||||
@@ -152,9 +153,7 @@ func (b *BaseApi) Register(c *gin.Context) {
|
||||
response.FailWithMessage(err.Error(), c)
|
||||
return
|
||||
}
|
||||
// Extend: Start admin init
|
||||
r.AuthorityId = system.AdminGroupID
|
||||
// Extend: stop admin init
|
||||
|
||||
var authorities []system.SysAuthority
|
||||
for _, v := range r.AuthorityIds {
|
||||
authorities = append(authorities, system.SysAuthority{
|
||||
|
||||
Reference in New Issue
Block a user