schema/index: update index comments (#1814)

* update index comments

* Update schema/index/index.go

Co-authored-by: Ariel Mashraki <7413593+a8m@users.noreply.github.com>
This commit is contained in:
Mohammed Salman
2021-08-08 12:55:04 +03:00
committed by GitHub
parent e0a85ab609
commit 710d5d77e9

View File

@@ -31,7 +31,7 @@ type Builder struct {
//
// // Unique index of field under specific edge.
// index.Fields("name").
// FromEdges("parent").
// Edges("parent").
// Unique(),
//
// }
@@ -46,7 +46,7 @@ func Fields(fields ...string) *Builder {
// func (T) Indexes() []ent.Index {
//
// // Unique index of field under 2 edges.
// index.Field("name").
// index.Fields("name").
// Edges("parent", "type").
// Unique(),
//
@@ -105,10 +105,8 @@ func (b *Builder) StorageKey(key string) *Builder {
// func (T) Indexes() []ent.Index {
//
// // Partial index on name where the entity is not deleted.
// index.Field("name").
// Annotations(index.Annotation{
// WhereClause: "deleted_at is not null",
// })
// index.Fields("name").
// Annotations(entsql.Prefix(100))
//
// }
//