fix(widget-select): allow number value type (#4599)
This commit is contained in:
parent
33383af704
commit
9741a79e49
@ -143,6 +143,13 @@ collections: # A list of collections the CMS should be able to edit
|
|||||||
options: ['a', 'b', 'c'],
|
options: ['a', 'b', 'c'],
|
||||||
multiple: true,
|
multiple: true,
|
||||||
}
|
}
|
||||||
|
- {
|
||||||
|
label: 'Select numeric',
|
||||||
|
name: 'select_numeric',
|
||||||
|
widget: 'select',
|
||||||
|
options:
|
||||||
|
[{ label: 'One', value: 1 }, { label: 'Two', value: 2 }, { label: 'Three', value: 3 }],
|
||||||
|
}
|
||||||
- { label: 'Hidden', name: 'hidden', widget: 'hidden', default: 'hidden' }
|
- { label: 'Hidden', name: 'hidden', widget: 'hidden', default: 'hidden' }
|
||||||
- label: 'Object'
|
- label: 'Object'
|
||||||
name: 'object'
|
name: 'object'
|
||||||
|
@ -8,11 +8,12 @@ export default {
|
|||||||
items: {
|
items: {
|
||||||
oneOf: [
|
oneOf: [
|
||||||
{ type: 'string' },
|
{ type: 'string' },
|
||||||
|
{ type: 'number' },
|
||||||
{
|
{
|
||||||
type: 'object',
|
type: 'object',
|
||||||
properties: {
|
properties: {
|
||||||
label: { type: 'string' },
|
label: { type: 'string' },
|
||||||
value: { type: 'string' },
|
value: { oneOf: [{ type: 'string' }, { type: 'number' }] },
|
||||||
},
|
},
|
||||||
required: ['label', 'value'],
|
required: ['label', 'value'],
|
||||||
},
|
},
|
||||||
|
Loading…
x
Reference in New Issue
Block a user