From d44c6aa524e92600195ec8dd661dab121a9651cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?John=20Molakvo=C3=A6=20=28skjnldsv=29?= Date: Mon, 7 Dec 2020 15:03:10 +0100 Subject: [PATCH] Add tel, note, org and title search MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: John Molakvoæ (skjnldsv) --- apps/dav/lib/Search/ContactsSearchProvider.php | 4 ++++ .../tests/unit/Search/ContactsSearchProviderTest.php | 12 +++++++++++- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/apps/dav/lib/Search/ContactsSearchProvider.php b/apps/dav/lib/Search/ContactsSearchProvider.php index a76e1f7fef..d92226aa1b 100644 --- a/apps/dav/lib/Search/ContactsSearchProvider.php +++ b/apps/dav/lib/Search/ContactsSearchProvider.php @@ -61,7 +61,11 @@ class ContactsSearchProvider implements IProvider { 'FN', 'NICKNAME', 'EMAIL', + 'TEL', 'ADR', + 'TITLE', + 'ORG', + 'NOTE', ]; /** diff --git a/apps/dav/tests/unit/Search/ContactsSearchProviderTest.php b/apps/dav/tests/unit/Search/ContactsSearchProviderTest.php index 640ada0a9d..7e9fc6d9a4 100644 --- a/apps/dav/tests/unit/Search/ContactsSearchProviderTest.php +++ b/apps/dav/tests/unit/Search/ContactsSearchProviderTest.php @@ -160,7 +160,17 @@ class ContactsSearchProviderTest extends TestCase { $this->backend->expects($this->once()) ->method('searchPrincipalUri') ->with('principals/users/john.doe', 'search term', - ['N', 'FN', 'NICKNAME', 'EMAIL', 'ADR'], + [ + 'N', + 'FN', + 'NICKNAME', + 'EMAIL', + 'TEL', + 'ADR', + 'TITLE', + 'ORG', + 'NOTE', + ], ['limit' => 5, 'offset' => 20]) ->willReturn([ [