public function actionAdmin()
 {
     $model = new IguClientProduct('search');
     $model->unsetAttributes();
     if (isset($_GET['IguClientProduct'])) {
         $model->setAttributes($_GET['IguClientProduct']);
     }
     $this->render('admin', array('model' => $model));
 }
Example #2
0
<?php

$this->breadcrumbs = array($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', 'Amamaza ') . ' ' . IguClientProduct::label(), 'url' => array('create')));
$this->beginWidget('zii.widgets.CPortlet', array('htmlOptions' => array('class' => '')));
$this->widget('bootstrap.widgets.TbMenu', array('type' => 'pills', 'items' => array(array('label' => 'Amamaza', 'icon' => 'icon-plus', 'url' => Yii::app()->controller->createUrl('create'), 'linkOptions' => array()), array('label' => 'Ibicuruzwa', 'icon' => 'icon-search', 'url' => Yii::app()->controller->createUrl('admin'), 'linkOptions' => array()))));
$this->endWidget();
?>
<h3><?php 
echo Yii::t('app', 'Guhindura') . ' ' . GxHtml::encode($model->label());
?>
</h3>

<?php 
$this->renderPartial('_form', array('model' => $model));
Example #3
0
					<div id="content" style='background:white'>
						<ul id="tabs" class="nav nav-tabs" data-tabs="tabs" style='background:#F8F8F8'>
							<li class="active" ><a href="#red" data-toggle="tab">Ibigurishwa</a></li>
							<li><a href="#orange" data-toggle="tab">Imbuto</a></li>
							<li><a href="#yellow" data-toggle="tab">Imboga</a></li>
							<li><a href="#green" data-toggle="tab">Ibihingwa Ngengabukungu</a></li>
							<li><a href="#blue" data-toggle="tab">Ibihingwa Ngandurarugo</a></li>
							<li><a href="#white" data-toggle="tab">Amatungo</a></li>
						</ul>
						<div id="my-tab-content" class="tab-content" >
							<div class="tab-pane active" id="red" >
							<!-- ------------------------------------------------ Ibigurishwa --------------------------------------- -->
								 <div class="">
										<?php 
$this->beginWidget('zii.widgets.CPortlet', array('title' => "<center>Ntimucikwe</center>"));
$rawData = IguClientProduct::displayProductsHomegage();
foreach ($rawData as $row) {
    if ($row['idsouscategory'] == 4 || $row['idsouscategory'] == 5 || $row['idsouscategory'] == 6 || $row['idsouscategory'] == 7) {
        $ku = 'zigera ku ';
    } else {
        $ku = 'agera ku biro ';
    }
    $link = $row['district'] . " haraboneka " . $row['productname'] . " " . $ku . " " . $row['quantity'] . " ,ubwo mwabaza kuri izi numero zikurikira " . $row['telephone'];
    $href = '?r=iguClientProduct/displayAll&st=2&id=' . $row["id"];
    $links = '<div style="display: inline-block;"><p  style="font-size:12px"> <a href=' . $href . '>' . $link . '</a></p></div>';
    ?>
										
										<blockquote ><div><?php 
    echo "<div style='display: inline-block;width:7%;height:7%'><img src=images/products/" . $row['image'] . "></div> " . $links . '';
    ?>
</div></p></blockquote>
Example #4
0
<?php

$model = new IguClientProduct();
$b = $model->searchArray();
$this->menu = array(array('label' => Yii::t('app', 'Create') . ' ' . IguClientProduct::label(), 'url' => array('create')));
$form = $this->beginWidget('GxActiveForm', array('action' => Yii::app()->createUrl($this->route), 'method' => 'get'));
$this->beginWidget('zii.widgets.CPortlet', array('title' => "Shakisha"));
$this->widget('zii.widgets.jui.CJuiAutoComplete', array('name' => 'productname', 'source' => $b, 'options' => array('minLength' => '2'), 'htmlOptions' => array('style' => 'height:20px;width:60%')));
echo '&nbsp;&nbsp;&nbsp;' . GxHtml::submitButton(Yii::t('app', 'Search'));
$this->endWidget();
$this->endWidget();
?>
	
<h3><?php 
echo GxHtml::encode(IguClientProduct::label(2));
?>
</h3>

<?php 
$this->widget('zii.widgets.CListView', array('dataProvider' => $dataProvider, 'itemView' => '_view'));
Example #5
0
<?php

$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')));
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('igu-image-product-grid', {\n\t\tdata: \$(this).serialize()\n\t});\n\treturn false;\n});\n");
?>

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

<?php 
echo GxHtml::link(Yii::t('app', 'Advanced Search'), '#', array('class' => 'search-button'));
?>
<div class="search-form">
<?php 
$this->renderPartial('_search', array('model' => $model));
?>
</div><!-- search-form -->

<?php 
$this->widget('zii.widgets.grid.CGridView', array('id' => 'igu-image-product-grid', 'dataProvider' => $model->search(), 'filter' => $model, 'columns' => array('image', array('name' => 'idclientproduct', 'value' => 'GxHtml::valueEx($data->idclientproduct0)', 'filter' => GxHtml::listDataEx(IguClientProduct::model()->findAllAttributes(null, true))), array('class' => 'CButtonColumn'))));
Example #6
0
	<div class="row">
		<?php 
echo $form->label($model, 'image');
?>
		<?php 
echo $form->textField($model, 'image', array('maxlength' => 100));
?>
	</div>

	<div class="row">
		<?php 
echo $form->label($model, 'idclientproduct');
?>
		<?php 
echo $form->dropDownList($model, 'idclientproduct', GxHtml::listDataEx(IguClientProduct::model()->findAllAttributes(null, true)), array('prompt' => Yii::t('app', 'All')));
?>
	</div>

	<div class="row buttons">
		<?php 
echo GxHtml::submitButton(Yii::t('app', 'Search'));
?>
	</div>

<?php 
$this->endWidget();
?>

</div><!-- search-form -->