1
0
Fork 0
mirror of synced 2024-07-15 11:15:59 +12:00

Allow primary keys to be foreign key (#9331)

This commit is contained in:
melohagan 2023-01-13 11:22:59 +00:00 committed by GitHub
parent e55f4d1981
commit 5477cf420a

View file

@ -340,9 +340,7 @@
{:else if isManyToOne && toTable}
<Select
label={`Foreign Key (${toTable?.name})`}
options={Object.keys(toTable?.schema).filter(
field => toTable?.primary.indexOf(field) === -1
)}
options={Object.keys(toTable?.schema)}
on:change={() => ($touched.foreign = true)}
bind:error={errors.foreign}
bind:value={fromRelationship.fieldName}