135 lines
4.7 KiB
Smarty
135 lines
4.7 KiB
Smarty
{extends file=$smarty.current_dir|cat:'/../extends.tpl'}
|
|
{use class="yii\helpers\Url"}
|
|
{use class="yii\grid\GridView"}
|
|
{use class="app\assets\LogsAsset"}
|
|
{LogsAsset::register($this)|void}
|
|
{block name='content'}
|
|
<style>
|
|
.img-thumbnail{
|
|
max-width: inherit;
|
|
}
|
|
.popover{
|
|
max-width:600px;
|
|
}
|
|
</style>
|
|
<input type="hidden" value="{Url::to(['/logs/save'])}" name="saveUrl">
|
|
<div class="row">
|
|
<div class="col-md-2">
|
|
<div class="form-group">
|
|
<div class="input-group">
|
|
<div class="input-group-addon">Từ</div>
|
|
<input type='text' value="{$from}" class="form-control" id='from' name='FromTime' readonly="">
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="col-md-2">
|
|
<div class="form-group">
|
|
<div class="input-group">
|
|
<div class="input-group-addon">Đến</div>
|
|
<input type='text' value="{$to}" class="form-control" id='to' name='ToTime' readonly="">
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="col-md-1">
|
|
<button class="btn btn-primary btn-block" onclick="search(this);" data-href='{Url::to(['index'])}'>
|
|
<i class="fa fa-search"></i> Search
|
|
</button>
|
|
</div>
|
|
<div class="col-md-2">
|
|
<button class="btn btn-success" onclick="_export(this);" data-href='{Url::to(['export'])}'>
|
|
<i class="fa fa-download"></i> Xuất báo cáo
|
|
</button>
|
|
</div>
|
|
<div class="col-md-1 col-md-push-3">
|
|
<button class="btn btn-info" onclick="window.location.reload(true);">
|
|
<i class="fa fa-refresh"></i> Làm mới
|
|
</button>
|
|
</div>
|
|
<div class="col-md-2 col-md-push-3">
|
|
<a href="{Url::to(['/logs-unknow'])}" class="btn btn-danger">
|
|
<i class="fa fa-truck"></i> Xe khác
|
|
</a>
|
|
</div>
|
|
</div>
|
|
<br>
|
|
{GridView::widget([
|
|
'dataProvider' => $dataProvider,
|
|
'filterModel' => $searchModel,
|
|
'layout'=> \app\helpers\LogsGrid::getLayout(),
|
|
'tableOptions' => [
|
|
'class' => 'table table-striped table-bordered',
|
|
'style' => 'background:#fff;min-width:700px;'
|
|
],
|
|
'columns' => [
|
|
['class' => 'yii\grid\SerialColumn'],
|
|
[
|
|
'attribute' => 'plate',
|
|
'value' => 'vehicle.plate'
|
|
],
|
|
[
|
|
'attribute' => 'type',
|
|
'value' => 'vehicle.type'
|
|
],
|
|
[
|
|
'attribute' => 'company',
|
|
'value' => 'vehicle.company'
|
|
],
|
|
[
|
|
'attribute' => 'driver',
|
|
'format' => 'raw',
|
|
'value' => \app\helpers\LogsGrid::driver()
|
|
],
|
|
[
|
|
'attribute' => 'telephone',
|
|
'format' => 'raw',
|
|
'value' => \app\helpers\LogsGrid::telephone()
|
|
],
|
|
[
|
|
'attribute' => 'cmt',
|
|
'format' => 'raw',
|
|
'value' => \app\helpers\LogsGrid::cmt()
|
|
],
|
|
[
|
|
'attribute' => 'factory',
|
|
'format' => 'raw',
|
|
'value' => \app\helpers\LogsGrid::factory()
|
|
],
|
|
[
|
|
'attribute' => 'seal_no',
|
|
'format' => 'raw',
|
|
'value' => \app\helpers\LogsGrid::sealNo()
|
|
],
|
|
[
|
|
'attribute' => "plate_image_in",
|
|
'format' => 'raw',
|
|
'contentOptions' => ['class' => 'text-center'],
|
|
'value' => \app\helpers\LogsGrid::plateIn()
|
|
],
|
|
[
|
|
'attribute' => "time_in",
|
|
'format' => 'raw',
|
|
'contentOptions' => ['class' => 'text-center'],
|
|
'headerOptions' => ['style' => 'width:5%'],
|
|
'value' => \app\helpers\LogsGrid::timeIn()
|
|
],
|
|
[
|
|
'attribute' => "plate_image_out",
|
|
'format' => 'raw',
|
|
'contentOptions' => ['class' => 'text-center'],
|
|
'value' => \app\helpers\LogsGrid::plateOut()
|
|
],
|
|
[
|
|
'attribute' => "time_out",
|
|
'format' => 'raw',
|
|
'contentOptions' => ['class' => 'text-center'],
|
|
'headerOptions' => ['style' => 'width:5%'],
|
|
'value' => \app\helpers\LogsGrid::timeOut()
|
|
],
|
|
[
|
|
'attribute' => 'note',
|
|
'format' => 'raw',
|
|
'value' => \app\helpers\LogsGrid::note()
|
|
]
|
|
]
|
|
])}
|
|
{/block} |