aboutsummaryrefslogtreecommitdiff
path: root/template
diff options
context:
space:
mode:
authorMaZderMind2014-11-03 21:53:30 +0100
committerMaZderMind2014-11-07 00:17:40 +0100
commitdb0a85ea97096af4529b0ea3b903d182144c1310 (patch)
tree7dc8cebc458175627c7dd809ec67d6c2288cc221 /template
parent82a054e876424cf055793ae653fbb40b6d5e58ec (diff)
experimental program view
Diffstat (limited to 'template')
-rw-r--r--template/assemblies/program.phtml38
-rw-r--r--template/room.phtml8
2 files changed, 42 insertions, 4 deletions
diff --git a/template/assemblies/program.phtml b/template/assemblies/program.phtml
new file mode 100644
index 0000000..9575d8c
--- /dev/null
+++ b/template/assemblies/program.phtml
@@ -0,0 +1,38 @@
+<?
+$room = 'Grossbaustelle BER';
+
+foreach($program[$room] as $event)
+{
+ $width += intval(isset($event['duration']) ? $event['duration'] : 5);
+}
+?>
+
+<div class="program">
+ <div class="now">now</div>
+ <div class="inner" style="width: <?=$width * $GLOBALS['CONFIG']['SCHEDULE_SCALE'] ?>px">
+ <? foreach($program[$room] as $event): ?>
+ <? if(@$event['special'] == 'daychange'): ?>
+
+ <div class="block daychange" style="width: <?=h($GLOBALS['CONFIG']['SCHEDULE_SCALE'])?>px"></div>
+
+ <? elseif(@$event['special'] == 'gap'): ?>
+
+ <div class="block daychange" style="width: <?=h($event['duration'] * $GLOBALS['CONFIG']['SCHEDULE_SCALE'])?>px"></div>
+
+ <? elseif(@$event['special']): ?>
+
+ <div class="block <?=h($event['special'])?>" style="width: <?=h($event['duration'] * $GLOBALS['CONFIG']['SCHEDULE_SCALE'])?>px">
+ <h3><?=h($event['title'])?></h3>
+ </div>
+
+ <? else: ?>
+
+ <div class="block event" style="width: <?=h($event['duration'] * $GLOBALS['CONFIG']['SCHEDULE_SCALE'])?>px">
+ <h3><?=h($event['title'])?></h3>
+ </div>
+
+ <? endif ?>
+
+ <? endforeach ?>
+ </div>
+</div>
diff --git a/template/room.phtml b/template/room.phtml
index 87f2b9f..6c26730 100644
--- a/template/room.phtml
+++ b/template/room.phtml
@@ -30,14 +30,14 @@
</ul>
<div class="tab-content">
- <div class="tab-pane active switcher" id="switcher">
+ <div class="tab-pane active" id="switcher">
<? include("assemblies/switcher/$type.phtml") ?>
</div>
- <div class="tab-pane irc" id="irc">
+ <div class="tab-pane" id="irc">
<? include("assemblies/irc.phtml") ?>
</div>
- <div class="tab-pane program" id="program">
- Program
+ <div class="tab-pane" id="program">
+ <? include("assemblies/program.phtml") ?>
</div>
</div>
</div>