Clear empty optional fields.
This commit is contained in:
parent
53113101c9
commit
8a4dd9fb3b
4 changed files with 28 additions and 9 deletions
|
|
@ -112,7 +112,7 @@ func AdminEntityForm(ctx echo.Context, isNew bool, schema *load.Schema, values u
|
|||
}))
|
||||
case field.TypeEnum:
|
||||
options := make([]Choice, 0, len(f.Enums)+1)
|
||||
if f.Nillable {
|
||||
if f.Optional {
|
||||
options = append(options, Choice{
|
||||
Label: "-",
|
||||
Value: "",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue