mirror of
https://gitlab.easter-eggs.com/ee/ldapsaisie.git
synced 2024-11-18 16:19:06 +01:00
LSaddon::supann: add new components of supannEtuInscription attribute (SUPANN 2021)
This commit is contained in:
parent
bf28a6ea94
commit
1683cadd73
1 changed files with 89 additions and 78 deletions
|
@ -35,83 +35,94 @@ LSsession :: loadLSaddon('supann');
|
|||
|
||||
class LSformElement_supannEtuInscription extends LSformElement_supannCompositeAttribute {
|
||||
|
||||
public function __construct(&$form, $name, $label, $params, &$attr_html){
|
||||
$this -> components = array (
|
||||
'etab' => array (
|
||||
'label' => _('Organism'),
|
||||
'type' => 'table',
|
||||
'table' => 'codeEtablissement',
|
||||
'required' => true,
|
||||
),
|
||||
'anneeinsc' => array (
|
||||
'label' => _('Registration year'),
|
||||
'type' => 'text',
|
||||
'required' => true,
|
||||
'check_data' => array (
|
||||
'integer' => array (
|
||||
'msg' => _('Registration year must be an integer'),
|
||||
'params' => array (
|
||||
'positive' => true,
|
||||
'min' => 1970
|
||||
)
|
||||
),
|
||||
)
|
||||
),
|
||||
'regimeinsc' => array (
|
||||
'label' => _('Registration regime'),
|
||||
'type' => 'table',
|
||||
'table' => 'etuRegimeInscription',
|
||||
'required' => true
|
||||
),
|
||||
'sectdisc' => array (
|
||||
'label' => _('Discipline sector'),
|
||||
'type' => 'table',
|
||||
'table' => 'etuSecteurDisciplinaire',
|
||||
'required' => true
|
||||
),
|
||||
'typedip' => array (
|
||||
'label' => _('Diploma type'),
|
||||
'type' => 'table',
|
||||
'table' => 'etuTypeDiplome',
|
||||
'required' => true
|
||||
),
|
||||
'cursusann' => array (
|
||||
'label' => _('Cursus & Year'),
|
||||
'type' => 'text',
|
||||
'check_data' => array (
|
||||
'regex' => array (
|
||||
'params' => array (
|
||||
'regex' => '/^[LMDXB][0-9]?$/'
|
||||
)
|
||||
),
|
||||
),
|
||||
'required' => true
|
||||
),
|
||||
'affect' => array (
|
||||
'label' => _('Entity'),
|
||||
'type' => 'codeEntite',
|
||||
'required' => false
|
||||
),
|
||||
'diplome' => array (
|
||||
'label' => _('Diploma'),
|
||||
'type' => 'table',
|
||||
'table' => 'etuDiplome',
|
||||
'required' => false
|
||||
),
|
||||
'etape' => array (
|
||||
'label' => _('Step'),
|
||||
'type' => 'table',
|
||||
'table' => 'etuEtape',
|
||||
'required' => false
|
||||
),
|
||||
'eltpedago' => array (
|
||||
'label' => _('Pedagogical element'),
|
||||
'type' => 'table',
|
||||
'table' => 'etuElementPedagogique',
|
||||
'required' => false
|
||||
)
|
||||
);
|
||||
return parent :: __construct($form, $name, $label, $params, $attr_html);
|
||||
}
|
||||
public function __construct(&$form, $name, $label, $params, &$attr_html){
|
||||
$this -> components = array (
|
||||
'etab' => array (
|
||||
'label' => _('Organism'),
|
||||
'type' => 'table',
|
||||
'table' => 'codeEtablissement',
|
||||
'required' => true,
|
||||
),
|
||||
'anneeinsc' => array (
|
||||
'label' => _('Registration year'),
|
||||
'type' => 'text',
|
||||
'required' => true,
|
||||
'check_data' => array (
|
||||
'integer' => array (
|
||||
'msg' => _('Registration year must be an integer'),
|
||||
'params' => array (
|
||||
'positive' => true,
|
||||
'min' => 1970,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
'regimeinsc' => array (
|
||||
'label' => _('Registration regime'),
|
||||
'type' => 'table',
|
||||
'table' => 'etuRegimeInscription',
|
||||
'required' => true,
|
||||
),
|
||||
'sectdisc' => array (
|
||||
'label' => _('Discipline sector'),
|
||||
'type' => 'table',
|
||||
'table' => 'etuSecteurDisciplinaire',
|
||||
'required' => true,
|
||||
),
|
||||
'typedip' => array (
|
||||
'label' => _('Diploma type'),
|
||||
'type' => 'table',
|
||||
'table' => 'etuTypeDiplome',
|
||||
'required' => true,
|
||||
),
|
||||
'cursusann' => array (
|
||||
'label' => _('Cursus & Year'),
|
||||
'type' => 'text',
|
||||
'check_data' => array (
|
||||
'regex' => array (
|
||||
'params' => array (
|
||||
'regex' => '/^[LMDXB][0-9]?$/'
|
||||
),
|
||||
),
|
||||
),
|
||||
'required' => true,
|
||||
),
|
||||
'affect' => array (
|
||||
'label' => _('Entity'),
|
||||
'type' => 'codeEntite',
|
||||
'required' => false,
|
||||
),
|
||||
'diplome' => array (
|
||||
'label' => _('Diploma'),
|
||||
'type' => 'table',
|
||||
'table' => 'etuDiplome',
|
||||
'required' => false,
|
||||
),
|
||||
'etape' => array (
|
||||
'label' => _('Step'),
|
||||
'type' => 'table',
|
||||
'table' => 'etuEtape',
|
||||
'required' => false,
|
||||
),
|
||||
'eltpedago' => array (
|
||||
'label' => _('Pedagogical element'),
|
||||
'type' => 'table',
|
||||
'table' => 'etuElementPedagogique',
|
||||
'required' => false,
|
||||
),
|
||||
'population' => array (
|
||||
'label' => _('Population'),
|
||||
'type' => 'table',
|
||||
'table' => 'codePopulation',
|
||||
'required' => false,
|
||||
),
|
||||
'datefin' => array (
|
||||
'label' => _('End date'),
|
||||
'type' => 'date',
|
||||
'required' => false,
|
||||
),
|
||||
);
|
||||
return parent :: __construct($form, $name, $label, $params, $attr_html);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue