mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-23 22:10:55 +01:00
Search by full path in Owners
Summary: Search tool currently allows only searching by substring which is useful. But searching by the full path (for packages in which the path is contained) is probably even more useful. NOTE: I used a trick to perform the search by superstring. Packages containing path '/' are found always which could seem strange but it is correct after all. Test Plan: Search for /src/x/a.php. Found package with path /src/x/. Search for /src/. Found package with path /src/x/. Reviewers: epriestley Reviewed By: epriestley CC: aran, epriestley Differential Revision: https://secure.phabricator.com/D1560
This commit is contained in:
parent
17b6649552
commit
67ea5a0b61
1 changed files with 4 additions and 2 deletions
|
@ -57,8 +57,10 @@ class PhabricatorOwnersListController extends PhabricatorOwnersController {
|
|||
$path->getTableName());
|
||||
$where[] = qsprintf(
|
||||
$conn_r,
|
||||
'path.path LIKE %~',
|
||||
$request->getStr('path'));
|
||||
'path.path LIKE %~ OR %s LIKE CONCAT(path.path, %s)',
|
||||
$request->getStr('path'),
|
||||
$request->getStr('path'),
|
||||
'%');
|
||||
}
|
||||
|
||||
if ($request->getArr('owner')) {
|
||||
|
|
Loading…
Reference in a new issue