<?php
/* @var $this NoteController */
/* @var $model Note */
/* @var $form CActiveForm */
?>
<div class="form">
<?php $form=$this->beginWidget('CActiveForm', array(
"id" => "note-form",
"enableAjaxValidation" => true,
)); ?>
<div class="row">
<?php echo $form->label($model,'id_type'); ?>
<?php echo $form->textField($model,'id_type'); ?>
<?php echo $form->error($model,'id_type'); ?>
</div>
<div class="row">
<?php echo $form->label($model,'title'); ?>
<?php echo $form->textField($model,'title'); ?>
<?php echo $form->error($model,'title'); ?>
</div>
<div class="row">
<?php echo $form->label($model,'content'); ?>
<?php echo $form->textArea($model,'content'); ?>
<?php echo $form->error($model,'content'); ?>
</div>
<div class="row">
<?php echo $form->label($model,'addition_date'); ?>
<?php echo $form->textField($model,'addition_date'); ?>
<?php echo $form->error($model,'addition_date'); ?>
</div>
<div class="row">
<?php echo $form->label($model,'is_deleted'); ?>
<?php echo $form->checkBox($model, 'is_deleted'); ?>
<?php echo $form->error($model,'is_deleted'); ?>
</div>
<div class="row buttons">
<?php echo CHtml::ajaxSubmitButton("Применить", Yii::app()->request->requestUri, array(
"type" => "POST",
"data" => "js:jQuery(this).parents('form').serialize()",
"update" => "#out",
"success" => "function(data,textStatus){ alert(data + ' - ' + textStatus); }",
)); ?>
<?php echo CHtml::resetButton('Отмена'); ?>
</div>
<div id="out"></div>
<?php $this->endWidget(); ?>
</div><!-- form -->