mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-24 16:03:43 +08:00
Merge pull request #4602 from rainzm/bugfix/notify_filter_contact
fix(notify): Fix the error of filter about contact
This commit is contained in:
Vendored
+2
-7
@@ -103,13 +103,8 @@ func (ucm *SUserCacheManager) FetchUserLikeName(ctx context.Context, name string
|
||||
// todo
|
||||
return nil, fmt.Errorf("FetchUserLikeName with check Not Implement")
|
||||
}
|
||||
q := ucm.Query().Like("name", "%"+name+"%")
|
||||
users := make([]SUser, 0)
|
||||
err := db.FetchModelObjects(ucm, q, &users)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return users, nil
|
||||
q := ucm.Query().Contains("name", name)
|
||||
return ucm.FetchUserFromLoaclCache(ctx, q)
|
||||
}
|
||||
|
||||
func (ucm *SUserCacheManager) FetchUserFromLoaclCache(ctx context.Context, q *sqlchemy.SQuery) ([]SUser, error) {
|
||||
|
||||
Reference in New Issue
Block a user