Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
n/a
0 / 0
n/a
0 / 0
CRAP
n/a
0 / 0
ContactMapper
n/a
0 / 0
n/a
0 / 0
0
n/a
0 / 0
1<?php
2/**
3 * Jingga
4 *
5 * PHP Version 8.1
6 *
7 * @package   Modules\Admin\Models
8 * @copyright Dennis Eichhorn
9 * @license   OMS License 2.0
10 * @version   1.0.0
11 * @link      https://jingga.app
12 */
13declare(strict_types=1);
14
15namespace Modules\Admin\Models;
16
17use phpOMS\DataStorage\Database\Mapper\DataMapperFactory;
18
19/**
20 * Contact mapper class.
21 *
22 * @package Modules\Admin\Models
23 * @license OMS License 2.0
24 * @link    https://jingga.app
25 * @since   1.0.0
26 *
27 * @template T of Contact
28 * @extends DataMapperFactory<T>
29 */
30final class ContactMapper extends DataMapperFactory
31{
32    /**
33     * Columns.
34     *
35     * @var array<string, array{name:string, type:string, internal:string, autocomplete?:bool, readonly?:bool, writeonly?:bool, annotations?:array}>
36     * @since 1.0.0
37     */
38    public const COLUMNS = [
39        'account_contact_id'      => ['name' => 'account_contact_id', 'type' => 'int', 'internal' => 'id'],
40        'account_contact_type'    => ['name' => 'account_contact_type', 'type' => 'int', 'internal' => 'type'],
41        'account_contact_subtype' => ['name' => 'account_contact_subtype', 'type' => 'int', 'internal' => 'subtype'],
42        'account_contact_order'   => ['name' => 'account_contact_order', 'type' => 'int', 'internal' => 'order'],
43        'account_contact_content' => ['name' => 'account_contact_content', 'type' => 'string', 'internal' => 'content'],
44        'account_contact_module'  => ['name' => 'account_contact_module', 'type' => 'string', 'internal' => 'module'],
45        'account_contact_account' => ['name' => 'account_contact_account', 'type' => 'int', 'internal' => 'account'],
46    ];
47
48    /**
49     * Primary table.
50     *
51     * @var string
52     * @since 1.0.0
53     */
54    public const TABLE = 'account_contact';
55
56    /**
57     * Primary field name.
58     *
59     * @var string
60     * @since 1.0.0
61     */
62    public const PRIMARYFIELD = 'account_contact_id';
63}