From 4931fbb3720ca050eb7719a9b09471e950b0f334 Mon Sep 17 00:00:00 2001 From: Philip Häusler Date: Sun, 28 Sep 2014 19:44:53 +0200 Subject: replace icons with glyphicons --- includes/view/User_view.php | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'includes/view') diff --git a/includes/view/User_view.php b/includes/view/User_view.php index 912579e7..0bea946c 100644 --- a/includes/view/User_view.php +++ b/includes/view/User_view.php @@ -131,11 +131,12 @@ function User_view($user_source, $admin_user_privilege, $freeloader, $user_angel $myshift['comment'] .= '

' . _("Freeloaded") . '

'; } - $myshift['actions'] = ""; + $myshift['actions'] = array(); if ($its_me || in_array('user_shifts_admin', $privileges)) - $myshift['actions'] .= img_button(page_link_to('user_myshifts') . '&edit=' . $shift['id'] . '&id=' . $user_source['UID'], 'pencil', _("edit")); + $myshift['actions'][] = button(page_link_to('user_myshifts') . '&edit=' . $shift['id'] . '&id=' . $user_source['UID'], glyph('edit') . _('edit'), 'btn-xs'); if (($shift['start'] > time() + $LETZTES_AUSTRAGEN * 3600) || in_array('user_shifts_admin', $privileges)) - $myshift['actions'] .= img_button(page_link_to('user_myshifts') . ((! $its_me) ? '&id=' . $user_source['UID'] : '') . '&cancel=' . $shift['id'], 'cross', _("sign off")); + $myshift['actions'][] = button(page_link_to('user_myshifts') . ((! $its_me) ? '&id=' . $user_source['UID'] : '') . '&cancel=' . $shift['id'], glyph('trash') . _('sign off'), 'btn-xs'); + $myshift['actions'] = table_buttons($myshift['actions']); if ($shift['freeloaded']) $timesum += - 2 * ($shift['end'] - $shift['start']); @@ -182,8 +183,9 @@ function User_view($user_source, $admin_user_privilege, $freeloader, $user_angel buttons(array( $admin_user_privilege ? button(page_link_to('admin_user') . '&id=' . $user_source['UID'], ' ' . _("edit")) : '', ! $user_source['Gekommen'] ? button(page_link_to('admin_arrive') . '&arrived=' . $user_source['UID'], _("arrived")) : '', - $its_me ? button(page_link_to_absolute('ical') . '&key=' . $user_source['api_key'], ' ' . _("iCal Export")) : '', - $its_me ? button(page_link_to_absolute('shifts_json_export') . '&key=' . $user_source['api_key'], ' ' . _("JSON Export")) : '' + $its_me ? button(page_link_to_absolute('ical') . '&key=' . $user_source['api_key'], glyph('calendar') . _("iCal Export")) : '', + $its_me ? button(page_link_to_absolute('shifts_json_export') . '&key=' . $user_source['api_key'], glyph('export') . _("JSON Export")) : '', + $its_me ? button(page_link_to_absolute('user_myshifts') . '&reset', glyph('repeat') . _('Reset API key')) : '' )), ($its_me || $admin_user_privilege) ? '

' . _("Shifts") . '

' : '', ($its_me || $admin_user_privilege) ? table(array( -- cgit v1.2.3-70-g09d2