@@ -1,20 +1,19 @@
<?php

$this->breadcrumbs = array(
$model->label(2) => array('index'),
Yii::t('app', 'Create'),
$model->label(2) => array('index'),
Yii::t('app', 'Create'),
);

$this->menu = array(
array('label'=>Yii::t('app', 'List') . ' ' . $model->label(2), 'url' => array('index')),
array('label'=>Yii::t('app', 'Manage') . ' ' . $model->label(2), 'url' => array('admin')),
array('label' => Yii::t('app', 'List') . ' ' . $model->label(2), 'url' => array('index')),
array('label' => Yii::t('app', 'Manage') . ' ' . $model->label(2), 'url' => array('admin')),
);
?>

<h1><?php echo Yii::t('app', 'Create') . ' ' . GxHtml::encode($model->label()); ?></h1>

<?php
$this->renderPartial('_form', array(
'model' => $model,
'buttons' => 'create'));
'model' => $model,
'buttons' => 'create'));
?>
@@ -1,19 +1,19 @@
<?php

$this->breadcrumbs = array(
Category::label(2),
Yii::t('app', 'Index'),
Category::label(2),
Yii::t('app', 'Index'),
);

$this->menu = array(
array('label'=>Yii::t('app', 'Create') . ' ' . Category::label(), 'url' => array('create')),
array('label'=>Yii::t('app', 'Manage') . ' ' . Category::label(2), 'url' => array('admin')),
array('label' => Yii::t('app', 'Create') . ' ' . Category::label(), 'url' => array('create')),
array('label' => Yii::t('app', 'Manage') . ' ' . Category::label(2), 'url' => array('admin')),
);
?>

<h1><?php echo GxHtml::encode(Category::label(2)); ?></h1>

<?php $this->widget('zii.widgets.CListView', array(
'dataProvider'=>$dataProvider,
'itemView'=>'_view',
));
<?php
$this->widget('zii.widgets.CListView', array(
'dataProvider' => $dataProvider,
'itemView' => '_view',
));
@@ -1,22 +1,21 @@
<?php

$this->breadcrumbs = array(
$model->label(2) => array('index'),
GxHtml::valueEx($model) => array('view', 'id' => GxActiveRecord::extractPkValue($model, true)),
Yii::t('app', 'Update'),
$model->label(2) => array('index'),
GxHtml::valueEx($model) => array('view', 'id' => GxActiveRecord::extractPkValue($model, true)),
Yii::t('app', 'Update'),
);

$this->menu = array(
array('label' => Yii::t('app', 'List') . ' ' . $model->label(2), 'url'=>array('index')),
array('label' => Yii::t('app', 'Create') . ' ' . $model->label(), 'url'=>array('create')),
array('label' => Yii::t('app', 'View') . ' ' . $model->label(), 'url'=>array('view', 'id' => GxActiveRecord::extractPkValue($model, true))),
array('label' => Yii::t('app', 'Manage') . ' ' . $model->label(2), 'url'=>array('admin')),
array('label' => Yii::t('app', 'List') . ' ' . $model->label(2), 'url' => array('index')),
array('label' => Yii::t('app', 'Create') . ' ' . $model->label(), 'url' => array('create')),
array('label' => Yii::t('app', 'View') . ' ' . $model->label(), 'url' => array('view', 'id' => GxActiveRecord::extractPkValue($model, true))),
array('label' => Yii::t('app', 'Manage') . ' ' . $model->label(2), 'url' => array('admin')),
);
?>

<h1><?php echo Yii::t('app', 'Update') . ' ' . GxHtml::encode($model->label()) . ' ' . GxHtml::encode(GxHtml::valueEx($model)); ?></h1>

<?php
$this->renderPartial('_form', array(
'model' => $model));
'model' => $model));
?>
@@ -1,28 +1,29 @@
<?php

$this->breadcrumbs = array(
$model->label(2) => array('index'),
GxHtml::valueEx($model),
$model->label(2) => array('index'),
GxHtml::valueEx($model),
);

$this->menu=array(
array('label'=>Yii::t('app', 'List') . ' ' . $model->label(2), 'url'=>array('index')),
array('label'=>Yii::t('app', 'Create') . ' ' . $model->label(), 'url'=>array('create')),
array('label'=>Yii::t('app', 'Update') . ' ' . $model->label(), 'url'=>array('update', 'id' => $model->id)),
array('label'=>Yii::t('app', 'Delete') . ' ' . $model->label(), 'url'=>'#', 'linkOptions' => array('submit' => array('delete', 'id' => $model->id), 'confirm'=>'Are you sure you want to delete this item?')),
array('label'=>Yii::t('app', 'Manage') . ' ' . $model->label(2), 'url'=>array('admin')),
$this->menu = array(
array('label' => Yii::t('app', 'List') . ' ' . $model->label(2), 'url' => array('index')),
array('label' => Yii::t('app', 'Create') . ' ' . $model->label(), 'url' => array('create')),
array('label' => Yii::t('app', 'Update') . ' ' . $model->label(), 'url' => array('update', 'id' => $model->id)),
array('label' => Yii::t('app', 'Delete') . ' ' . $model->label(), 'url' => '#', 'linkOptions' => array('submit' => array('delete', 'id' => $model->id), 'confirm' => 'Are you sure you want to delete this item?')),
array('label' => Yii::t('app', 'Manage') . ' ' . $model->label(2), 'url' => array('admin')),
);
?>

<h1><?php echo Yii::t('app', 'View') . ' ' . GxHtml::encode($model->label()) . ' ' . GxHtml::encode(GxHtml::valueEx($model)); ?></h1>

<?php $this->widget('zii.widgets.CDetailView', array(
'data' => $model,
'attributes' => array(
'id',
'name',
'description',
'image',
),
)); ?>
<?php
$this->widget('zii.widgets.CDetailView', array(
'data' => $model,
'attributes' => array(
'id',
'name',
'description',
'image',
),
));
?>

Large diffs are not rendered by default.

@@ -1,16 +1,3 @@
<?php $this->pageTitle=Yii::app()->name; ?>
<?php

<h1>Welcome to <i><?php echo CHtml::encode(Yii::app()->name); ?></i></h1>

<p>Congratulations! You have successfully created your Yii application.</p>

<p>You may change the content of this page by modifying the following two files:</p>
<ul>
<li>View file: <tt><?php echo __FILE__; ?></tt></li>
<li>Layout file: <tt><?php echo $this->getLayoutFile('main'); ?></tt></li>
</ul>

<p>For more details on how to further develop this application, please read
the <a href="http://www.yiiframework.com/doc/">documentation</a>.
Feel free to ask in the <a href="http://www.yiiframework.com/forum/">forum</a>,
should you have any questions.</p>
$this->widget('HTMLWidget', array('title' => '1'));
@@ -0,0 +1,14 @@
<?php

Yii::import('zii.widgets.CPortlet');

class HTMLWidget extends CPortlet {

public function run() {
$content = rand(1, 3);
$this->render('HTMLWidget', array(
'content' => $content,
));
}

}
@@ -0,0 +1,3 @@
<?php

echo $content;