-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve multi-create workflow for almost pure and binary relationships #2416
Comments
This comment was marked as outdated.
This comment was marked as outdated.
Names for property:
Values for property:
Annotations to add to:visible-columns
|
true | null usage in configurationNOTE: annotationsnull is needed to override inheritance
null means undefined, same as not existing in schema document
|
The first part of this issue has been implemented. This issue is pending annotation changes to allow for configuring this without relying on the heuristics. |
This issue focuses on tables that are almost pure and binary associations. These tables have 2 foreign keys and some static columns. A good example of this is the
Protocol_Author
table in atlas-d2k. We want to be able to create rows using the modal interface but also need a way to allow for setting values for these associated rows after selections have been made in the modal.To improve this workflow, we are changing what the
Add records
button does on record page for inbound foreign keys when certain criteria are met. If the table is "almost a pure and binary association" and has other columns that are not foreign keys, we will trigger the following alternate workflow. Currently for adding protocol author associations, add records opensrecordedit
app with only 1 row and the "author" value is empty.Workflow change:
We discussed changing the workflow to the following for adding rows to an association like table when the pair of foreign keys are a unique relation (1 table entry for X main entity and Y leaf entity pair) and non-unique (N table entries for X main entity and Y leaf entity pair):
a. in the case that the pair of foreign keys are a part of a unique key, this modal will show selected rows from step 2 as "greyed" out since they can't be chosen again
Notes:
Annotation changes to make:
Properties to add to annotations will be
bulk_create_foreign_key
andbulk_create_foreign_key_candidates
in 1 case (table-display). Annotations to change include:display
annotation on catalog, schema, and table,table-display
annotation, display property of theforeign-key
annotation, and the display property of the column directive syntax used invisible-columns
annotation.Notes:
["schema_name", "foreign_key_name"]
: foreign key name to be used as the foreign key input being bulk selected if that foreign key is in the visible columns list_constraintName
inermrestJS
for foreign key pseudo columnsfalse
: Turns off the heuristics that trigger this feature.null
: Overrides inheritance for this property and use the default heuristics.display
only allows for turning off the feature or ignoring inherited values and using default heuristicsdisplay
annotation and this is being turned on for 1 specific tabletable-display
would allow for multiple foreign keys to be defined that are checked based on the columns visibility to the userforeign-key
, defined on one foreign key relationship and be unidirectionalvisible-columns
, like foreign key above, this would be defined on one foreign key of the relationship and be unidirectionalThe text was updated successfully, but these errors were encountered: