oms-Tag/Models/TagMapper.php
2019-04-27 12:05:33 +02:00

66 lines
1.3 KiB
PHP

<?php
/**
* Orange Management
*
* PHP Version 7.2
*
* @package Modules\Tag
* @copyright Dennis Eichhorn
* @license OMS License 1.0
* @version 1.0.0
* @link http://website.orange-management.de
*/
declare(strict_types=1);
namespace Modules\Tag\Models;
use phpOMS\DataStorage\Database\DataMapperAbstract;
/**
* Tag mapper class.
*
* @package Modules\Tag
* @license OMS License 1.0
* @link http://website.orange-management.de
* @since 1.0.0
*/
final class TagMapper extends DataMapperAbstract
{
/**
* Columns.
*
* @var array<string, array<string, bool|string>>
* @since 1.0.0
*/
protected static $columns = [
'tag_id' => ['name' => 'tag_id', 'type' => 'int', 'internal' => 'id'],
'tag_title' => ['name' => 'tag_title', 'type' => 'string', 'internal' => 'title'],
'tag_color' => ['name' => 'tag_color', 'type' => 'string', 'internal' => 'color'],
];
/**
* Primary table.
*
* @var string
* @since 1.0.0
*/
protected static $table = 'tag';
/**
* Primary field name.
*
* @var string
* @since 1.0.0
*/
protected static $primaryField = 'tag_id';
/**
* Created at.
*
* @var string
* @since 1.0.0
*/
protected static $createdAt = 'tag_created_at';
}