<?php

namespace Entity\Model;

use Helpers\QueryBuilder\QueryBuilder;
use Helpers\Trad\Trad;

class GrpSociete extends QueryBuilder
{
    protected \PDO $pdo;
    
    protected string $table = 'GROUPSOC with (nolock)';
    
    protected string $primaryKey = 'CODE_GRP';
    protected string $libelle = 'RS_GRP';
    public string $titre;

    public function __construct(\PDO $pdo)
    {
        
        $this->pdo = $pdo;
    }

    public function getArchitecture(\Helpers\Trad\ITrad $trad)
    {
        return
        [
            'CODE_GRP' => [
                'nomChamp' =>$trad->t("Code Groupe Société"),
                'type' => 'TEXTE',
                'taille' => 7,
                'obligatoire' => true
            ],
            'RS_GRP' => [
                'nomChamp' => $trad->t('Raison Sociale Groupe'),
                'type' => 'TEXTEAREA',
                'taille' => 45,
                'obligatoire' => true
            ],
            'SIEGE' => [
                'nomChamp' => $trad->t('Siege'),
                'type' => 'TEXTE',
                'taille' => 7,
                'obligatoire' => true
            ],

        ];
    }
}
