-
Notifications
You must be signed in to change notification settings - Fork 35
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
Enable creation of empty seedlots #5159
base: master
Are you sure you want to change the base?
Conversation
Would it be better to require a weight or count but allow 0s? That way no one accidentally skips those fields without meaning to and there's still a value in one at least one of them. Or, alternatively, you could give a warning message so that users have to confirm that they want to create a seedlot with no weight and no count. |
I'd say warning message makes the most sense to me. Without knowing who requested this feature I speculate that they want to be able to make a bunch of seedlot entries all at once in anticipation of seed collection and then go back and edit the data once they actually have the seeds collected. Giving a warning popup handles both this case and the case where someone just forgot to enter the data and needs to go back. |
Sounds good to me! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is the check that the value be numeric still there?
Yes, the check that a value be numeric should still be there |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
:-)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, I found an issue: when I added 0 as the count, it appeared as NA in the seedlot later. Shouldn't it appear as 0? May be due to the fact that 0 is also false in Perl...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a warning if the user chooses to make both count and weight empty to make sure that was on purpose.
There are a couple of issues I'm seeing:
|
Thanks, Amber - I'll check about the spaces and update this PR. On your other point, after some discussion, we are just going to use this PR to allow the user to create an empty seedlot by using zero values in either the amount or weight fields. Leaving both fields blank is not an option going forward. This will be followed by another ticket/PR that implements the user having to commit to one or the other, and will address the issue of the 0 values actually appearing as 0 values. |
Description
This PR allows users to create empty seedlots as placeholders (i.e., seedlots with no/zero seed weight values or seed count values), as this seems desirable for certain users.
Closes #5157
Checklist
/t/data/fixture/patches/
./docs
has been updated./js
to/js/source/legacy
.