summaryrefslogtreecommitdiff
path: root/includes/pages/user_ical.php
diff options
context:
space:
mode:
authorPhilip Häusler <msquare@notrademark.de>2014-12-25 22:32:18 +0100
committerPhilip Häusler <msquare@notrademark.de>2014-12-25 22:32:18 +0100
commite89acc0c1d1188662da7490e3a75a4a5c3950a75 (patch)
treef646260cc23195008f6ca5152426b17641fc4f69 /includes/pages/user_ical.php
parentbcd33c02c814a8d82c08c078c8fae287d1cd95a5 (diff)
parent544a51612f14c4f3cf7d1c4a6de26a99ea94b788 (diff)
merge feature-shift-types
Diffstat (limited to 'includes/pages/user_ical.php')
-rw-r--r--includes/pages/user_ical.php9
1 files changed, 8 insertions, 1 deletions
diff --git a/includes/pages/user_ical.php b/includes/pages/user_ical.php
index 911f48aa..ba832842 100644
--- a/includes/pages/user_ical.php
+++ b/includes/pages/user_ical.php
@@ -22,7 +22,14 @@ function user_ical() {
require_once realpath(__DIR__ . '/user_shifts.php');
view_user_shifts();
} else {
- $ical_shifts = sql_select("SELECT `Shifts`.*, `Room`.`Name` as `room_name` FROM `ShiftEntry` INNER JOIN `Shifts` ON (`ShiftEntry`.`SID` = `Shifts`.`SID`) INNER JOIN `Room` ON (`Shifts`.`RID` = `Room`.`RID`) WHERE `UID`=" . sql_escape($user['UID']) . " ORDER BY `start`");
+ $ical_shifts = sql_select("
+ SELECT `ShiftTypes`.`name`, `Shifts`.*, `Room`.`Name` as `room_name`
+ FROM `ShiftEntry`
+ INNER JOIN `Shifts` ON (`ShiftEntry`.`SID` = `Shifts`.`SID`)
+ JOIN `ShiftTypes` ON (`ShiftTypes`.`id` = `Shifts`.`shifttype_id`)
+ INNER JOIN `Room` ON (`Shifts`.`RID` = `Room`.`RID`)
+ WHERE `UID`=" . sql_escape($user['UID']) . "
+ ORDER BY `start`");
}
header("Content-Type: text/calendar; charset=utf-8");