diff options
author | Philip Häusler <msquare@notrademark.de> | 2013-12-27 18:45:27 +0100 |
---|---|---|
committer | Philip Häusler <msquare@notrademark.de> | 2013-12-27 18:45:27 +0100 |
commit | c589219a962203ddb2a8b3899f964ca5ae5209ef (patch) | |
tree | ee8c01d5a839c4bd15365868851562e5d35e897c /includes/view | |
parent | 2c41fcdc0902279fd5c651a7ba08dbe7ba02d94b (diff) |
freeloader feature
Diffstat (limited to 'includes/view')
-rw-r--r-- | includes/view/ShiftEntry_view.php | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/includes/view/ShiftEntry_view.php b/includes/view/ShiftEntry_view.php index 1080c4bc..b815ba73 100644 --- a/includes/view/ShiftEntry_view.php +++ b/includes/view/ShiftEntry_view.php @@ -11,7 +11,15 @@ * * @return string */ -function ShiftEntry_edit_view($angel, $date, $location, $title, $type, $comment) { +function ShiftEntry_edit_view($angel, $date, $location, $title, $type, $comment, $freeloaded, $freeload_comment, $user_admin_shifts = false) { + if ($user_admin_shifts) { + $freeload_form = array( + form_checkbox('freeloaded', _("Freeloaded"), $freeloaded), + form_textarea('freeload_comment', _("Freeload comment (Only for shift coordination):"), $freeload_comment) + ); + } else { + $freeload_form = $freeloaded ? "" : ""; + } return page(array( form(array( form_info(_("Angel:"), $angel), @@ -20,6 +28,7 @@ function ShiftEntry_edit_view($angel, $date, $location, $title, $type, $comment) form_info(_("Title:"), $title), form_info(_("Type:"), $type), form_textarea('comment', _("Comment (for your eyes only):"), $comment), + join("", $freeload_form), form_submit('submit', _("Save")) )) )); |