mirror of
https://github.com/TeaOSLab/EdgeAPI.git
synced 2025-11-22 06:20:25 +08:00
增加修改全体用户功能API
This commit is contained in:
@@ -1,5 +1,21 @@
|
||||
package models
|
||||
|
||||
import (
|
||||
"github.com/TeaOSLab/EdgeCommon/pkg/userconfigs"
|
||||
_ "github.com/go-sql-driver/mysql"
|
||||
_ "github.com/iwind/TeaGo/bootstrap"
|
||||
"github.com/iwind/TeaGo/dbs"
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestUserDAO_UpdateUserFeatures(t *testing.T) {
|
||||
var dao = NewUserDAO()
|
||||
var tx *dbs.Tx
|
||||
err := dao.UpdateUsersFeatures(tx, []string{
|
||||
userconfigs.UserFeatureCodeFinance,
|
||||
userconfigs.UserFeatureCodeServerACME,
|
||||
}, false)
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user