2 次代码提交 1f6bd9e1a8 ... 8bd7bb6a61

作者 SHA1 备注 提交日期
  Yi 8bd7bb6a61 system: userDepth update 2 周之前
  Yi 1f6bd9e1a8 system: userDepth update 2 周之前
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      module/backend/enum_options.go

+ 2 - 2
module/backend/enum_options.go

@@ -146,7 +146,7 @@ func (s *StoreEntry) CowTransferPenReasonOptions(ctx context.Context) (*pastureP
 	}, nil
 }
 
-// SystemUserOptions 系统用户下拉框   todo 待优化
+// SystemUserOptions 系统用户下拉框  todo 待优化
 func (s *StoreEntry) SystemUserOptions(ctx context.Context, depId int) (*pasturePb.ConfigOptionsListResponse, error) {
 	userModel, err := s.GetUserModel(ctx)
 	if err != nil {
@@ -155,7 +155,7 @@ func (s *StoreEntry) SystemUserOptions(ctx context.Context, depId int) (*pasture
 
 	systemUserList := make([]*model.SystemUser, 0)
 	pref := s.DB.Table(new(model.SystemUser).TableName()).
-		Where("pasture_id = ?", userModel.AppPasture.Id).
+		Where("FIND_IN_SET('?',pasture_ids) > ?", userModel.AppPasture.Id).
 		Where("is_delete = ?", pasturePb.IsShow_Ok).
 		Where("is_show =? ", pasturePb.IsShow_Ok)
 	if depId != -1 && depId > 0 {