ẩn dữ liệu thông tin vào/ra

This commit is contained in:
dongpd 2020-11-16 10:59:06 +07:00
parent aa1144da08
commit a2537ab3fc
2 changed files with 2 additions and 10 deletions

View File

@ -143,7 +143,7 @@ class LogsController extends Controller {
$t = date_format(date_create_from_format('H:i:s d/m/Y', $to), 'U');
$objPHPExcel = new \PHPExcel();
$objPHPExcel->setActiveSheetIndex(0);
$toExcelFile[] = ["Thời gian", "Mã nhân viên", "Tên nhân viên", "Phòng ban", "Mã thẻ", "Thiết bị", "Cửa", "Trạng thái vào/ra", "Mô tả sự kiện"];
$toExcelFile[] = ["Thời gian", "Mã nhân viên", "Tên nhân viên", "Phòng ban", "Mã thẻ", "Thiết bị", "Cửa", "", "Mô tả sự kiện"];
$query = Logs::find();
$query->andWhere(["BETWEEN", 'time', $f, $t]);
$query->orderBy(["time" => SORT_DESC]);
@ -161,7 +161,7 @@ class LogsController extends Controller {
$ExportData[] = $v->card_number;
$ExportData[] = isset($deviceArray[$v->device_id]) ? $deviceArray[$v->device_id] : "";
$ExportData[] = isset($deviceArray[$v->device_id]) ? $deviceArray[$v->device_id] . "-" . $v->door_id : "";
$ExportData[] = isset($stateArray[$v->in_out_state]) ? $stateArray[$v->in_out_state] : "";
$ExportData[] = "";//isset($stateArray[$v->in_out_state]) ? $stateArray[$v->in_out_state] : "";
$ExportData[] = isset($eventTypeArray[$v->event_type]) ? $eventTypeArray[$v->event_type] : "";
$toExcelFile[] = $ExportData;
unset($ExportData);

View File

@ -94,14 +94,6 @@
'headerOptions' => ['style' => 'width:10%'],
'value' => \app\helpers\LogsGrid::door($deviceArray)
],
[
'attribute' => 'in_out_state',
'format' => 'raw',
'filter' => $stateArray,
'headerOptions' => ['style' => 'width:8%'],
'contentOptions' => ['class' => 'text-center'],
'value' => \app\helpers\LogsGrid::state($stateArray)
],
[
'attribute' => 'event_type',
'format' => 'raw',