From 035bf5c318515406912678716e059b8e8546ce02 Mon Sep 17 00:00:00 2001 From: Aldrik Ramaekers Date: Sun, 12 Oct 2025 14:13:32 +0200 Subject: contact search filter --- include/administration.hpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'include/administration.hpp') diff --git a/include/administration.hpp b/include/administration.hpp index ebb30d0..c046dba 100644 --- a/include/administration.hpp +++ b/include/administration.hpp @@ -96,6 +96,11 @@ typedef struct char bank_account[MAX_LEN_BANK]; } contact; +typedef struct +{ + char name_filter[MAX_LEN_LONG_DESC]; +} contact_filter; + typedef enum { PROJECT_RUNNING, @@ -477,7 +482,7 @@ namespace administration { // Contact functions. // ======================= - u32 contact_count(); + u32 contact_count(contact_filter* filter = 0); contact contact_create_empty(); a_err contact_import(contact data); a_err contact_add(contact data); @@ -490,7 +495,7 @@ namespace administration { a_err contact_get_by_id(contact* buffer, char* id); int contact_get_autocompletions(contact* buffer, int buf_size, char* name); - u32 contact_get_partial_list(u32 page_index, u32 page_size, contact* buffer); + u32 contact_get_partial_list(u32 page_index, u32 page_size, contact* buffer, contact_filter* filter = 0); u32 contact_get_all(contact* buffer); // Project functions. -- cgit v1.2.3-70-g09d2