53 lines
1.3 KiB
PHP
53 lines
1.3 KiB
PHP
<?php
|
|
|
|
namespace App\Services\Equipment;
|
|
|
|
use App\Entities\Equipment\ServerEntity;
|
|
use App\Models\Equipment\ServerModel;
|
|
use App\Services\Equipment\EquipmentService;
|
|
|
|
class ServerService extends EquipmentService
|
|
{
|
|
public function __construct()
|
|
{
|
|
parent::__construct(new ServerModel());
|
|
$this->addClassName('Server');
|
|
}
|
|
public function getFormFields(): array
|
|
{
|
|
return [
|
|
"clientinfo_uid",
|
|
"serviceinfo_uid",
|
|
"code",
|
|
"type",
|
|
"title",
|
|
"price",
|
|
"total_price",
|
|
"manufactur_at",
|
|
"format_at",
|
|
"status",
|
|
];
|
|
}
|
|
public function getFilterFields(): array
|
|
{
|
|
return ['status'];
|
|
}
|
|
public function getBatchJobFields(): array
|
|
{
|
|
return ['type', 'status'];
|
|
}
|
|
public function getIndexFields(): array
|
|
{
|
|
return ['clientinfo_uid', 'serviceinfo_uid', "type", 'title', 'price', 'total_price', 'manufactur_at', "format_at", 'status'];
|
|
}
|
|
//기본 기능부분
|
|
//FieldForm관련용
|
|
//List 검색용
|
|
//OrderBy 처리
|
|
public function setOrderBy(mixed $field = null, mixed $value = null): void
|
|
{
|
|
$this->getModel()->orderBy('title', 'ASC');
|
|
parent::setOrderBy($field, $value);
|
|
}
|
|
}
|