Refactor code

This commit is contained in:
cuigh
2021-12-16 20:23:08 +08:00
parent c3115b952c
commit 6705bd6d64
51 changed files with 848 additions and 1176 deletions

View File

@@ -8,6 +8,7 @@ import (
"github.com/cuigh/auxo/security/passwd"
"github.com/cuigh/swirl/biz"
"github.com/cuigh/swirl/misc"
"github.com/cuigh/swirl/model"
)
type Authenticator struct {
@@ -92,7 +93,7 @@ func ldapRealm(s *misc.Setting, ub biz.UserBiz) RealmFunc {
lu = user.(*ldap.User)
)
if u == nil {
id, err = ub.Create(&biz.User{
id, err = ub.Create(&model.User{
Type: biz.UserTypeLDAP,
LoginName: loginName,
Name: lu.Name(),