app->app_name;
};
}
public static function getLayout() {
return "{items}
";
}
public static function actionTemplate() {
return "{update} {delete}";
}
public static function plateIn() {
return function($model) {
if ($model->time_in) {
$style = "width:100px;cursor:pointer;";
$image = $model->plate_image_in;
return Html::img(Yii::$app->request->hostInfo . "/AIParking_Intops_Server/web/data/uploads/" . $image, [
'class' => "img-thumbnail",
"style" => $style,
"data" => [
"toggle" => "popover-hover",
"img" => Yii::$app->request->hostInfo . "/AIParking_Intops_Server/web/data/uploads/" . $model->frame_image_in,
"size" => "min"
],
"onclick" => "resizeImage(this);"
]);
} else {
return "";
}
};
}
public static function plateOut() {
return function($model) {
if ($model->time_out) {
$style = "width:100px;cursor:pointer;";
$image = $model->plate_image_out;
return Html::img(Yii::$app->request->hostInfo . "/AIParking_Intops_Server/web/data/uploads/" . $image, [
'class' => "img-thumbnail",
"style" => $style,
"data" => [
"toggle" => "popover-hover",
"img" => Yii::$app->request->hostInfo . "/AIParking_Intops_Server/web/data/uploads/" . $model->frame_image_out,
"size" => "min"
],
"onclick" => "resizeImage(this);"
]);
} else {
return "";
}
};
}
public static function timeIn() {
return function($model) {
if ($model->time_in) {
$common = new common();
return $common->formatTime($model->time_in, "H:i:s d/m/Y");
} else {
return "";
}
};
}
public static function timeOut() {
return function($model) {
if ($model->time_out) {
$common = new common();
return $common->formatTime($model->time_out, "H:i:s d/m/Y");
} else {
return "";
}
};
}
public static function driver() {
return function($model) {
$ls = explode("/", $model->vehicle->driver);
return implode("
", $ls);
};
}
public static function telephone() {
return function($model) {
$ls = explode("/", $model->vehicle->telephone);
return implode("
", $ls);
};
}
public static function cmt() {
return function($model) {
$ls = explode("/", $model->vehicle->indentity_card);
return implode("
", $ls);
};
}
public static function factory() {
return function($model) {
$text = $model->factory;
if ($model->factory == null)
$text = "không có";
$data = "{$text}
";
return $data;
};
}
public static function sealNo() {
return function($model) {
$text = $model->seal_no;
if ($model->seal_no == null)
$text = "không có";
$data = "{$text}
";
return $data;
};
}
public static function note() {
return function($model) {
$text = $model->note;
if ($model->note == null)
$text = "không có";
$data = "{$text}
";
return $data;
};
}
}