View definition

(*DB).FirstOrInit

Defined in github.com/jinzhu/gorm/main.go

Description

FirstOrInit find first matched record or initialize a new one with given conditions (only works with struct, map conditions) https://jinzhu.github.io/gorm/curd.html#firstorinit

FirstOrInit is referenced in 9 repositories

github.com/jinzhu/gorm github.com/hobeone/tv2go github.com/jmrobles/outbarriers

...