Stop hiding the Status select when refining.

This restriction dates from when RTIR had a State Custom Field, before
we could use Lifecycles to create Queue-specific status sets.
Remove another double-tag
Remove an erroneous arg added in 1dda1b71ab0626

Passing just this one argument means that we'll always just select
Incident Reports when clicking on Reply.  It's much more helpful if
clicking Reply selects the current set of selected lists.
Carry forward SelectFooAll links in the Refine mechanism

Without this, Reply will uncheck all the checkboxes.
This follows on a long twisty history detailed in cff337b.
Remove 'New Search' on subsearch pages

Places such as the Merge list or Link list or other places where you
search for a list of Incidents or Reports while performing an action
have an Edit Search as well as New Search link.  Unfortunately, New
Search takes you to a blank search without any Queues and doesn't
provide a way to select Queues (this is because of an explicit choice in
the PickBasics callbacks).  It's unclear what the behavior should be.
Should it force you to the 'sane' set of Queues?  If so, that's actually
a sizable feature to implement, and as this is a new feature in
2.9-trunk and doesn't currently work, I'm removing it until it can be
implemented properly.

This caused t/walk-web.t to run less tests (because less tabs) so adjust
the count there.
Give the Search form an id so that core CSS applies.

Without this, the Add these terms (and search) buttons will float behind
the Saved Search box on pages without long Add Criteria sections.
Pass a requested argument to Refine.html

In 0d7b8d5 Refine.html was created expecting a Queue argument, but it
was never passed in from Tabs.
Stop using Mason Notes and just pass Arguments.

This makes RTIR more like core, which passes %TabArgs in a few places.

This reveals a number of misconceptions in the Refine code.  It was
relying on the ShowResults code to clobber $session{'tickets'}, which is
a bug that was fixed in 8d3cc5fa0.

This reliance on being able to grovel in your session meant that
whatever search you ran last would show up when you clicked on Edit
Search on a Merge (or other) Refine page.  So, if you were Merging
something and went to visit your homepage, or looked at any other
Incident, you'd see some completely irrelevant search.

Instead, we're now *explicit* about the passed information.
We still have to separate the Query and BaseQuery because RTIR's search
is built around that distinction, but from now on, clicking Edit Search
will edit the search that was run to generate the Merge page.  This
includes passing the correct Format.

This change, plus the previous change to make Add these terms and Search
work means that you can now visit an Incident page, click Merge, click
Edit search, search for a resolved Incident as well as one that's open,
click back to see results and then merge into a resolved incident.

We could no longer rely simply on $m->notes in one place because you
must change the Tabs from each of the Entry pages (/Merge/index.html)
and not *just* on Refine.html, which is much too late.  There will be
several follow on commits to resolve the other places that relied on
this erroneous code.
Grab and pass along the id of the Ticket we're working from.

None of the Refine Page Menus contain the ticket id after any action on
the Query Builder page.

From an Incident, visiting Merge -> Edit Search -> Add these terms ->
Merge fails because of this.

Any attempt to click on Add these terms and Search from a refine page
takes you to an error page about being unable to load the ticket the
re-calculation of $ResultPage cannot work without access to the original
id that was in the query args when we started.

The other solution to this involves swapping ARGS so taht ResultPage is
taken from the submission, but that doesn't fix the Page Menus.
Pass through all the arguments on Incident Reply

Without this, you'll lose any checkbox state when you edit the search.
It also ensure that knowing *which* types of children to search for are
passed back through.

Right now, nothing else uses the ExtraQueryParams argument, but we may
find another Refine UI which needs it.
Properly set QueryBuilder arguments for Linking searches

This allows editing of a search when choosing which Incidents to link to
(or from).  Without this, you never got the correct search setup and it
never passed back properly when running the updated search.
No longer allow Editing of the Children search

Because we use ShowChildren, it's relatively difficult to pass along the
relevant search parameters like we've been doing for all the other Edit
Search updates.

Because Children/index.html doesn't pass along updates from Refine.html
back into the search, I'm not sure how this code was ever supposed to
update the Query being run by ShowChildren.  Changing this became
invasive quickly, and this is a new feature since 2.6 so we'll remove it
rather than introduce even buggier code.

Unlike other lists fixed on this branch, this UI *does* allow filtering
by status, so while you can't build more complicated filters, you can at
least do that.
Rename RefineArgs to SearchArgs

We're passing these along to better support searching, and it looks like
this is needed even outside the Refine code.
Pass search state to the RTIR Search UI

Like all the Refine pages fixed in earlier commits, this ensures that
the menuing code has access to the current state of the search being
worked on and can properly set up links.
Limit what Menus are shown on a New Search

In core, New Search shows you Edit Search and Advanced.  Since Advanced
isn't an option in RTIR, limit ourselves to Edit Search.
Don't send full search interface into the limited Refine interface.

Refine.html hides the Queue selector, so this is terrible for the full
search interface.

I've made the decision that New Search doesn't work for the sub-search
interfaces (such as BuilkReject and BulkAbandon) so we don't even show
New Search there.

Ensure that the Bulk UIs do get the Refine view when editing searches.
Add a QueryString to the top-level Search Results link.

We don't need it on Search/index.html for the "Build Search" link
because ProcessQuery will look in the search for us.

Because of all the groveling done here, the number of tests basically
trebles in t/walk-web.t.  This warrants more investigation.

Most of this code was borrowed from RT and included in a much larger
commit - 6076487.

Remove the unneeded comment and empty else clause (?).
More consistent Search naming

We say New and Edit Search everywhere else (including the in the
PageMenu tabs on /Search/) so we should say that in the menus too.
Switch to DECODED_ARGS from request_args

The rationale for using this is in RT's 17bc0c1 but the biggest change
is having access to the utf8-decoded values.
Initial caps for params passed in link to Shredder