Loading module/Evenementiel/src/Entity/Db/Inscription.php +4 −0 Changes for module/Evenementiel/src/Entity/Db/Inscription.php: 4 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -312,5 +312,9 @@ class Inscription implements HistoriqueAwareInterface, HasEtatsInterface, Resour $this->qrCodeUriPointage = $qrCodeUriPointage; } public function getLibelleType(): string { return $this->estIndividuelle() ? 'Inscription individuelle' : 'Inscription de groupe'; } } module/Evenementiel/src/Service/Notification/NotificationService.php +3 −2 Changes for module/Evenementiel/src/Service/Notification/NotificationService.php: 3 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -77,14 +77,15 @@ class NotificationService $htmlUrlPointer = ""; $qrcode = ""; if ($inscription->estGroupe()) { if ($inscription->estGroupe() && $inscription->getPlaces()->isEmpty()) { $urlPointer = $urlService->getUrlInscriptionPointage([ 'entity' => $inscription->getId(), ]); $htmlUrlPointer = $urlService->trueLink($urlPointer); $qrcode = $this->getQrcodeService()->generateQrcodeImgTag($urlPointer, 'Inscription groupe'); } else { // urls pointage par place // URL et QR code de pointage pour chaque place, y compris pour // une inscription de groupe qui possède des places nominatives. foreach ($inscription->getPlaces() as $place) { /** @var InscriptionPlace $place */ $urlPointer = $urlService->getUrlInscriptionPointage( Loading module/Evenementiel/src/View/Helper/InscriptionPlaces.php +29 −3 Changes for module/Evenementiel/src/View/Helper/InscriptionPlaces.php: 29 added lines, 3 removed lines. Original line number Diff line number Diff line Loading @@ -34,15 +34,41 @@ class InscriptionPlaces extends AbstractHelper /** @var Inscription $inscription */ $e = $this->getView()->plugin('escapeHtml'); if ($inscription->estGroupe()) { return ''; $html = '<div class="inscription-groupe-pointage">' . '<span class="libelle-groupe">' . $e($inscription->getLibelleType()) . '</span> '; if ($canPointerInscription) { if ($inscription->getNombrePlacesPointees() < $inscription->getNombrePlacesDemandees()) { $html .= '<a class="btn btn-success action js-retour-link" href="' . $this->getView()->url('evenementiel/inscription/pointer', [ 'entity' => $inscription->getId(), ], true) . '"><span class="icon icon-checked" title="Pointer une place">' . ' Pointer une place</span></a> '; } if ($inscription->getNombrePlacesPointees() > 0) { $html .= '<a class="btn btn-danger action js-retour-link" href="' . $this->getView()->url('evenementiel/inscription/depointer', [ 'entity' => $inscription->getId(), ], true) . '"><span class="icon icon-unchecked" title="Dépointer une place">' . ' Dépointer une place</span></a>'; } } $html .= '</div>'; return $html; } $emptyText = $options['empty_text'] ?? 'Les places ne sont pas renseignées'; $listClass = $options['list_class'] ?? 'liste-places'; $e = $this->getView()->plugin('escapeHtml'); $places = $inscription->getPlaces(); // 1) Nombre de places (texte déjà formaté par l’entité) Loading module/Evenementiel/src/View/Helper/QrCodeHtmlViewHelper.php +9 −1 Changes for module/Evenementiel/src/View/Helper/QrCodeHtmlViewHelper.php: 9 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -21,7 +21,15 @@ class QrCodeHtmlViewHelper extends AbstractHelper return $this->getQrcodeService()->generateQrcodeImgTag($urlPointer); */ // urls pointage par place // Une inscription de groupe sans places possède un QR code global. if ($inscription->estGroupe() && $inscription->getPlaces()->isEmpty()) { $urlPointer = $this->getUrlService()->getUrlInscriptionPointage([ 'entity' => $inscription->getId(), ]); return $this->getQrcodeService()->generateQrcodeImgTag($urlPointer, 'Inscription groupe'); } // URL et QR code de pointage pour chaque place. $qrcode = ""; foreach ($inscription->getPlaces() as $place) { /** @var InscriptionPlace $place */ Loading module/Qr/src/Controller/ScanController.php +4 −3 Changes for module/Qr/src/Controller/ScanController.php: 4 added lines, 3 removed lines. Original line number Diff line number Diff line Loading @@ -99,10 +99,11 @@ class ScanController extends AbstractActionController ]); } // TODO à revoir suite à l'utilisation que de place pointéee if(!$inscriptionPlace) // Une inscription individuelle doit être liée à une place précise. // Une inscription de groupe utilise en revanche un QR code unique, // sans identifiant de place : le pointage porte alors sur le groupe. if (!$inscriptionPlace && (!$inscription->estGroupe() || $idPlace !== null)) { // Inscription historisé return new JsonModel([ 'ok' => false , 'status' => 'err' Loading Loading
module/Evenementiel/src/Entity/Db/Inscription.php +4 −0 Changes for module/Evenementiel/src/Entity/Db/Inscription.php: 4 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -312,5 +312,9 @@ class Inscription implements HistoriqueAwareInterface, HasEtatsInterface, Resour $this->qrCodeUriPointage = $qrCodeUriPointage; } public function getLibelleType(): string { return $this->estIndividuelle() ? 'Inscription individuelle' : 'Inscription de groupe'; } }
module/Evenementiel/src/Service/Notification/NotificationService.php +3 −2 Changes for module/Evenementiel/src/Service/Notification/NotificationService.php: 3 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -77,14 +77,15 @@ class NotificationService $htmlUrlPointer = ""; $qrcode = ""; if ($inscription->estGroupe()) { if ($inscription->estGroupe() && $inscription->getPlaces()->isEmpty()) { $urlPointer = $urlService->getUrlInscriptionPointage([ 'entity' => $inscription->getId(), ]); $htmlUrlPointer = $urlService->trueLink($urlPointer); $qrcode = $this->getQrcodeService()->generateQrcodeImgTag($urlPointer, 'Inscription groupe'); } else { // urls pointage par place // URL et QR code de pointage pour chaque place, y compris pour // une inscription de groupe qui possède des places nominatives. foreach ($inscription->getPlaces() as $place) { /** @var InscriptionPlace $place */ $urlPointer = $urlService->getUrlInscriptionPointage( Loading
module/Evenementiel/src/View/Helper/InscriptionPlaces.php +29 −3 Changes for module/Evenementiel/src/View/Helper/InscriptionPlaces.php: 29 added lines, 3 removed lines. Original line number Diff line number Diff line Loading @@ -34,15 +34,41 @@ class InscriptionPlaces extends AbstractHelper /** @var Inscription $inscription */ $e = $this->getView()->plugin('escapeHtml'); if ($inscription->estGroupe()) { return ''; $html = '<div class="inscription-groupe-pointage">' . '<span class="libelle-groupe">' . $e($inscription->getLibelleType()) . '</span> '; if ($canPointerInscription) { if ($inscription->getNombrePlacesPointees() < $inscription->getNombrePlacesDemandees()) { $html .= '<a class="btn btn-success action js-retour-link" href="' . $this->getView()->url('evenementiel/inscription/pointer', [ 'entity' => $inscription->getId(), ], true) . '"><span class="icon icon-checked" title="Pointer une place">' . ' Pointer une place</span></a> '; } if ($inscription->getNombrePlacesPointees() > 0) { $html .= '<a class="btn btn-danger action js-retour-link" href="' . $this->getView()->url('evenementiel/inscription/depointer', [ 'entity' => $inscription->getId(), ], true) . '"><span class="icon icon-unchecked" title="Dépointer une place">' . ' Dépointer une place</span></a>'; } } $html .= '</div>'; return $html; } $emptyText = $options['empty_text'] ?? 'Les places ne sont pas renseignées'; $listClass = $options['list_class'] ?? 'liste-places'; $e = $this->getView()->plugin('escapeHtml'); $places = $inscription->getPlaces(); // 1) Nombre de places (texte déjà formaté par l’entité) Loading
module/Evenementiel/src/View/Helper/QrCodeHtmlViewHelper.php +9 −1 Changes for module/Evenementiel/src/View/Helper/QrCodeHtmlViewHelper.php: 9 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -21,7 +21,15 @@ class QrCodeHtmlViewHelper extends AbstractHelper return $this->getQrcodeService()->generateQrcodeImgTag($urlPointer); */ // urls pointage par place // Une inscription de groupe sans places possède un QR code global. if ($inscription->estGroupe() && $inscription->getPlaces()->isEmpty()) { $urlPointer = $this->getUrlService()->getUrlInscriptionPointage([ 'entity' => $inscription->getId(), ]); return $this->getQrcodeService()->generateQrcodeImgTag($urlPointer, 'Inscription groupe'); } // URL et QR code de pointage pour chaque place. $qrcode = ""; foreach ($inscription->getPlaces() as $place) { /** @var InscriptionPlace $place */ Loading
module/Qr/src/Controller/ScanController.php +4 −3 Changes for module/Qr/src/Controller/ScanController.php: 4 added lines, 3 removed lines. Original line number Diff line number Diff line Loading @@ -99,10 +99,11 @@ class ScanController extends AbstractActionController ]); } // TODO à revoir suite à l'utilisation que de place pointéee if(!$inscriptionPlace) // Une inscription individuelle doit être liée à une place précise. // Une inscription de groupe utilise en revanche un QR code unique, // sans identifiant de place : le pointage porte alors sur le groupe. if (!$inscriptionPlace && (!$inscription->estGroupe() || $idPlace !== null)) { // Inscription historisé return new JsonModel([ 'ok' => false , 'status' => 'err' Loading