schedule: add support for full schedule
This commit is contained in:
parent
18ac2789f7
commit
76b46316f9
|
@ -7,7 +7,12 @@ require("schedule-config.php");
|
|||
|
||||
?>
|
||||
<section class="content grid">
|
||||
<div class="col-left">
|
||||
<?php
|
||||
// full schedule is not limited in only one column
|
||||
if (!preg_match('/^full/', $pagename)) {
|
||||
echo '<div class="col-left">';
|
||||
}
|
||||
?>
|
||||
<h1><?php pll_e('Програма') ?></h1>
|
||||
|
||||
<?php
|
||||
|
@ -34,9 +39,11 @@ if (!empty($content)) {
|
|||
}
|
||||
|
||||
?>
|
||||
</div>
|
||||
<?php
|
||||
if (!preg_match('/^full/', $pagename)) {
|
||||
echo "</div>";
|
||||
get_sidebar();
|
||||
};
|
||||
?>
|
||||
</section>
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@ $data = loadData($sched_config);
|
|||
|
||||
if ( preg_match('/^workshop/', $pagename) ) {
|
||||
$sched_config['filterEventType'] = "workshop";
|
||||
} else {
|
||||
} else if (!preg_match('/^full/', $pagename)) {
|
||||
$sched_config['filterEventType'] = "lecture";
|
||||
}
|
||||
$content = parseData($sched_config, $data);
|
||||
|
|
|
@ -42,7 +42,7 @@ function parseData($config, $data) {
|
|||
|
||||
$eid = $slot['event_id'];
|
||||
$etype = $data['events'][$eid]['event_type_id'];
|
||||
if ($etype !== $filtered_type_id) {
|
||||
if ($etype !== $filtered_type_id && !is_null($filtered_type_id)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue