initial setup for one to many
This commit is contained in:
parent
5ab29ab73e
commit
ce864e118f
|
@ -149,6 +149,10 @@
|
||||||
label="Max Value"
|
label="Max Value"
|
||||||
bind:value={field.constraints.numericality.lessThanOrEqualTo} />
|
bind:value={field.constraints.numericality.lessThanOrEqualTo} />
|
||||||
{:else if field.type === 'link'}
|
{:else if field.type === 'link'}
|
||||||
|
<Toggle
|
||||||
|
bind:checked={field.constraints.oneToMany}
|
||||||
|
thin
|
||||||
|
text="One to many?" />
|
||||||
<Select label="Table" thin secondary bind:value={field.tableId}>
|
<Select label="Table" thin secondary bind:value={field.tableId}>
|
||||||
<option value="">Choose an option</option>
|
<option value="">Choose an option</option>
|
||||||
{#each tableOptions as table}
|
{#each tableOptions as table}
|
||||||
|
|
|
@ -78,6 +78,7 @@ export const FIELDS = {
|
||||||
constraints: {
|
constraints: {
|
||||||
type: "array",
|
type: "array",
|
||||||
presence: false,
|
presence: false,
|
||||||
|
oneToMany: false
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue