public function testItems() { $items = Lookup::items('CrashReportStatus'); $this->assertTrue($items[1] == 'Waiting'); Lookup::reset(); $items = Lookup::items('BugStatus', Bug::STATUS_OPEN_MAX); $this->assertTrue($items[1] == 'New'); $this->assertTrue(count($items) == 4); }
<?php $this->breadcrumbs = array('艺术家' => array('index'), '管理'); $this->menu = array(array('label' => '列出艺术家', 'url' => array('index')), array('label' => '增加艺术家', 'url' => array('create'))); Yii::app()->clientScript->registerScript('search', "\n\$('.search-button').click(function(){\n\t\$('.search-form').toggle();\n\treturn false;\n});\n\$('.search-form form').submit(function(){\n\t\$.fn.yiiGridView.update('artist-grid', {\n\t\tdata: \$(this).serialize()\n\t});\n\treturn false;\n});\n"); ?> <h1>管理艺术家</h1> <p> 你可以在每个搜索值之前输入一个对比符 (<b><</b>, <b><=</b>, <b>></b>, <b>>=</b>, <b><></b> 或 <b>=</b>) ,以指定对比如何完成。 </p> <?php echo CHtml::link('高级搜索', '#', array('class' => 'search-button')); ?> <div class="search-form" style="display:none"> <?php $this->renderPartial('_search', array('model' => $model)); ?> </div><!-- search-form --> <?php $this->widget('zii.widgets.grid.CGridView', array('id' => 'artist-grid', 'dataProvider' => $model->search(), 'filter' => $model, 'summaryText' => '这是 {start} 到 {end} 共 {count} 条记录', 'columns' => array(array('name' => 'type_id', 'value' => 'ArtistType::item($data->type_id)', 'filter' => ArtistType::items()), array('name' => 'area_id', 'value' => 'ArtistArea::item($data->area_id)', 'filter' => ArtistArea::items()), array('name' => 'name', 'type' => 'raw', 'value' => 'CHtml::link(CHtml::encode($data->name), $data->url)'), array('name' => 'proved', 'value' => 'Lookup::item("PROVED",$data->proved)', 'filter' => Lookup::items('PROVED')), array('name' => 'add_time', 'type' => 'datetime', 'filter' => false), array('class' => 'CButtonColumn'))));
echo $item->name; echo CHtml::closeTag("strong"); echo " - " . $item->description; echo CHtml::closeTag("li"); } echo CHtml::closeTag("ul"); ?> </div> <h2><?php echo $header2; ?> </h2> <?php $foodtypes = Lookup::items('DietType'); if ($model2) { echo CHtml::openTag("div", array('class' => 'foodmenu')); echo CHtml::openTag("ul"); foreach ($model2 as $item2) { echo CHtml::openTag("li"); echo CHtml::openTag("strong"); echo $item2->name; echo CHtml::closeTag("strong"); echo " - " . $item2->description; //echo " - ". $foodtypes[item2->foodtype]; echo CHtml::closeTag("li"); } echo CHtml::closeTag("ul"); echo CHtml::closeTag("div"); }
'value' => 'CHtml::link(CHtml::encode($data->username),Users::url("admin/view",array("id"=>$data->id)))', ), array( 'name'=>'email', 'type'=>'raw', 'value'=>'CHtml::link(CHtml::encode($data->email), "mailto:".$data->email)', ), array( 'name'=>'status', 'value'=>'User::itemAlias("UserStatus",$data->status)', 'filter'=>User::aliases('UserStatus'), ), array( 'name'=>'role', 'type'=>'raw', 'value'=>'Lookup::item("role",$data->role)', 'filter'=>Lookup::items('role'), ), array( 'name' => 'createtime', 'value' => 'date("d.m.Y H:i:s",$data->createtime)', ), array( 'name' => 'lastvisit', 'value' => '($data->lastvisit?date("d.m.Y H:i:s",$data->lastvisit):Users::t("Not visited"))', ), array( 'class'=>'CButtonColumn', ), ), )); ?>
?> <?php $items = Lookup::items('BugPriority'); echo $form->dropDownList($model, 'priority', $items); ?> <?php echo $form->error($model, 'priority'); ?> </div> <div class="row"> <?php echo $form->labelEx($model, 'reproducability'); ?> <?php $items = Lookup::items('BugReproducability'); echo $form->dropDownList($model, 'reproducability', $items); ?> <?php echo $form->error($model, 'reproducability'); ?> </div> <div class="row"> <?php echo $form->labelEx($model, 'assigned_to'); ?> <?php $curProject = Yii::app()->user->getCurProject(); $projectUsers = $curProject->users; $items = array();
<?php Y::beginTab('Настройки')?> <?php Admin::makeTextFields($form, $model, array('title', 'second_title', 'alias'))?> <div class="row"> <div class="left"><?php echo $form->labelEx($model,'published')?></div> <div class="right"> <?php if ($model->isNewRecord) $model->published = Record::PUBLISHED?> <?php echo $form->radioButtonList($model,'published',Lookup::items('FPublished'));?> </div> </div> <?php Admin::makeDateFields($form, $model, 'created', 'dd.mm.yy'); ?> <?php Y::endTab()?> <?php Admin::makeTinyTabs($form, $model, array('text', 'descr'))?>
<td> <?php echo CHtml::activeTextField($model, "[{$index}]firstname"); ?> <?php echo CHtml::error($model, "[{$index}]firstname"); ?> </td> <td> <?php $this->widget('ext.widgets.autocomplete.XJuiAutoComplete', array('model' => $model, 'attribute' => "[{$index}]lastname", 'source' => $this->createUrl('request/suggestLastname'))); ?> <?php echo CHtml::error($model, "[{$index}]lastname"); ?> </td> <td> <?php echo CHtml::activeDropDownList($model, "[{$index}]eyecolor_code", Lookup::items('eyecolor')); ?> <?php echo CHtml::error($model, "[{$index}]eyecolor_code"); ?> </td>
echo Inflector::camel2id(StringHelper::basename($generator->modelClass)); ?> -form"> <?php echo "<?php "; ?> $form = ActiveForm::begin(); ?> <?php foreach ($generator->getColumnNames() as $attribute) { if (in_array($attribute, $safeAttributes)) { echo "\t<?= " . $generator->generateActiveField($attribute) . " ?>\n"; } } ?> <?php echo $form->field($model, 'type')->dropDownList(Lookup::items('SourceType')); ?> <?php echo "<?php\n "; ?> //$form->field($model, 'type')->dropDownList(Lookup::items('SourceType')) <?php echo "\n?>"; ?> <div class="form-group"> <?php echo "<?= "; ?> BaseHtml::submitButton($model->isNewRecord ? <?php
foreach ($persons as $i => $person) { ?> <tr class="templateContent"> <td> <?php echo $form->textField($person, "[{$i}]firstname", array('style' => 'width:100px')); ?> </td> <td> <?php echo $form->textField($person, "[{$i}]lastname", array('style' => 'width:100px')); ?> </td> <td> <?php echo $form->dropDownList($person, "[{$i}]eyecolor_code", Lookup::items('eyecolor'), array('style' => 'width:100px', 'prompt' => '')); ?> </td> <td> <input type="hidden" class="rowIndex" value="<?php echo $i; ?> " /> <div class="remove"><?php echo Yii::t('ui', 'Remove'); ?> </td> </tr> <?php } ?>
$this->breadcrumbs = array(Yii::t('ui', 'Persons')); ?> <h2><?php echo Yii::t('ui', 'Manage Persons'); ?> </h2> <div class="actionBar"> <?php echo CHtml::link(Yii::t('ui', 'New'), array('create')); ?> </div> <!-- actionBar --> <?php $this->widget('zii.widgets.grid.CGridView', array('id' => 'person-grid', 'dataProvider' => $model->search(), 'filter' => $model, 'htmlOptions' => array('style' => 'width:740px'), 'pager' => array('header' => '', 'firstPageLabel' => '<<', 'prevPageLabel' => '<', 'nextPageLabel' => '>', 'lastPageLabel' => '>>'), 'columns' => array(array('name' => 'lastname', 'type' => 'raw', 'value' => 'CHtml::link($data->lastname, $this->grid->controller->createReturnableUrl("view",array("id"=>$data->id)))'), 'firstname', 'birthyear', array('name' => 'country_id', 'value' => '$data->country->name', 'filter' => Country::model()->options), array('name' => 'eyecolor_code', 'value' => 'Lookup::item("eyecolor",$data->eyecolor_code)', 'filter' => Lookup::items('eyecolor')), array('class' => 'CLinkColumn', 'header' => Yii::t('ui', 'Email'), 'imageUrl' => XHtml::imageUrl('email.png'), 'labelExpression' => '$data->email', 'urlExpression' => '"mailto://".$data->email', 'htmlOptions' => array('style' => 'text-align:center')), array('class' => 'CButtonColumn', 'viewButtonUrl' => '$this->grid->controller->createReturnableUrl("view",array("id"=>$data->id))', 'updateButtonUrl' => '$this->grid->controller->createReturnableUrl("update",array("id"=>$data->id))', 'deleteButtonUrl' => '$this->grid->controller->createReturnableUrl("delete",array("id"=>$data->id))', 'deleteConfirmation' => Yii::t('ui', 'Are you sure to delete this item?'))))); ?> <br /> <div class="tpanel"> <div class="toggle"><?php echo Yii::t('ui', 'View code'); ?> </div> <?php $this->beginWidget('CTextHighlighter', array('language' => 'PHP')); ?> $this->widget('zii.widgets.grid.CGridView', array( 'id'=>'person-grid', 'dataProvider'=>$model->search(),
<?php echo $form->error($model, 'tags'); ?> </div> <div class="margin-left-15"> <p>Khu vực</p> <?php echo $form->dropDownList($model, 'status', CHtml::listData(Place::model()->findAll(), 'id', 'name'), array('class' => 'btn btn-default')); ?> <?php echo $form->error($model, 'status'); ?> </div> <div class="margin-left-15"> <?php echo CHtml::submitButton($model->isNewRecord ? 'Tạo bài đăng' : 'Lưu', array('class' => 'btn btn-default')); ?> </div> <?php $this->endWidget(); ?> </div><!-- form --> <!--<?php echo $form->dropDownList($model, 'status', Lookup::items('PostStatus'), array('class' => 'form-control btn btn-default trangthai')); ?> -->
<?php $form->endDynamicAreaDDL(); ?> <?php $form->beginDynamicAreaDDL($model2, 'selectOption', Person::SELECT_EYECOLOR); ?> <div class="complex"> <span class="label"> <?php echo Yii::t('ui', 'Eyecolor'); ?> </span> <div class="panel"> <?php echo $form->radioButtonList($model2, 'eyecolor_code', Lookup::items('eyecolor')); ?> <?php echo $form->error($model2, 'eyecolor_code'); ?> </div> </div> <?php $form->endDynamicAreaDDL(); ?> <?php $this->endWidget(); ?>
<div class="row"> <div class="left"> <?php echo $form->labelEx($model,'email'); ?> </div> <div class="right"> <?php echo $form->textField($model,'email',array('size'=>60,'maxlength'=>128)); ?> <?php echo $form->error($model,'email'); ?> </div> </div> <div class="row"> <div class="left"> <?php echo $form->labelEx($model,'role'); ?> </div> <div class="right"> <?php echo $form->dropDownList($model,'role',Lookup::items('role')); ?> <?php echo $form->error($model,'role'); ?> </div> </div> <div class="row"> <div class="left"> <?php echo $form->labelEx($model,'status'); ?> </div> <div class="right"> <?php echo $form->dropDownList($model,'status',User::itemAlias('UserStatus')); ?> <?php echo $form->error($model,'status'); ?> </div> </div> <?php echo $this->renderPartial('/profile/_form', array('profile'=>$profile, 'form'=>$form))?>
<?php echo CHtml::activeDropDownList($model, 'eyecolor_code', Lookup::items('eyecolor')); ?> <?php $this->beginWidget('CTextHighlighter', array('language' => 'PHP')); ?> echo CHtml::activeDropDownList($model,'eyecolor_code', Lookup::add()+Lookup::items('eyecolor'),array('prompt'=>'')); <?php $this->endWidget(); ?> <?php echo CHtml::activeDropDownList($model, 'eyecolor_code', Lookup::add() + Lookup::items('eyecolor'), array('prompt' => '')); ?> <h3 style="margin-top:30px"><?php echo Yii::t('ui', 'Gridview with classificators'); ?> </h3> <?php $this->beginWidget('CTextHighlighter', array('language' => 'PHP')); ?> $this->widget('zii.widgets.grid.CGridView', array( 'dataProvider'=>$model->search(), 'columns'=>array( 'firstname', 'lastname',
echo $form->labelEx($model, 'country_id'); ?> <?php echo $form->DropDownList($model, 'country_id', Country::model()->options, array('prompt' => '')); ?> <?php echo $form->error($model, 'country_id'); ?> </div> <div class="simple"> <?php echo $form->labelEx($model, 'eyecolor_code'); ?> <?php echo $form->dropDownList($model, 'eyecolor_code', Lookup::items('eyecolor'), array('prompt' => '')); ?> <?php echo $form->error($model, 'eyecolor_code'); ?> </div> </div><!-- cpanelContent --> </div><!-- cpanel --> <div class="action"> <?php //echo CHtml::submitButton($model->isNewRecord ? Yii::t('ui', 'Create') : Yii::t('ui','Save')); ?> </div>
<?php $this->breadcrumbs = array('专辑' => array('index'), '管理'); $this->menu = array(array('label' => '列出专辑', 'url' => array('index')), array('label' => '创建专辑', 'url' => array('create'))); Yii::app()->clientScript->registerScript('search', "\n\$('.search-button').click(function(){\n\t\$('.search-form').toggle();\n\treturn false;\n});\n\$('.search-form form').submit(function(){\n\t\$.fn.yiiGridView.update('album-grid', {\n\t\tdata: \$(this).serialize()\n\t});\n\treturn false;\n});\n"); ?> <h1>管理专辑</h1> <p> 你可以在搜索值之前使用对比符 (<b><</b>, <b><=</b>, <b>></b>, <b>>=</b>, <b><></b> or <b>=</b>) 以指定如何完成对比。 </p> <?php echo CHtml::link('高级搜索', '#', array('class' => 'search-button')); ?> <div class="search-form" style="display:none"> <?php $this->renderPartial('_search', array('model' => $model)); ?> </div><!-- search-form --> <?php $this->widget('zii.widgets.grid.CGridView', array('id' => 'album-grid', 'dataProvider' => $model->search(), 'filter' => $model, 'summaryText' => '这是 {start} 到 {end} 共 {count} 条记录', 'columns' => array('name', array('name' => 'proved', 'value' => 'Lookup::item("PROVED",$data->proved)', 'filter' => Lookup::items('PROVED')), array('name' => 'add_time', 'type' => 'datetime', 'filter' => false), array('class' => 'CButtonColumn'))));
)); $form->errorSummary($model); Y::beginTab('Настройки'); Admin::makeTextFields($form, $model, array('title', 'alias')) ?> <div class="row"> <div class="left"><?php echo $form->labelEx($model,'published') ?></div> <div class="right"> <?php echo $form->radioButtonList($model,'published',Lookup::items('MPublished')) ?> </div> </div> <div class="row"> <div class="left"<?php echo $form->labelEx($model,'is_empty') ?></div> <div class="right"> <?php echo $form->radioButtonList($model,'is_empty',Lookup::items('YesNo')) ?> </div> </div> <?php if ($model->isNewRecord) { ?> <div class="row"> <div class="left"><?php echo $form->labelEx($model,'type') ?></div> <div class="right"> <?php echo $form->dropDownList($model,'type',ModelFactory::getTypes()) ?> </div> </div> <?php } ?> <?php Y::endTab(); Y::beginTab('Метаданные'); Admin::makeTextFields($form, $model, array('meta_title', 'meta_descr', 'meta_keywords')); Y::endTab();
echo $form->labelEx($model, 'course'); ?> <?php echo $form->dropDownList($model, 'course', Lookup::items('CourseType')); ?> <?php echo $form->error($model, 'course'); ?> </div> <div class="row"> <?php echo $form->labelEx($model, 'foodtype'); ?> <?php echo $form->dropDownList($model, 'foodtype', Lookup::items('DietType')); ?> <?php echo $form->error($model, 'foodtype'); ?> </div> <div class="row"> <?php echo $form->labelEx($model, 'tags'); ?> <?php $this->widget('CAutoComplete', array('model' => $model, 'attribute' => 'tags', 'url' => array('suggestTags'), 'multiple' => true, 'htmlOptions' => array('size' => 50))); ?> <p class="hint">Please separate different tags with commas.</p> <?php echo $form->error($model, 'tags');
$this->beginWidget('zii.widgets.jui.CJuiDialog', array( 'id'=>'delete-category', 'htmlOptions'=>array( 'title'=>'Удаление категории', ), 'options'=>array( 'autoOpen'=>false, 'modal'=>true, 'width'=>350, 'height'=>270, ), )); echo CHtml::tag('b',array(), "Что сделать со связанными с категорией данными?"); echo CHtml::dropDownList('deleteCategoryVariant','1',Lookup::items('deleteCategoryVariant')); echo CHtml::hiddenField('category_id'); $js_delete =<<< EOD var variant = $(this).parent().children('#deleteCategoryVariant').val(); var catId = $(this).parent().find('input[name="category_id"]').val(); $("#delete-category").dialog("close"); if(variant == 1) { $("#choise-category").dialog("open"); $("#relevant-cats").load('/admin/categories/getRelevantCategories',{catId:catId, action:'cut'}); } else window.location = '/admin/categories/delete?id='+catId; return false; EOD; echo CHtml::link('Удалить', '#', array( 'onclick'=>$js_delete));
$this->breadcrumbs = array(Yii::t('ui', 'Persons')); ?> <h2><?php echo Yii::t('ui', 'Manage Persons'); ?> </h2> <div class="actionBar"> <?php echo CHtml::link(Yii::t('ui', 'New'), array('create')); ?> </div> <!-- actionBar --> <?php $this->widget('zii.widgets.grid.CGridView', array('id' => 'person-grid', 'dataProvider' => $model->search(), 'filter' => $model, 'htmlOptions' => array('style' => 'width:740px'), 'pager' => array('header' => '', 'firstPageLabel' => '<<', 'prevPageLabel' => '<', 'nextPageLabel' => '>', 'lastPageLabel' => '>>'), 'columns' => array(array('name' => 'lastname', 'type' => 'raw', 'value' => 'CHtml::link($data->lastname, $this->grid->controller->createReturnableUrl("view",array("id"=>$data->id)))', 'filter' => $this->widget('zii.widgets.jui.CJuiAutoComplete', array('model' => $model, 'attribute' => 'lastname', 'source' => $this->createUrl('request/suggestLastname'), 'options' => array('focus' => "js:function(event, ui) {\n\t\t\t\t\t\t\$('#" . CHtml::activeId($model, 'lastname') . "').val(ui.item.value);\n\t\t\t\t\t}")), true)), 'firstname', 'birthyear', array('name' => 'country_id', 'value' => '$data->country->name', 'filter' => Country::model()->options), array('name' => 'eyecolor_code', 'value' => 'Lookup::item("eyecolor",$data->eyecolor_code)', 'filter' => Lookup::items('eyecolor')), array('class' => 'CLinkColumn', 'header' => Yii::t('ui', 'Email'), 'imageUrl' => XHtml::imageUrl('email.png'), 'labelExpression' => '$data->email', 'urlExpression' => '"mailto://".$data->email', 'htmlOptions' => array('style' => 'text-align:center')), array('class' => 'CButtonColumn', 'viewButtonUrl' => '$this->grid->controller->createReturnableUrl("view",array("id"=>$data->id))', 'updateButtonUrl' => '$this->grid->controller->createReturnableUrl("update",array("id"=>$data->id))', 'deleteButtonUrl' => '$this->grid->controller->createReturnableUrl("delete",array("id"=>$data->id))', 'deleteConfirmation' => Yii::t('ui', 'Are you sure to delete this item?'))), 'afterAjaxUpdate' => "function(){\n\t\tjQuery('#" . CHtml::activeId($model, 'lastname') . "').autocomplete({\n\t\t\t'delay':300,\n\t\t\t'minLength':2,\n\t\t\t'source':'" . $this->createUrl('request/suggestLastname') . "',\n\t\t\t'focus':function(event, ui) {\n\t\t\t\t\$('#" . CHtml::activeId($model, 'lastname') . "').val(ui.item.value);\n\t\t\t}\n\t\t});\n\t}")); ?> <br /> <div class="tpanel"> <div class="toggle"><?php echo Yii::t('ui', 'View code'); ?> </div> <?php $this->beginWidget('CTextHighlighter', array('language' => 'PHP')); ?> $this->widget('zii.widgets.grid.CGridView', array( 'id'=>'person-grid', 'dataProvider'=>$model->search(),
<?php echo CHtml::activeLabel($model, 'status'); ?> <?php $statuses = Lookup::items('BugStatus'); $statuses = array(-1 => '<any>') + $statuses; echo CHtml::dropDownList('Bug[status]', array('selected' => $model->status), $statuses); ?> </div> <div class="row"> <?php echo CHtml::activeLabel($model, 'priority'); ?> <?php $items = Lookup::items('BugPriority'); $items = array(-1 => '<any>') + $items; echo CHtml::activeDropDownList($model, 'priority', $items); ?> <?php echo CHtml::error($model, 'priority'); ?> </div> <div class="row"> <?php echo CHtml::activeLabel($model, 'date_created'); ?> From: <?php $this->widget('zii.widgets.jui.CJuiDatePicker', array('name' => 'Bug[createdFrom]', 'value' => $model->createdFrom, 'options' => array('showAnim' => 'fold'), 'htmlOptions' => array()));
<?php $this->breadcrumbs = array('Manage Posts'); ?> <h1>Manage Posts</h1> <?php $this->widget('zii.widgets.grid.CGridView', array('dataProvider' => $model->search(), 'filter' => $model, 'columns' => array(array('name' => 'title', 'type' => 'raw', 'value' => 'CHtml::link(CHtml::encode($data->title), $data->url)'), array('name' => 'status', 'value' => 'Lookup::item("PostStatus",$data->status)', 'filter' => Lookup::items('PostStatus')), array('name' => 'create_time', 'type' => 'datetime', 'filter' => false), array('class' => 'CButtonColumn'))));
<div class="row"> <?php echo CHtml::activeLabel($model, 'description'); ?> <?php echo CHtml::activeTextField($model, 'description', array('value' => $model->description)); ?> </div> <div class="row"> <?php echo CHtml::activeLabel($model, 'status'); ?> <?php $statuses = Lookup::items('CrashReportStatus', $model->status); $statuses = array(-1 => '<any>') + $statuses; echo CHtml::dropDownList('CrashReport[status]', array('selected' => $model->status), $statuses); ?> </div> <div class="row"> <?php echo CHtml::activeLabel($model, 'received'); ?> From: <?php $this->widget('zii.widgets.jui.CJuiDatePicker', array('name' => 'CrashReport[receivedFrom]', 'value' => $model->receivedFrom, 'options' => array('showAnim' => 'fold'), 'htmlOptions' => array())); ?> To: <?php
<?php echo $form->labelEx($model, 'tags'); ?> <div class="controls"> <?php $this->widget('CAutoComplete', array('model' => $model, 'attribute' => 'tags', 'url' => array('suggestTags'), 'multiple' => true, 'htmlOptions' => array('size' => 50))); ?> <p class="hint">Please separate different tags with commas.</p> <?php echo $form->error($model, 'tags'); ?> </div> </div> <?php echo $form->dropDownListControlGroup($model, 'status', Lookup::items('PostStatus')); ?> <?php echo $form->dropDownListControlGroup($model, 'language', array('zh_cn' => '中文', 'en' => '英文')); ?> <div class="form-actions"> <?php echo TbHtml::submitButton($model->isNewRecord ? 'Create' : 'Save', array('color' => TbHtml::BUTTON_COLOR_PRIMARY, 'size' => TbHtml::BUTTON_SIZE_LARGE)); ?> </div> <?php $this->endWidget(); ?>
?> <?php echo $form->dropDownList($model, 'status', Lookup::items('PostStatus')); ?> </div> <?php echo $form->error($model, 'status'); ?> </div> <div class="row"> <div class="form-group"> <?php echo $form->labelEx($model, 'type'); ?> <?php echo $form->dropDownList($model, 'type', Lookup::items('PostType')); ?> </div> <?php echo $form->error($model, 'type'); ?> </div> <div class="row buttons"> <?php echo CHtml::submitButton($model->isNewRecord ? 'Create' : 'Save'); ?> </div> <?php $this->endWidget();
?> <?php $this->widget('CAutoComplete', array('model' => $model, 'attribute' => 'tags', 'url' => array('suggestTags'), 'multiple' => true, 'htmlOptions' => array('size' => 50))); ?> <p class="hint">Please separate different tags with commas.</p> <?php echo $form->error($model, 'tags'); ?> </div> <div class="row"> <?php echo $form->labelEx($model, 'status'); ?> <?php echo $form->dropDownList($model, 'status', Lookup::items('PostStatus')); ?> <?php echo $form->error($model, 'status'); ?> </div> <?php $this->widget('ext.EAjaxUpload.EAjaxUpload', array('id' => 'uploadFile', 'config' => array('action' => Yii::app()->createUrl('post/upload'), 'allowedExtensions' => array("jpg"), 'sizeLimit' => 10 * 1024 * 1024, 'minSizeLimit' => 0))); ?> <div class="row buttons"> <?php
<?php $this->breadcrumbs = array('Menu'); ?> <h1>Green Door Food Menu</h1> <p> <?php $courses = Lookup::items('CourseType'); foreach ($courses as $course) { echo '--- ' . $course; } $this->widget('zii.widgets.jui.CJuiAccordion', array('panels' => array('panel 1' => 'Content for panel 1', 'panel 2' => 'Content for panel 2', 'panel 3' => $this->renderPartial('pages/_content1', null, true)), 'options' => array('collapsible' => true, 'active' => 1), 'htmlOptions' => array('style' => 'width:500px;'))); ?> <h3><a href="index.php?r=menu/soupAndBreads">Soup and Breads</a></h3> <h3><a href="index.php?r=menu/hotFoods">Hot Food</h3> <h3><a href="index.php?r=menu/salads">Salads</h3> <h3><a href="index.php?r=menu/desserts">Deserts</h3> </p>