Closed (won't fix)
Project:
Apache Solr Search
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
5 Apr 2011 at 19:51 UTC
Updated:
21 Apr 2011 at 03:42 UTC
Jump to comment: Most recent file
Comments
Comment #1
elliotttf commentedComment #2
pwolanin commentedIs this a change to how core worked in 6?
I thought top-level #submit functions were always called.
Also, not so sure about this patch - typically I'd call apachesolr_settings_form() and then add any additional handlers after the buttons are defined.
Comment #3
elliotttf commentedGood question...
The issue appears to be that the form's #submit callbacks are not firing when the button is handling the #submit
I believe this is how it worked in D6 and in fact it might even be desirable to work that way if for example your submit button should hijack the normal flow of form submission and do something else (like attach a file...).
If that's the case then adding custom submit callbacks afterwards might not fix the problem.
Comment #4
pwolanin commentedOk, so I think the basic answer is that your form builder should call the helper function and then add its submit function onto any buttons where it's relevant.
I don't think this helper should be concerned with a top-level #submit, since it has no way of knowing if it's relevant for all buttons, and any code calling this function will know that buttons with #submit properties are created.
Comment #5
elliotttf commentedOk, here's a reworked patch that addresses the original issue then.
Comment #6
pwolanin commented