Loading module/Application/src/Application/Controller/ExportController.php +22 −0 Original line number Diff line number Diff line Loading @@ -6,6 +6,7 @@ use Application\Entity\Db\Acteur; use Application\Entity\Db\Financement; use Application\Entity\Db\Role; use Application\Entity\Db\These; use Application\Entity\Db\VersionFichier; use Application\Service\FichierThese\FichierTheseServiceAwareTrait; use Application\Service\These\TheseRechercheServiceAwareTrait; use Application\Service\These\TheseServiceAwareTrait; Loading @@ -21,6 +22,8 @@ class ExportController extends AbstractController public function csvAction() { $headers = [ // Doctorant 'Civilité' => function (These $these) { return $these->getDoctorant()->getIndividu()->getCivilite(); }, Loading Loading @@ -103,6 +106,25 @@ class ExportController extends AbstractController 'Thèse format PDF' => function (These $these) { if ($these->hasMemoire()) return 'O'; else return 'N'; }, 'Annexe non PDF' => function (These $these) { if ($these->hasAnnexe()) return 'O'; else return 'N'; }, //Embargo et refus de diffusion 'Embargo' => function (These $these) { $versionCorrigee = $version = $this->fichierTheseService->fetchVersionFichier(VersionFichier::CODE_ORIG_CORR); $diffusionCorrigee = $these->getDiffusionForVersion($versionCorrigee); if ($diffusionCorrigee !== null) return $diffusionCorrigee->getAutorisEmbargoDuree(); $versionInitiale = $version = $this->fichierTheseService->fetchVersionFichier(VersionFichier::CODE_ORIG); $diffusionInitiale = $these->getDiffusionForVersion($versionInitiale); if ($diffusionInitiale !== null) return $diffusionInitiale->getAutorisEmbargoDuree(); }, 'Refus de diffusion' => function (These $these) { $versionCorrigee = $version = $this->fichierTheseService->fetchVersionFichier(VersionFichier::CODE_ORIG_CORR); $diffusionCorrigee = $these->getDiffusionForVersion($versionCorrigee); if ($diffusionCorrigee !== null) return $diffusionCorrigee->getAutorisMotif(); $versionInitiale = $version = $this->fichierTheseService->fetchVersionFichier(VersionFichier::CODE_ORIG); $diffusionInitiale = $these->getDiffusionForVersion($versionInitiale); if ($diffusionInitiale !== null) return $diffusionInitiale->getAutorisMotif(); }, ]; $queryParams = $this->params()->fromQuery(); Loading module/Application/src/Application/Controller/TheseController.php +5 −1 Original line number Diff line number Diff line Loading @@ -505,6 +505,8 @@ class TheseController extends AbstractController $validationsPdc = $this->validationService->getRepository()->findValidationByCodeAndThese(TypeValidation::CODE_PAGE_DE_COUVERTURE, $these); $pageCouvValidee = !empty($validationsPdc); $isExemplPapierFourniPertinent = $this->theseService->isExemplPapierFourniPertinent($these); $view = new ViewModel([ 'these' => $these, 'diffusion' => $these->getDiffusionForVersion($version), Loading @@ -523,6 +525,7 @@ class TheseController extends AbstractController 'hasVD' => $hasVD, 'pageCouvValidee' => $pageCouvValidee, 'asynchronous' => $asynchronous, 'isExemplPapierFourniPertinent' => $isExemplPapierFourniPertinent, ]); Loading Loading @@ -1166,11 +1169,12 @@ class TheseController extends AbstractController private function getAttestationTheseForm(VersionFichier $version) { $these = $this->requestedThese(); $diffusion = $these->getDiffusionForVersion($version); /** @var AttestationTheseForm $form */ $form = $this->getServiceLocator()->get('formElementManager')->get('AttestationTheseForm'); if (! $these->getDiffusionForVersion($version)->isRemiseExemplairePapierRequise()) { if ($diffusion && ! $diffusion->isRemiseExemplairePapierRequise()) { $form->disableExemplaireImprimeConformeAVersionDeposee(); } Loading module/Application/view/application/these/partial/rdv-bu.phtml +1 −1 Original line number Diff line number Diff line Loading @@ -59,7 +59,7 @@ $ddPageCouv = $pageCouvValidee ? $checked : $unchecked; <?php $class = ($ok = $rdvBu->getConventionMelSignee()) ? '' : 'text-danger' ?> <dd class="<?php echo $class ?>"><?php echo $ok ? $checked : $unchecked ?></dd> <?php if ($isExemplPapierFourniPertinent): ?> <?php if ($isExemplPapierFourniPertinent || $rdvBu->getExemplPapierFourni()): ?> <dt>Exemplaire papier fourni :</dt> <?php $class = ($ok = $rdvBu->getExemplPapierFourni()) ? '' : 'text-danger' ?> <dd class="<?php echo $class ?>"><?php echo $ok ? $checked : $unchecked ?></dd> Loading module/Application/view/application/these/rdv-bu.phtml +2 −3 Original line number Diff line number Diff line Loading @@ -2,14 +2,13 @@ use Application\Controller\TheseController; use Application\Entity\Db\Diffusion; use Application\Entity\Db\Repository\FichierTheseRepository; use Application\Entity\Db\These; use Application\Entity\Db\Validation; use Application\Entity\Db\WfEtape; use Application\Provider\Privilege\ThesePrivileges; use Application\Provider\Privilege\ValidationPrivileges; use Application\View\Renderer\PhpRenderer; use UnicaenApp\Service\MessageCollector; use Application\Entity\Db\Repository\FichierTheseRepository; /** * @var PhpRenderer $this Loading @@ -25,7 +24,7 @@ use Application\Entity\Db\Repository\FichierTheseRepository; * @var FichierTheseRepository $fichierRepository * @var boolean $asynchronous * * @see TheseController::modifierRdvBuAction() * @see TheseController::detailRdvBuAction() */ $canEdit = $this->isAllowed($these, ThesePrivileges::THESE_SAISIE_RDV_BU); Loading Loading
module/Application/src/Application/Controller/ExportController.php +22 −0 Original line number Diff line number Diff line Loading @@ -6,6 +6,7 @@ use Application\Entity\Db\Acteur; use Application\Entity\Db\Financement; use Application\Entity\Db\Role; use Application\Entity\Db\These; use Application\Entity\Db\VersionFichier; use Application\Service\FichierThese\FichierTheseServiceAwareTrait; use Application\Service\These\TheseRechercheServiceAwareTrait; use Application\Service\These\TheseServiceAwareTrait; Loading @@ -21,6 +22,8 @@ class ExportController extends AbstractController public function csvAction() { $headers = [ // Doctorant 'Civilité' => function (These $these) { return $these->getDoctorant()->getIndividu()->getCivilite(); }, Loading Loading @@ -103,6 +106,25 @@ class ExportController extends AbstractController 'Thèse format PDF' => function (These $these) { if ($these->hasMemoire()) return 'O'; else return 'N'; }, 'Annexe non PDF' => function (These $these) { if ($these->hasAnnexe()) return 'O'; else return 'N'; }, //Embargo et refus de diffusion 'Embargo' => function (These $these) { $versionCorrigee = $version = $this->fichierTheseService->fetchVersionFichier(VersionFichier::CODE_ORIG_CORR); $diffusionCorrigee = $these->getDiffusionForVersion($versionCorrigee); if ($diffusionCorrigee !== null) return $diffusionCorrigee->getAutorisEmbargoDuree(); $versionInitiale = $version = $this->fichierTheseService->fetchVersionFichier(VersionFichier::CODE_ORIG); $diffusionInitiale = $these->getDiffusionForVersion($versionInitiale); if ($diffusionInitiale !== null) return $diffusionInitiale->getAutorisEmbargoDuree(); }, 'Refus de diffusion' => function (These $these) { $versionCorrigee = $version = $this->fichierTheseService->fetchVersionFichier(VersionFichier::CODE_ORIG_CORR); $diffusionCorrigee = $these->getDiffusionForVersion($versionCorrigee); if ($diffusionCorrigee !== null) return $diffusionCorrigee->getAutorisMotif(); $versionInitiale = $version = $this->fichierTheseService->fetchVersionFichier(VersionFichier::CODE_ORIG); $diffusionInitiale = $these->getDiffusionForVersion($versionInitiale); if ($diffusionInitiale !== null) return $diffusionInitiale->getAutorisMotif(); }, ]; $queryParams = $this->params()->fromQuery(); Loading
module/Application/src/Application/Controller/TheseController.php +5 −1 Original line number Diff line number Diff line Loading @@ -505,6 +505,8 @@ class TheseController extends AbstractController $validationsPdc = $this->validationService->getRepository()->findValidationByCodeAndThese(TypeValidation::CODE_PAGE_DE_COUVERTURE, $these); $pageCouvValidee = !empty($validationsPdc); $isExemplPapierFourniPertinent = $this->theseService->isExemplPapierFourniPertinent($these); $view = new ViewModel([ 'these' => $these, 'diffusion' => $these->getDiffusionForVersion($version), Loading @@ -523,6 +525,7 @@ class TheseController extends AbstractController 'hasVD' => $hasVD, 'pageCouvValidee' => $pageCouvValidee, 'asynchronous' => $asynchronous, 'isExemplPapierFourniPertinent' => $isExemplPapierFourniPertinent, ]); Loading Loading @@ -1166,11 +1169,12 @@ class TheseController extends AbstractController private function getAttestationTheseForm(VersionFichier $version) { $these = $this->requestedThese(); $diffusion = $these->getDiffusionForVersion($version); /** @var AttestationTheseForm $form */ $form = $this->getServiceLocator()->get('formElementManager')->get('AttestationTheseForm'); if (! $these->getDiffusionForVersion($version)->isRemiseExemplairePapierRequise()) { if ($diffusion && ! $diffusion->isRemiseExemplairePapierRequise()) { $form->disableExemplaireImprimeConformeAVersionDeposee(); } Loading
module/Application/view/application/these/partial/rdv-bu.phtml +1 −1 Original line number Diff line number Diff line Loading @@ -59,7 +59,7 @@ $ddPageCouv = $pageCouvValidee ? $checked : $unchecked; <?php $class = ($ok = $rdvBu->getConventionMelSignee()) ? '' : 'text-danger' ?> <dd class="<?php echo $class ?>"><?php echo $ok ? $checked : $unchecked ?></dd> <?php if ($isExemplPapierFourniPertinent): ?> <?php if ($isExemplPapierFourniPertinent || $rdvBu->getExemplPapierFourni()): ?> <dt>Exemplaire papier fourni :</dt> <?php $class = ($ok = $rdvBu->getExemplPapierFourni()) ? '' : 'text-danger' ?> <dd class="<?php echo $class ?>"><?php echo $ok ? $checked : $unchecked ?></dd> Loading
module/Application/view/application/these/rdv-bu.phtml +2 −3 Original line number Diff line number Diff line Loading @@ -2,14 +2,13 @@ use Application\Controller\TheseController; use Application\Entity\Db\Diffusion; use Application\Entity\Db\Repository\FichierTheseRepository; use Application\Entity\Db\These; use Application\Entity\Db\Validation; use Application\Entity\Db\WfEtape; use Application\Provider\Privilege\ThesePrivileges; use Application\Provider\Privilege\ValidationPrivileges; use Application\View\Renderer\PhpRenderer; use UnicaenApp\Service\MessageCollector; use Application\Entity\Db\Repository\FichierTheseRepository; /** * @var PhpRenderer $this Loading @@ -25,7 +24,7 @@ use Application\Entity\Db\Repository\FichierTheseRepository; * @var FichierTheseRepository $fichierRepository * @var boolean $asynchronous * * @see TheseController::modifierRdvBuAction() * @see TheseController::detailRdvBuAction() */ $canEdit = $this->isAllowed($these, ThesePrivileges::THESE_SAISIE_RDV_BU); Loading