/**
  * Returns the data model based on the primary key given in the GET variable.
  * If the data model is not found, an HTTP exception will be raised.
  * @param integer $id the ID of the model to be loaded
  * @return Coordocs the loaded model
  * @throws CHttpException
  */
 public function loadModel($id)
 {
     $model = Coordocs::model()->findByPk($id);
     if ($model === null) {
         throw new CHttpException(404, 'The requested page does not exist.');
     }
     return $model;
 }
Example #2
0
<div class="panelizquierdo">


<?php 
if (!$model->isNewRecord) {
    $this->widget('zii.widgets.grid.CGridView', array('id' => 'detallex-grid', 'dataProvider' => Mensajes::model()->search_docu($model->coddocu, $model->idguia), 'columns' => array('cuando', 'usuario', 'nombrefichero', 'enviadoel')));
}
?>
</div>
    <div class="panelderecho">

<?php 
$datos1 = CHtml::listData(Coordocs::model()->findAll("codocu=:hu", array(":hu" => $this->documento)), 'id', 'nombrereporte');
echo $form->DropDownList($model, 'idreporte', $datos1, array('prompt' => 'Seleccione un reporte'));
?>


    </div>

<div id="zona_pdf">

</div>
Example #3
0
        <DIV ID="imagenmaterial" >
            <?php 
echo CHtml::image("/recurso/logos/" . $this->documento . ".JPG", "", array('width' => '120', 'height' => '120'));
?>
        </DIV>
    </div>

</div> <!--  FIn del panel derecho      !-->



<h1>Coordendas Reporte</h1>

<div style="width:500px; ">
    <?php 
$this->widget('zii.widgets.grid.CGridView', array('id' => 'detalle-grid4', 'dataProvider' => Coordocs::model()->search('021'), 'summaryText' => '', 'columns' => array('xgeneral', 'ygeneral', 'xlogo', 'ylogo', 'codocu', array('class' => 'CButtonColumn', 'buttons' => array('view' => array('visible' => 'false'), 'update' => array('url' => '$this->grid->controller->createUrl("/Coordocs/Update/",
										    array("id"=>$data->id,
                                                                                         "asDialog"=>1,
											"gridId"=>$this->grid->id
											)
									    )', 'click' => 'function(){
							    $("#cru-detalle").attr("src",$(this).attr("href"));
							    $("#cru-dialogdetalle").dialog("open");
							     return false;
							 }', 'imageUrl' => '' . Yii::app()->getTheme()->baseUrl . Yii::app()->params['rutatemagrid'] . 'update.png', 'label' => 'Actualizar Item'), 'delete' => array('visible' => 'false'))))));
?>
</div>



Example #4
0
//$datos = CHtml::listData(Estado::model()->find('codocu=:c_hcod', array(':c_hcod'=>$documento)),'codestado','estado');
//datos = CHtml::listData(Estado::model()->find($criteria),'codestado','estado');
$datos = CHtml::listData(Documentos::model()->findall($criterial), 'coddocu', 'desdocu');
echo $form->DropDownList($model, 'coddocupadre', $datos, array('empty' => '--Indique un documento padre--'));
?>
		<?php 
echo $form->error($model, 'coddocupadre');
?>
              
		
		</div>

	<div class="row">
		<?php 
echo $form->labelEx($model, 'idreportedefault');
$datos = CHtml::listData(Coordocs::model()->findall(), 'id', 'nombrereporte');
echo $form->DropDownList($model, 'idreportedefault', $datos, array('empty' => '--Indique el reporte--'));
?>

		<?php 
echo $form->error($model, 'idreportedefault');
?>
	</div>

	<div class="row">
		<?php 
echo $form->labelEx($model, 'prefijo');
?>
		<?php 
echo $form->textField($model, 'prefijo', array('size' => 3, 'maxlength' => 3));
?>