Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for escopos (0.06 sec)

  1. generics.go

    	return chainG[T]{
    		execG: execG[T]{g: &g[T]{
    			db:  c.g.db,
    			ops: append(append([]op(nil), c.g.ops...), v),
    		}},
    	}
    }
    
    func (c chainG[T]) Scopes(scopes ...func(db *Statement)) ChainInterface[T] {
    	return c.with(func(db *DB) *DB {
    		for _, fc := range scopes {
    			fc(db.Statement)
    		}
    		return db
    	})
    }
    
    func (c chainG[T]) Table(name string, args ...interface{}) ChainInterface[T] {
    Registered: Sun Sep 07 09:35:13 UTC 2025
    - Last Modified: Thu Sep 04 13:13:16 UTC 2025
    - 15.5K bytes
    - Viewed (0)
  2. statement.go

    	}
    
    	if len(stmt.Joins) > 0 {
    		newStmt.Joins = make([]join, len(stmt.Joins))
    		copy(newStmt.Joins, stmt.Joins)
    	}
    
    	if len(stmt.scopes) > 0 {
    		newStmt.scopes = make([]func(*DB) *DB, len(stmt.scopes))
    		copy(newStmt.scopes, stmt.scopes)
    	}
    
    	stmt.Settings.Range(func(k, v interface{}) bool {
    		newStmt.Settings.Store(k, v)
    		return true
    	})
    
    	return newStmt
    }
    
    Registered: Sun Sep 07 09:35:13 UTC 2025
    - Last Modified: Thu Sep 04 13:13:16 UTC 2025
    - 20.8K bytes
    - Viewed (0)
  3. tests/generics_test.go

    	filterName1 := func(stmt *gorm.Statement) {
    		stmt.Where("name = ?", "GenericsScopes1")
    	}
    
    	results, err := gorm.G[User](DB).Scopes(filterName1).Find(ctx)
    	if err != nil {
    		t.Fatalf("Scopes failed: %v", err)
    	}
    	if len(results) != 1 || results[0].Name != "GenericsScopes1" {
    		t.Fatalf("Scopes expected 1, got %d", len(results))
    	}
    
    Registered: Sun Sep 07 09:35:13 UTC 2025
    - Last Modified: Thu Sep 04 13:13:16 UTC 2025
    - 28K bytes
    - Viewed (0)
  4. docs/en/docs/release-notes.md

    ## 0.13.0
    
    * Improve/upgrade OAuth2 scopes support with `SecurityScopes`:
        * `SecurityScopes` can be declared as a parameter like `Request`, to get the scopes of all super-dependencies/dependants.
        * Improve `Security` handling, merging scopes when declaring `SecurityScopes`.
    Registered: Sun Sep 07 07:19:17 UTC 2025
    - Last Modified: Fri Sep 05 12:48:45 UTC 2025
    - 544.1K bytes
    - Viewed (0)
Back to top