Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for relForeignKeys (0.14 sec)

  1. callbacks/preload.go

    			if ref.OwnPrimaryKey {
    				relForeignKeys = append(relForeignKeys, ref.ForeignKey.DBName)
    				relForeignFields = append(relForeignFields, ref.ForeignKey)
    				foreignFields = append(foreignFields, ref.PrimaryKey)
    			} else if ref.PrimaryValue != "" {
    				tx = tx.Where(clause.Eq{Column: ref.ForeignKey.DBName, Value: ref.PrimaryValue})
    			} else {
    				relForeignKeys = append(relForeignKeys, ref.PrimaryKey.DBName)
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Wed Jun 12 10:52:33 UTC 2024
    - 11.6K bytes
    - Viewed (0)
  2. callbacks/delete.go

    				)
    
    				for _, ref := range rel.References {
    					if ref.OwnPrimaryKey {
    						foreignFields = append(foreignFields, ref.PrimaryKey)
    						relForeignKeys = append(relForeignKeys, ref.ForeignKey.DBName)
    					} else if ref.PrimaryValue != "" {
    						queryConds = append(queryConds, clause.Eq{
    							Column: clause.Column{Table: rel.JoinTable.Table, Name: ref.ForeignKey.DBName},
    							Value:  ref.PrimaryValue,
    						})
    					}
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Fri Feb 25 02:48:23 UTC 2022
    - 5.6K bytes
    - Viewed (0)
  3. schema/relationship.go

    	table := rel.FieldSchema.Table
    	foreignFields := []*Field{}
    	relForeignKeys := []string{}
    
    	if rel.JoinTable != nil {
    		table = rel.JoinTable.Table
    		for _, ref := range rel.References {
    			if ref.OwnPrimaryKey {
    				foreignFields = append(foreignFields, ref.PrimaryKey)
    				relForeignKeys = append(relForeignKeys, ref.ForeignKey.DBName)
    			} else if ref.PrimaryValue != "" {
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Wed Jun 12 03:46:59 UTC 2024
    - 22.7K bytes
    - Viewed (0)
Back to top