49 lines
1.1 KiB
PHP
49 lines
1.1 KiB
PHP
<?php
|
|
|
|
namespace App\Entities\Part;
|
|
|
|
use App\Models\Part\IPModel;
|
|
|
|
class IPEntity extends PartType3Entity
|
|
{
|
|
const PK = IPModel::PK;
|
|
const TITLE = IPModel::TITLE;
|
|
protected $attributes = [
|
|
'title' => '',
|
|
'used' => 0,
|
|
'price' => 0,
|
|
'stock' => 0,
|
|
'ip' => '',
|
|
'status' => '',
|
|
];
|
|
public function __construct(array|null $data = null)
|
|
{
|
|
parent::__construct($data);
|
|
}
|
|
public function getLineInfoUID(): int|null
|
|
{
|
|
return $this->attributes['lineinfo_uid'] ?? null;
|
|
}
|
|
public function getOldClientInfoUID(): int|null
|
|
{
|
|
return $this->attributes['old_clientinfo_uid'] ?? null;
|
|
}
|
|
final public function getClientInfoUid(): int|null
|
|
{
|
|
return $this->attributes['clientinfo_uid'];
|
|
}
|
|
final public function getServiceInfoUid(): int|null
|
|
{
|
|
return $this->attributes['serviceinfo_uid'];
|
|
}
|
|
final public function getServerInfoUid(): int|null
|
|
{
|
|
return $this->attributes['serverinfo_uid'];
|
|
}
|
|
//기본기능
|
|
public function getIP(): string
|
|
{
|
|
return $this->attributes['ip'] ?? "";
|
|
}
|
|
}
|