<?php
/* @var $this SourceMessageController */
/* @var $model SourceMessage */
$this->breadcrumbs = array(
    'Source Messages' => array('admin'),
    'Manage',
);
$this->menu = array(
    array('label' => 'Create Source Message', 'url' => array('create')),
);
?>
<div class="page-header"><h1>Manage Source Messages</h1></div>
<?php
$this->widget('ext.widgets.FGridView', array(
    'id' => 'source-message-grid',
    'dataProvider' => $model->search(),
    'filter' => $model,
    'columns' => array(
        array(
            'name' => 'id',
            'htmlOptions' => array('style' => 'width:50px;'),
        ),
        array(
            'name' => 'category',
            'filter' => $model->getCategories(),
            'htmlOptions' => array('style' => "width:200px"),
        ),
        array(
            'class' => 'editable.EditableColumn',
            'name' => 'message',
            'headerHtmlOptions' => array('style' => 'width: 110px'),
            'editable' => array(//editable section
                'url' => $this->createUrl('quickUpdate'),
                'placement' => 'right',
            ),
            'htmlOptions' => array('width' => '300px'),
        ),
        array(
            "value" => 'CHtml::link(Yii::t("admin", "Translate"), array("/admin/fmessage/message/create", "source_id" => $data->id),array("class"=>"btn btn-xs btn-primary"))." ".CHtml::link(Yii::t("admin", "Manage Translates"), array("/admin/fmessage/message/admin", "Message[id]" => $data->id),array("class"=>"btn btn-xs"))',
            'type' => 'html',
        ),
        array(
            'class' => 'CButtonColumn',
            'template' => '{update} {delete}',
        ),
    ),
));
?>
