🚧 Refactor backup service
This commit is contained in:
@@ -170,6 +170,9 @@ func (_u *DocumentUpdate) sqlSave(ctx context.Context) (_node int, err error) {
|
||||
}
|
||||
}
|
||||
}
|
||||
if _u.mutation.UUIDCleared() {
|
||||
_spec.ClearField(document.FieldUUID, field.TypeString)
|
||||
}
|
||||
if value, ok := _u.mutation.UpdatedAt(); ok {
|
||||
_spec.SetField(document.FieldUpdatedAt, field.TypeString, value)
|
||||
}
|
||||
@@ -385,6 +388,9 @@ func (_u *DocumentUpdateOne) sqlSave(ctx context.Context) (_node *Document, err
|
||||
}
|
||||
}
|
||||
}
|
||||
if _u.mutation.UUIDCleared() {
|
||||
_spec.ClearField(document.FieldUUID, field.TypeString)
|
||||
}
|
||||
if value, ok := _u.mutation.UpdatedAt(); ok {
|
||||
_spec.SetField(document.FieldUpdatedAt, field.TypeString, value)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user