1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
|
<?php
$this->breadcrumbs=array(
'Veranstaltungen',
);
$this->pageTitle = 'Programmpunkte auf der Bühne '.$model->name.' - ' . Yii::app()->name;
$this->menu=array(
array('label'=>'Jetzt auf dem Fest', 'url'=>array('now')),
//array('label'=>'Zellerplatz', 'url'=>array('stage','id'=>45)),
//array('label'=>'Veranstaltung suchen', 'url'=>array('search')),
);
$buehnen = new CActiveDataProvider('Standort', array(
'criteria'=>array(
'condition'=>"type='Bühne'",
'with'=>'vereine'
),
));
$mymenu = array();
foreach ($buehnen->getData() as $buehne) {
$hasVerein = false;
foreach ($buehne->vereine as $verein) {
if ($verein->published) { $hasVerein=true;}
}
$mymenu = array_merge( $mymenu , array(array('label' => 'Bühnenprogramm '.$buehne->name, 'url'=>array('stage','id'=>$buehne->id))));
}
$this->menu = array_merge($this->menu, $mymenu);
?>
<h3>Bühnenprogramm <?php echo $model->name?> </h3>
<h5>Freitag</h5>
<?php
$veranstaltung = new Veranstaltung();
$veranstaltung->published()->thisYear()->freitag()->parentStage($model->id)->sorted();
$this->widget('zii.widgets.grid.CGridView', array(
'dataProvider'=>$veranstaltung->search(),
'columns'=>array(
array( // display 'create_time' using an expression
'name'=>'Startzeit',
'value'=>'Format::displayDateForLists($data)',
'htmlOptions' => array('style'=>"width:20%;"),
'type' => 'html',
),
array(
'name'=> 'Titel',
'type' => 'Raw',
'value' => 'CHTML::link($data->titel,array("veranstaltung/view","id"=>$data->id))',
),
),
'blankDisplay' => "Heute keine Termine bekannt",
'enableSorting' => false,
'enablePagination' => false,
'hideHeader' => true,
'template' => '{items}',
'htmlOptions' => array('class'=>''),
));
?>
<h5>Samstag</h5>
<?php
$veranstaltung = new Veranstaltung();
$this->widget('zii.widgets.grid.CGridView', array(
'dataProvider'=>$veranstaltung->published()->thisYear()->samstag()->parentStage($model->id)->sorted()->search(),
'columns'=>array(
array( // display 'create_time' using an expression
'name'=>'Startzeit',
'value'=>'Format::displayDateForLists($data)',
'htmlOptions' => array('style'=>"width:20%;"),
'type' => 'html',
),
array(
'name'=> 'Titel',
'type' => 'Raw',
'value' => 'CHTML::link($data->titel,array("veranstaltung/view","id"=>$data->id))',
),
),
'blankDisplay' => "Heute keine Termine bekannt",
'enableSorting' => false,
'enablePagination' => false,
'hideHeader' => true,
'template' => '{items}',
'htmlOptions' => array('class'=>''),
));?>
<h5>Sonntag</h5>
<?php
$veranstaltung = new Veranstaltung();
$this->widget('zii.widgets.grid.CGridView', array(
'dataProvider'=>$veranstaltung->published()->thisYear()->sonntag()->parentStage($model->id)->sorted()->search(),
'columns'=>array(
array( // display 'create_time' using an expression
'name'=>'Startzeit',
'value'=>'Format::displayDateForLists($data)',
'htmlOptions' => array('style'=>"width:20%;"),
'type' => 'html',
),
array(
'name'=> 'Titel',
'type' => 'Raw',
'value' => 'CHTML::link($data->titel,array("veranstaltung/view","id"=>$data->id))',
),
),
'blankDisplay' => "Heute keine Termine bekannt",
'enableSorting' => false,
'enablePagination' => false,
'hideHeader' => true,
'template' => '{items}',
'htmlOptions' => array('class'=>''),
));?>
|