From 3738d071f86aa5016ce326a009a278085b41fb48 Mon Sep 17 00:00:00 2001 From: msquare Date: Fri, 30 Sep 2016 17:08:20 +0200 Subject: remove long array syntax --- includes/view/AngelTypes_view.php | 8 ++++---- includes/view/User_view.php | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) (limited to 'includes/view') diff --git a/includes/view/AngelTypes_view.php b/includes/view/AngelTypes_view.php index 65abe0f3..7e8663a1 100644 --- a/includes/view/AngelTypes_view.php +++ b/includes/view/AngelTypes_view.php @@ -38,17 +38,17 @@ function AngelType_render_membership($user_angeltype) { } function AngelType_delete_view($angeltype) { - return page_with_title(sprintf(_("Delete angeltype %s"), $angeltype['name']), array( + return page_with_title(sprintf(_("Delete angeltype %s"), $angeltype['name']), [ info(sprintf(_("Do you want to delete angeltype %s?"), $angeltype['name']), true), buttons([ button(page_link_to('angeltypes'), _("cancel"), 'cancel'), button(page_link_to('angeltypes') . '&action=delete&angeltype_id=' . $angeltype['id'] . '&confirmed', _("delete"), 'ok') ]) - )); + ]); } function AngelType_edit_view($name, $restricted, $description, $coordinator_mode, $requires_driver_license) { - return page_with_title(sprintf(_("Edit %s"), $name), array( + return page_with_title(sprintf(_("Edit %s"), $name), [ buttons([ button(page_link_to('angeltypes'), _("Angeltypes"), 'back') ]), @@ -62,7 +62,7 @@ function AngelType_edit_view($name, $restricted, $description, $coordinator_mode form_info("", _("Please use markdown for the description.")), form_submit('submit', _("Save")) ]) - )); + ]); } function AngelType_view($angeltype, $members, $user_angeltype, $admin_user_angeltypes, $admin_angeltypes, $coordinator, $user_driver_license, $user) { diff --git a/includes/view/User_view.php b/includes/view/User_view.php index 5c258fc7..3e365ea2 100644 --- a/includes/view/User_view.php +++ b/includes/view/User_view.php @@ -97,11 +97,11 @@ function Users_view($users, $order_by, $arrived_count, $active_count, $force_act $user['force_active'] = glyph_bool($user['force_active']); $user['Tshirt'] = glyph_bool($user['Tshirt']); $user['lastLogIn'] = date(_('m/d/Y h:i a'), $user['lastLogIn']); - $user['actions'] = table_buttons(array( + $user['actions'] = table_buttons([ button_glyph(page_link_to('admin_user') . '&id=' . $user['UID'], 'edit', 'btn-xs') - )); + ]); } - $users[] = array( + $users[] = [ 'Nick' => '' . _('Sum') . '', 'Gekommen' => $arrived_count, 'got_voucher' => $voucher_count, @@ -110,7 +110,7 @@ function Users_view($users, $order_by, $arrived_count, $active_count, $force_act 'freeloads' => $freeloads_count, 'Tshirt' => $tshirts_count, 'actions' => '' . count($users) . '' - ); + ]; return page_with_title(_('All users'), [ msg(), -- cgit v1.2.3-70-g09d2