From 72a0df55f1a5858ac088cfce34183c740c544663 Mon Sep 17 00:00:00 2001 From: Harald Eilertsen Date: Tue, 25 May 2021 21:15:09 +0200 Subject: Use select_field in AdminPage::get_user --- includes/admin/views/giglog_admin_page.php | 19 ++++--------------- 1 file changed, 4 insertions(+), 15 deletions(-) (limited to 'includes/admin') diff --git a/includes/admin/views/giglog_admin_page.php b/includes/admin/views/giglog_admin_page.php index 4f211fc..bb42aa7 100644 --- a/includes/admin/views/giglog_admin_page.php +++ b/includes/admin/views/giglog_admin_page.php @@ -55,21 +55,10 @@ if ( !class_exists( 'GiglogAdmin_AdminPage' ) ) { $current_user = $cid ? GiglogAdmin_Concertlogs::get_assigned_user( $cid, $ctype ) : null; - $select = ''; - return($select); + return \EternalTerror\ViewHelpers\select_field( + $ctype, + array_map( fn($user) => [ $user, $user ], $users ), + $current_user); } -- cgit v1.2.3