From 60af9af46e4c80db1bd41d77991e2cf24ed69641 Mon Sep 17 00:00:00 2001 From: Harald Eilertsen Date: Fri, 3 Sep 2021 15:04:58 +0200 Subject: Rename AdminPage::get_user -> user_dropdown_for_role The original name did not make much sense. The function didn't return a user, but a dropdown list of users, where the user currently holding the given role for the given concert was preselected in the list. --- includes/admin/views/giglog_admin_page.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'includes/admin') diff --git a/includes/admin/views/giglog_admin_page.php b/includes/admin/views/giglog_admin_page.php index 0db72b2..248f175 100644 --- a/includes/admin/views/giglog_admin_page.php +++ b/includes/admin/views/giglog_admin_page.php @@ -68,7 +68,7 @@ if ( !class_exists( 'GiglogAdmin_AdminPage' ) ) { } - private function get_user( GiglogAdmin_Concert $concert, string $role): string + private function user_dropdown_for_role( GiglogAdmin_Concert $concert, string $role): string { $users = array_map( fn($usr) => $usr->user_login, @@ -147,10 +147,10 @@ if ( !class_exists( 'GiglogAdmin_AdminPage' ) ) { $content.=''; $content.='
ASSIGNMENT DETAILS

' - .''.$this->get_user($c,'photo1').'
' - .''.$this->get_user($c,'photo2').'
' - .''.$this->get_user($c,'rev1').'
' - .''.$this->get_user($c,'rev2').'
'; + .''.$this->user_dropdown_for_role($c,'photo1').'
' + .''.$this->user_dropdown_for_role($c,'photo2').'
' + .''.$this->user_dropdown_for_role($c,'rev1').'
' + .''.$this->user_dropdown_for_role($c,'rev2').'
'; $content.='
'; $content.='
VENUE DETAILS

' -- cgit v1.2.3