mirror of
https://github.com/ent/ent.git
synced 2026-05-24 09:31:56 +03:00
schema/field: fix annotations doc example (#1878)
* schema/field: Fix annotation doc example * Update numeric.tpl
This commit is contained in:
@@ -208,9 +208,7 @@ func (b *{{ $builder }}) GoType(typ interface{}) *{{ $builder }} {
|
||||
// codegen extensions.
|
||||
//
|
||||
// field.{{ $tt }}("{{ $t }}").
|
||||
// Annotations(entgql.Config{
|
||||
// Ordered: true,
|
||||
// })
|
||||
// Annotations(entgql.OrderField("{{ $t.String | toUpper }}"))
|
||||
//
|
||||
func (b *{{ $builder }}) Annotations(annotations ...schema.Annotation) *{{ $builder }} {
|
||||
b.desc.Annotations = append(b.desc.Annotations, annotations...)
|
||||
@@ -379,9 +377,7 @@ func (b *{{ $builder }}) GoType(typ interface{}) *{{ $builder }} {
|
||||
// codegen extensions.
|
||||
//
|
||||
// field.{{ $tt }}("{{ $t }}").
|
||||
// Annotations(entgql.Config{
|
||||
// Ordered: true,
|
||||
// })
|
||||
// Annotations(entgql.OrderField("{{ $t.String | toUpper }}"))
|
||||
//
|
||||
func (b *{{ $builder }}) Annotations(annotations ...schema.Annotation) *{{ $builder }} {
|
||||
b.desc.Annotations = append(b.desc.Annotations, annotations...)
|
||||
|
||||
Reference in New Issue
Block a user