Skip to content

Allow saving records even if required fields are empty #1988

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

Open
3 tasks done
RaschidJFR opened this issue Jan 8, 2022 · 1 comment
Open
3 tasks done

Allow saving records even if required fields are empty #1988

RaschidJFR opened this issue Jan 8, 2022 · 1 comment
Labels
bounty:$20 Bounty applies for fixing this issue (Parse Bounty Program) type:bug Impaired feature or lacking behavior that is likely assumed

Comments

@RaschidJFR
Copy link
Contributor

New Feature / Enhancement Checklist

Current Limitation

The Dashboard won't allow saving objects with required fields left blank, even if these fields could be populated in the beforeSave trigger (for example, due to a more complex logic being required like calling a different microservice).

Feature / Enhancement Description

  1. The dashboard should attempt to save the objects even if one or more required fields are left blank.
  2. If the object(s) is saved successfully (because it was populated by beforeSave), the job is done.
  3. But if the save fails due to any required values missing, then it should highlight the missing fields in red (as currently does).

Example Use Case

Let's say we have a class SmartContract with a required column abiInterface whose value is populated in the beforeSave trigger by calling a microservice, like a function in the blockchain.

Ideally, the user shouldn't worry about populating fields that will be addressed by the cloud logic.

Alternatives / Workarounds

  • Adding any random value to the fields, which will later be updated by beforeSave (making sure the beforeSave logic does not skip populating fields that are not null or empty)
  • Another workaround is to unmark the field as required, but that removes the data integrity check.
  • Another possible solution would be adding a default value (which could later be updated by the triggers), but this feature doesn't seem to work (they don't get loaded anywhere when adding a new record).

3rd Party References

@parse-github-assistant
Copy link

Thanks for opening this issue!

  • 🎉 We are excited about your ideas for improvement!

@mtrezza mtrezza added type:bug Impaired feature or lacking behavior that is likely assumed bounty:$20 Bounty applies for fixing this issue (Parse Bounty Program) labels Jan 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bounty:$20 Bounty applies for fixing this issue (Parse Bounty Program) type:bug Impaired feature or lacking behavior that is likely assumed
Projects
None yet
Development

No branches or pull requests

2 participants