Closed (fixed)
Project:
Multiple forms
Version:
7.x-1.x-dev
Component:
Code
Priority:
Major
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
27 Jun 2012 at 18:44 UTC
Updated:
21 Dec 2018 at 03:59 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
azinck commentedThis seems to happen with any error on the form, not just required fields.
Comment #2
kpv commentedSee #1870120: Add Delayed submit functionality - branch 7.x-2.x
Comment #3
dave reidMarked #1958722: No redirection when a custom required field is empty as a duplicate of this issue.
Comment #4
tobiasb* The attached patch do not redirect the form with some errors.
* Problems is Drupal shows the red border on all fields (example) from the n-"forms"
Comment #5
crifi commentedDoes somebody know the sense of $form_state['no_redirect'] and $redirect['no_redirect']? Maybe we should only unset $redirect['no_redirect'] without form errors?
Comment #6
miroslavbanov commentedPatch #4 did help for the media callback admin/content/file/edit-multiple to not redirect on validation error for me.
Comment #7
timwoodPatch in #4 helps, but there is still an issue when the FIRST of multiple files being uploaded/edited does NOT have a validation error but subsequent files DOES. In this case parts of the resulting form are broken, a message appears that the one file was updated, yet that files fields are still part of the multiple form. Once you correct all validation errors for all files it will save.
Comment #8
lplp commentedTried to reproduce the issue in #7 - having applied the patch in #4.
Yes I agree the files are not being handled ideally.
However I think that is a different issue. When all files are validated correctly, saving & redirecting works just fine and it will never save an uncorrectly validated file.
Whenever some of all added files still have errors, it will handle it differently each time (can't find the pattern just yet, didn't get the same issue as in #7 all the time). Sometimes it will go ahead and update the correctly validated files and give an error for the uncorrect ones. Sometimes it will just give the error and wait for you to have all the files correct before proceedng. But it will never save an uncorrect file and it will wait for you to correct it before redirecting, which is good.
SO at least the patch in #4 does fix the redirect problem and it will not update files that have an error, only correct ones.
I think patch #4 works but a new issue shoud be submitted for the issue in #7.
Comment #9
joseph.olstad#7 issue was fixed in release 7.x-1.3
lets queue this patch for testing
Comment #10
joseph.olstadComment #12
iliana_ng commentedI submit an update of #1 patch for 7.x-1.3 version
Comment #13
joseph.olstadtrigger tests
Comment #14
joseph.olstad@iliana_ng , had a look at your patch, it is the same patch as patch #9 , therefore, expect 1 fail.
Comment #16
stefan.kornProviding reworked patch, that does change tests as well. While not very familiar with testing, I suppose there is something wrong with the tests rather than with the patch from 9 and 12 itself.
So hopefully this will now pass the tests.
Comment #17
stefan.kornComment #19
stefan.kornhm, give it another try.
Comment #20
stefan.kornComment #22
stefan.kornSorry for the noise, but I have no local testing environment. So trying another one.
Comment #23
stefan.kornComment #25
stefan.kornand again
Comment #26
stefan.kornComment #27
stefan.kornOk, now finally the test passed. As I explained before, I am not very experienced with testing, so someone should surely check my changes in the test file.
But I think there was something wrong within the test and maybe the tests where seeming to succeed previously because the error handling was not correct at all.
Comment #28
joseph.olstadComment #29
chris matthews commentedWould it be possible to commit the patch in #25 to 7.x-1x-dev and tag a 7.x-1.5 release?
Comment #31
joseph.olstad