32 lines
595 B
PHP
32 lines
595 B
PHP
<?php
|
|
|
|
namespace lib\Models;
|
|
|
|
use lib\Entitys\ClientEntity as Entity;
|
|
|
|
class ClientModel extends CommonModel
|
|
{
|
|
public function __construct()
|
|
{
|
|
parent::__construct();
|
|
} //
|
|
|
|
final public function getTable()
|
|
{
|
|
return 'clientdb';
|
|
}
|
|
|
|
final public function getEntity(): Entity
|
|
{
|
|
return new Entity($this->getRow());
|
|
} //
|
|
final public function getEntitys(): array
|
|
{
|
|
$entitys = [];
|
|
foreach ($this->getRows() as $row) {
|
|
$entitys[] = new Entity($row);
|
|
}
|
|
return $entitys;
|
|
} //
|
|
} //Class
|