Expose sort orders from search engine in ApiQuerySearch
authorErik Bernhardson <ebernhardson@wikimedia.org>
Sat, 19 May 2018 13:42:54 +0000 (06:42 -0700)
committerErik Bernhardson <ebernhardson@wikimedia.org>
Wed, 13 Jun 2018 15:57:16 +0000 (08:57 -0700)
commit7bf3c405063370e101cf91c65f5356d057820622
tree50c677f6720d1683328b4e8d5cd40f01252d4bf0
parent8eb6cf585c5fb3d7dd5f014bac27518959512b98
Expose sort orders from search engine in ApiQuerySearch

Selectable sort orders were added to search some time ago, but never
appear to have been used.  Expose them in ApiQuerySearch.

There is one large problem here, but it's not easily solvable.
Specifically supported sort orders vary per search engine, but the
available api parameters are calculated with the default search
engine. This is already a problem with search profiles so it's
nothing new, just continuing the existing problem. Much like
search profiles we hide the functionality when multiple engines
are available.

Bug: T195071
Change-Id: I187a530bc973c08386d2c2126e02a85b952d9022
includes/api/ApiQuerySearch.php
includes/api/i18n/en.json
includes/api/i18n/qqq.json