Merge branch 'master' into dev
This commit is contained in:
commit
e58ab28787
2 changed files with 19 additions and 0 deletions
|
@ -17,6 +17,16 @@ type {{$modelName}} struct {
|
||||||
{{end -}}
|
{{end -}}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var {{$modelName}}Columns = struct {
|
||||||
|
{{range $column := .Table.Columns -}}
|
||||||
|
{{titleCase $column.Name}} string
|
||||||
|
{{end -}}
|
||||||
|
}{
|
||||||
|
{{range $column := .Table.Columns -}}
|
||||||
|
{{titleCase $column.Name}}: "{{$column.Name}}",
|
||||||
|
{{end -}}
|
||||||
|
}
|
||||||
|
|
||||||
{{- if .Table.IsJoinTable -}}
|
{{- if .Table.IsJoinTable -}}
|
||||||
{{- else}}
|
{{- else}}
|
||||||
// {{$modelNameCamel}}R is where relationships are stored.
|
// {{$modelNameCamel}}R is where relationships are stored.
|
||||||
|
|
9
templates/singleton/boil_table_names.tpl
Normal file
9
templates/singleton/boil_table_names.tpl
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
var TableNames = struct {
|
||||||
|
{{range $table := .Tables -}}
|
||||||
|
{{titleCase $table.Name}} string
|
||||||
|
{{end -}}
|
||||||
|
}{
|
||||||
|
{{range $table := .Tables -}}
|
||||||
|
{{titleCase $table.Name}}: "{{$table.Name}}",
|
||||||
|
{{end -}}
|
||||||
|
}
|
Loading…
Reference in a new issue