Loading SQL/004-evenementiel/00_schemas.sql +13 −0 Changes for SQL/004-evenementiel/00_schemas.sql: 13 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -201,6 +201,9 @@ CREATE TABLE evenementiel_inscription evenement_id INTEGER REFERENCES evenementiel_evenement (id) ON DELETE CASCADE, participant_id INTEGER REFERENCES evenementiel_participant (id) ON DELETE CASCADE, statut VARCHAR(50) DEFAULT 'inscrit', -- inscrit, annulé, en attente type_inscription VARCHAR(32) NOT NULL DEFAULT 'INDIVIDUELLE' CONSTRAINT evenementiel_inscription_type_check CHECK (type_inscription IN ('INDIVIDUELLE', 'GROUPE')), nombre_places_demandees integer default 1, nombre_places_pointees integer default 0, liste varchar(64), Loading @@ -222,6 +225,16 @@ CREATE TABLE evenementiel_inscription create unique index evenementiel_inscription_id_uindex on evenementiel_inscription (id); -- ajout du champ type inscription sur une table existante ALTER TABLE public.evenementiel_inscription ADD COLUMN type_inscription VARCHAR(32) NOT NULL DEFAULT 'INDIVIDUELLE'; ALTER TABLE public.evenementiel_inscription ADD CONSTRAINT evenementiel_inscription_type_check CHECK (type_inscription IN ('INDIVIDUELLE', 'GROUPE')); -- -- 1 ligne = 1 place pour 1 personne drop table evenementiel_inscription_place ; Loading docker-compose.yml +0 −2 Changes for docker-compose.yml: 0 added lines, 2 removed lines. Original line number Diff line number Diff line version: '2' services: inscription_suac: container_name: inscription_suac Loading module/Evenementiel/src/Entity/Db/Evenement.php +1 −2 Changes for module/Evenementiel/src/Entity/Db/Evenement.php: 1 added line, 2 removed lines. Original line number Diff line number Diff line Loading @@ -345,8 +345,7 @@ class Evenement implements HistoriqueAwareInterface, HasEtatsInterface, Resource public function isListePrincipaleComplete(): bool { $liste = $this->getListePrincipale(); return (count($liste) >= $this->getJauge()); return $this->getNombrePlacesDemandees() >= $this->getJauge(); } /** Fonctions pour les macros **********************************************************************************/ Loading module/Evenementiel/src/Entity/Db/Inscription.php +24 −0 Changes for module/Evenementiel/src/Entity/Db/Inscription.php: 24 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -19,6 +19,9 @@ class Inscription implements HistoriqueAwareInterface, HasEtatsInterface, Resour const PRINCIPALE = 'principale'; const COMPLEMENTAIRE = 'complémentaire'; const TYPE_INDIVIDUELLE = 'INDIVIDUELLE'; const TYPE_GROUPE = 'GROUPE'; const ETAPE_ETUDIANT = 'ETAPE_ETUDIANT'; const ETAPE_VALIDATION = 'ETAPE_VALIDATION'; const ETAPE_REFUS = 'ETAPE_REFUS'; Loading @@ -27,6 +30,7 @@ class Inscription implements HistoriqueAwareInterface, HasEtatsInterface, Resour private ?Evenement $evenement = null; private ?Participant $participant = null; private ?string $statut = null; private string $typeInscription = self::TYPE_INDIVIDUELLE; private ?int $nombrePlacesDemandees = 1; private ?int $nombrePlacesPointees = 0; private ?string $liste = null; Loading Loading @@ -83,6 +87,26 @@ class Inscription implements HistoriqueAwareInterface, HasEtatsInterface, Resour $this->statut = $statut; } public function getTypeInscription(): string { return $this->typeInscription; } public function setTypeInscription(string $typeInscription): void { $this->typeInscription = $typeInscription; } public function estIndividuelle(): bool { return $this->typeInscription === self::TYPE_INDIVIDUELLE; } public function estGroupe(): bool { return $this->typeInscription === self::TYPE_GROUPE; } public function getLibelle(): ?string { return $this->evenement?->getLibelle(); Loading module/Evenementiel/src/Entity/Db/Mapping/Evenementiel.Entity.Db.Inscription.dcm.xml +1 −0 Changes for module/Evenementiel/src/Entity/Db/Mapping/Evenementiel.Entity.Db.Inscription.dcm.xml: 1 added line, 0 removed lines. Original line number Diff line number Diff line Loading @@ -13,6 +13,7 @@ </many-to-one> <field name="statut" column="statut" type="string" length="50" nullable="true"/> <field name="typeInscription" column="type_inscription" type="string" length="32" nullable="false"/> <field name="nombrePlacesDemandees" column="nombre_places_demandees" type="integer" nullable="false"/> <field name="nombrePlacesPointees" column="nombre_places_pointees" type="integer" nullable="false"/> <field name="liste" column="liste" type="string" length="64" nullable="true" /> Loading Loading
SQL/004-evenementiel/00_schemas.sql +13 −0 Changes for SQL/004-evenementiel/00_schemas.sql: 13 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -201,6 +201,9 @@ CREATE TABLE evenementiel_inscription evenement_id INTEGER REFERENCES evenementiel_evenement (id) ON DELETE CASCADE, participant_id INTEGER REFERENCES evenementiel_participant (id) ON DELETE CASCADE, statut VARCHAR(50) DEFAULT 'inscrit', -- inscrit, annulé, en attente type_inscription VARCHAR(32) NOT NULL DEFAULT 'INDIVIDUELLE' CONSTRAINT evenementiel_inscription_type_check CHECK (type_inscription IN ('INDIVIDUELLE', 'GROUPE')), nombre_places_demandees integer default 1, nombre_places_pointees integer default 0, liste varchar(64), Loading @@ -222,6 +225,16 @@ CREATE TABLE evenementiel_inscription create unique index evenementiel_inscription_id_uindex on evenementiel_inscription (id); -- ajout du champ type inscription sur une table existante ALTER TABLE public.evenementiel_inscription ADD COLUMN type_inscription VARCHAR(32) NOT NULL DEFAULT 'INDIVIDUELLE'; ALTER TABLE public.evenementiel_inscription ADD CONSTRAINT evenementiel_inscription_type_check CHECK (type_inscription IN ('INDIVIDUELLE', 'GROUPE')); -- -- 1 ligne = 1 place pour 1 personne drop table evenementiel_inscription_place ; Loading
docker-compose.yml +0 −2 Changes for docker-compose.yml: 0 added lines, 2 removed lines. Original line number Diff line number Diff line version: '2' services: inscription_suac: container_name: inscription_suac Loading
module/Evenementiel/src/Entity/Db/Evenement.php +1 −2 Changes for module/Evenementiel/src/Entity/Db/Evenement.php: 1 added line, 2 removed lines. Original line number Diff line number Diff line Loading @@ -345,8 +345,7 @@ class Evenement implements HistoriqueAwareInterface, HasEtatsInterface, Resource public function isListePrincipaleComplete(): bool { $liste = $this->getListePrincipale(); return (count($liste) >= $this->getJauge()); return $this->getNombrePlacesDemandees() >= $this->getJauge(); } /** Fonctions pour les macros **********************************************************************************/ Loading
module/Evenementiel/src/Entity/Db/Inscription.php +24 −0 Changes for module/Evenementiel/src/Entity/Db/Inscription.php: 24 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -19,6 +19,9 @@ class Inscription implements HistoriqueAwareInterface, HasEtatsInterface, Resour const PRINCIPALE = 'principale'; const COMPLEMENTAIRE = 'complémentaire'; const TYPE_INDIVIDUELLE = 'INDIVIDUELLE'; const TYPE_GROUPE = 'GROUPE'; const ETAPE_ETUDIANT = 'ETAPE_ETUDIANT'; const ETAPE_VALIDATION = 'ETAPE_VALIDATION'; const ETAPE_REFUS = 'ETAPE_REFUS'; Loading @@ -27,6 +30,7 @@ class Inscription implements HistoriqueAwareInterface, HasEtatsInterface, Resour private ?Evenement $evenement = null; private ?Participant $participant = null; private ?string $statut = null; private string $typeInscription = self::TYPE_INDIVIDUELLE; private ?int $nombrePlacesDemandees = 1; private ?int $nombrePlacesPointees = 0; private ?string $liste = null; Loading Loading @@ -83,6 +87,26 @@ class Inscription implements HistoriqueAwareInterface, HasEtatsInterface, Resour $this->statut = $statut; } public function getTypeInscription(): string { return $this->typeInscription; } public function setTypeInscription(string $typeInscription): void { $this->typeInscription = $typeInscription; } public function estIndividuelle(): bool { return $this->typeInscription === self::TYPE_INDIVIDUELLE; } public function estGroupe(): bool { return $this->typeInscription === self::TYPE_GROUPE; } public function getLibelle(): ?string { return $this->evenement?->getLibelle(); Loading
module/Evenementiel/src/Entity/Db/Mapping/Evenementiel.Entity.Db.Inscription.dcm.xml +1 −0 Changes for module/Evenementiel/src/Entity/Db/Mapping/Evenementiel.Entity.Db.Inscription.dcm.xml: 1 added line, 0 removed lines. Original line number Diff line number Diff line Loading @@ -13,6 +13,7 @@ </many-to-one> <field name="statut" column="statut" type="string" length="50" nullable="true"/> <field name="typeInscription" column="type_inscription" type="string" length="32" nullable="false"/> <field name="nombrePlacesDemandees" column="nombre_places_demandees" type="integer" nullable="false"/> <field name="nombrePlacesPointees" column="nombre_places_pointees" type="integer" nullable="false"/> <field name="liste" column="liste" type="string" length="64" nullable="true" /> Loading