Footer callback not working in Bulk.html and Resutls.html + patch solution

I’ve created a Footer callback
(html/Callbacks/MyName/Elements/Footer/Default) in order to add my own text
to the end of every page.

I found that the Footer callback wasn’t called in Bulk.html and Results.html
(both have links to them from the search results page as “Update multiple
tickets” and “Bookmarkable link” respectively).

It seems that the problem is due to over-use of the argument name “$Page” in
RT components.

The callback mechanism is coded in html/Elements/Callback.

This component takes a “$Page” argument as the path of the component that
triggered the callback. If it doesn’t receive the argument (and it never
does in the standard shipped RT), it computes it from the callstack.

As luck has it, html/Search/Bulk.html and Results.html have a "$Page"
argument as well for a totally different purpose (page number of search
result in case of many entries). It has a default value of 1. Therefore,
this argument is passed on to the Footer and to Callback and RT tries to
look for a callback of a component called “1” instead of “Elements/Footer”.

To fix this, I renamed the argument in html/Elements/Callback to be called
"$PageForCallback" (no need to change anything else since no code ever
passes it a value, yet).

I actually did the change in a “local” version of html/Elements/Callback.

It would be great if this fix would enter the RT code base.

Thanks,

This component takes a “$Page” argument as the path of the component that
triggered the callback. If it doesn’t receive the argument (and it never
does in the standard shipped RT), it computes it from the callstack.

As luck has it, html/Search/Bulk.html and Results.html have a “$Page”
argument as well for a totally different purpose (page number of search
result in case of many entries). It has a default value of 1. Therefore,
this argument is passed on to the Footer and to Callback and RT tries to
look for a callback of a component called “1” instead of “Elements/Footer”.

To fix this, I renamed the argument in html/Elements/Callback to be called
“$PageForCallback” (no need to change anything else since no code ever
passes it a value, yet).

Unfortunately, that’s a fairly standard mechanism in custom code to “use
the callbacks of the standard version of the page”

It probably makes more sense to stomp the version coming in from %ARGS