Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for TestEmbeddedBelongsTo (0.29 sec)

  1. schema/relationship_test.go

    						References: []Reference{
    							{ForeignKey: "Type", ForeignSchema: "Toy", PrimaryValue: "users"},
    						},
    					},
    				},
    			},
    		})
    	})
    }
    
    func TestEmbeddedBelongsTo(t *testing.T) {
    	type Country struct {
    		ID   int `gorm:"primaryKey"`
    		Name string
    	}
    	type Address struct {
    		CountryID int
    		Country   Country
    	}
    	type NestedAddress struct {
    		Address
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Mon Apr 15 03:20:20 GMT 2024
    - 25.5K bytes
    - Viewed (0)
Back to top