- Sort Score
- Result 10 results
- Languages All
Results 1 - 3 of 3 for removeSettingFromTag (0.55 sec)
-
schema/utils_test.go
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Fri Jul 31 10:19:25 UTC 2020 - 1.5K bytes - Viewed (0) -
schema/utils.go
} func toColumns(val string) (results []string) { if val != "" { for _, v := range strings.Split(val, ",") { results = append(results, strings.TrimSpace(v)) } } return } func removeSettingFromTag(tag reflect.StructTag, names ...string) reflect.StructTag { for _, name := range names { tag = reflect.StructTag(regexp.MustCompile(`(?i)(gorm:.*?)(`+name+`(:.*?)?)(;|("))`).ReplaceAllString(string(tag), "${1}${5}")) }
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Sat Aug 19 13:35:14 UTC 2023 - 5.5K bytes - Viewed (0) -
schema/relationship.go
joinTableFields = append(joinTableFields, reflect.StructField{ Name: joinFieldName, PkgPath: ownField.StructField.PkgPath, Type: ownField.StructField.Type, Tag: removeSettingFromTag(appendSettingFromTag(ownField.StructField.Tag, "primaryKey"), "column", "autoincrement", "index", "unique", "uniqueindex"), }) } for idx, relField := range refForeignFields {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Wed Jun 12 03:46:59 UTC 2024 - 22.7K bytes - Viewed (0)