entc/gen: initial work for supporting uuid fields in codegen

Summary: Pull Request resolved: https://github.com/facebookincubator/ent/pull/182

Reviewed By: alexsn

Differential Revision: D18638199

fbshipit-source-id: 0de79c78b51e544486c07a004c3c8ea82e5c3398
This commit is contained in:
Ariel Mashraki
2019-11-24 07:00:37 -08:00
committed by Facebook Github Bot
parent e6c6442c84
commit 67c3fd2db9
81 changed files with 1914 additions and 94 deletions

View File

@@ -130,6 +130,7 @@ func (nc *NodeCreate) sqlSave(ctx context.Context) (*Node, error) {
insert.Set(node.FieldValue, *value)
n.Value = *value
}
id, err := insertLastID(ctx, tx, insert.Returning(node.FieldID))
if err != nil {
return nil, rollback(tx, err)