mirror of
https://github.com/ent/ent.git
synced 2026-05-24 09:31:56 +03:00
entc/gen/template: convert spaces to tabs (#1060)
This commit also fix a typo Receiver
This commit is contained in:
@@ -37,7 +37,7 @@ var schemaGraph = func() *sqlgraph.Schema {
|
||||
Type: "{{ $n.Name }}",
|
||||
Fields: map[string]*sqlgraph.FieldSpec{
|
||||
{{- range $f := $n.Fields }}
|
||||
{{ $n.Package }}.{{ $f.Constant }}: {Type: field.{{ $f.Type.ConstName }}, Column: {{ $n.Package }}.{{ $f.Constant }}},
|
||||
{{ $n.Package }}.{{ $f.Constant }}: {Type: field.{{ $f.Type.ConstName }}, Column: {{ $n.Package }}.{{ $f.Constant }}},
|
||||
{{- end }}
|
||||
},
|
||||
}
|
||||
@@ -125,7 +125,7 @@ type predicateAdder interface {
|
||||
}
|
||||
{{ end }}
|
||||
|
||||
{{ range $e := $n.Edges }}
|
||||
{{ range $e := $n.Edges }}
|
||||
{{ $func := print "WhereHas" $e.StructField }}
|
||||
// {{ $func }} applies a predicate to check if query has an edge {{ $e.Name }}.
|
||||
func (f *{{ $filter }}) {{ $func }}() {
|
||||
@@ -141,7 +141,7 @@ type predicateAdder interface {
|
||||
}
|
||||
})))
|
||||
}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
{{ end }}
|
||||
|
||||
Reference in New Issue
Block a user