-
Notifications
You must be signed in to change notification settings - Fork 65
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
Fix multiple issues with resource submission #390
Conversation
- Don't create multiple orders when a resource is saved as draft before being submitted - Fix acquisitionType selection when editing a resource saved as draft - Remove dead code
This is the last open PR tagged for 3.0 with an important label. I'll try to take a look over the weekend and see if I can test it, unless someone else beats me to it, or it gets moved to the parking lot for this beta. |
I was getting a PHP Fatal Error when testing this:
I committed a fix that adds quotes around the Otherwise this PR fixes the issues as laid out in the test plan. |
I'm probably the last one working today, so I'll go ahead and merge this, but anyone else can test it out after it is merged as well. |
@t4k Was this a bug introduced with the multiple orders feature? |
@scottvieira Yes, it looks like it was introduced in #244. |
Yes, it was. |
@t4k and @veggiematts Thank you both! |
Don't create multiple orders when a resource is saved as draft before being submitted
Test plan:
Before the fix: Create a resource. Save it as draft, validate the resource. Two default orders will be created instead of one. If you edit the resource as draft multiple times before validating it, multiple default orders will be created.
After the fix: Proceed as before. Check that only one default order has been created when the resource is validated.
Fix acquisitionType selection when editing a resource saved as draft
Test plan:
Remove dead code: a ResourcePayment array was created and never used.