Skip to content
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

Conditional Expression Not Applied on Refback-Linked Entry Creation #4408

Open
Fernananas opened this issue Oct 29, 2024 · 0 comments
Open
Assignees
Labels
bug Something isn't working ern
Milestone

Comments

@Fernananas
Copy link

What version of EMX2 are you using (see footer)
Software version: v11.25.0

Describe the bug
When creating an Order entry via a refback from Pet in the Petstore schema, the conditional expression set on the price column of the Order table is not applied. This results in missing mandatory fields when editing the entry directly in the Order table, as the conditional logic is bypassed during refback creation.

To Reproduce
Steps to reproduce the behavior:

  1. Go to 'https://emx2.dev.molgenis.org'
  2. Create petstore database, use template (without data)
  3. Set up references in the Petstore schema:
    Order has a ref to Pet.
    Pet has a refback to Order.
  4. In the Order table, add a computed column categoryPet with the expression pet?.category?.name.
  5. Add a conditional expression on the Order table's price column with the condition categoryPet === "test".
  6. Test the setup:
    Create a category named "test".
    Create a Pet entry and save it.
    Edit the Pet entry to add an Order, filling in all mandatory fields.
  7. Go to the Order table, and edit the entry created via the Pet refback.
  8. See error

Expected behavior
All mandatory fields should be filled, and the conditional expression should apply correctly.

Actual Behavior
Not all mandatory fields are filled in Order because the conditional expression on price is not applied when the entry is created via the Pet refback.

Screenshots
If applicable, add screenshots to help explain your problem.
Scherm­afbeelding 2024-10-29 om 14 00 13
Scherm­afbeelding 2024-10-29 om 14 00 41

@Fernananas Fernananas added bug Something isn't working ern labels Oct 29, 2024
@Fernananas Fernananas added this to the Backlog milestone Oct 29, 2024
@harmbrugge harmbrugge self-assigned this Oct 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working ern
Projects
None yet
Development

No branches or pull requests

2 participants