change procurement product selection, keytoggle redirect change

This commit is contained in:
2016-03-01 21:18:39 +01:00
parent b07bc4eca9
commit 80b8f5a238
12 changed files with 184 additions and 35 deletions

View File

@@ -2,6 +2,7 @@
use yii\helpers\Html;
use backend\assets\ProcurementCreateAsset;
use yii\helpers\Url;
/* @var $this yii\web\View */
@@ -14,12 +15,35 @@ $this->params['breadcrumbs'][] = $this->title;
ProcurementCreateAsset::register($this);
$this->registerJs(' new ProcurementCreate( { } );');
$options = [];
$options['products'] = $products;
$options['url_product_find'] = Url::toRoute(['product/find']);
$this->registerJs(' new ProcurementCreate( '. json_encode($options) .' );');
?>
<div class="procurement-create">
<h1><?= Html::encode($this->title) ?></h1>
<div class="row">
<div class="col-md-6">
<table class="table table-striped">
<tr>
<th>Terméknév</th>
<td class="product-name"></td>
</tr>
<tr>
<th>Mennyiség</th>
<td class="product-stock"></td>
</tr>
<tr>
<th>Termék kategória</th>
<td class="product-category"></td>
</tr>
</table>
</div>
</div>
<?= $this->render('_form', [
'model' => $model,