- Sort Score
- Result 10 results
- Languages All
Results 1 - 4 of 4 for done (0.13 sec)
-
tests/hooks_test.go
} if DB.Where("code = ?", "dont_update").First(&Product{}).Error == nil { t.Fatalf("Record Should not be updated due to errors happened in before update callback") } p2.Code = "dont_save" if DB.Save(&p2).Error == nil { t.Fatalf("An error from before save callbacks happened when update with invalid value") } p3 := Product{Code: "dont_delete", Price: 100} DB.Save(&p3)
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Sat Feb 18 01:20:29 GMT 2023 - 15.9K bytes - Viewed (0) -
tests/preload_test.go
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Thu Apr 25 12:21:03 GMT 2024 - 14.9K bytes - Viewed (0) -
schema/relationship.go
// The following code is basically called in for. // In order to avoid the performance problems caused by repeated compilation of regular expressions, // it only needs to be done once outside, so optimization is done here. if idx != -1 && regEnLetterAndMidline.MatchString(str[0:idx]) { name = str[0:idx] } else { name = rel.Schema.namer.RelationshipFKName(*rel) } constraint := Constraint{
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Mon Apr 15 03:20:20 GMT 2024 - 22.4K bytes - Viewed (0) -
tests/associations_many2many_test.go
var wg sync.WaitGroup for i := 0; i < count; i++ { wg.Add(1) go func(user User, language Language) { err := db.Model(&user).Association("Languages").Append(&language) AssertEqual(t, err, nil) wg.Done() }(user, languages[i]) } wg.Wait() var find User err = db.Preload(clause.Associations).Where("id = ?", user.ID).First(&find).Error AssertEqual(t, err, nil)
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Sat Jun 10 13:05:19 GMT 2023 - 13.2K bytes - Viewed (0)