Loading CHANGELOG.md +1 −0 Original line number Diff line number Diff line Loading @@ -9,6 +9,7 @@ Journal des modifications - Rapport d'activité : implémentation pour les rapports de fin de contrat du même circuit de validation/avis que les annuels. - Affichage du nom complet d'un individu : choc de simplification en supprimant 2 options d'affichage dans le formatteur. - Rapport activité : augmentation à 10 min du timeout CSRF dans le formulaire de création/modification. - Possibilité de déclarer des missions d'enseignement 6.0.2 ----- Loading doc/release-notes/v6.0.3.md +98 −1 Original line number Diff line number Diff line Loading @@ -19,4 +19,101 @@ systemctl reload php8.0-fpm ## 2. Dans la base de données Néant. No newline at end of file ```postgresql -- creation de la table de stockage create table doctorant_mission_enseignement ( id serial not null constraint doctorant_mission_enseignement_pk primary key, doctorant_id integer not null constraint doctorant_mission_enseignement_doctorant_id_fk references doctorant on delete cascade, annee_univ integer not null, histo_creation timestamp default now() not null, histo_createur_id integer default 1 not null constraint doctorant_mission_enseignement_utilisateur_id_fk references utilisateur, histo_modification timestamp, histo_modificateur_id integer constraint doctorant_mission_enseignement_utilisateur_id_fk2 references utilisateur, histo_destruction timestamp, histo_destructeur_id integer constraint doctorant_mission_enseignement_utilisateur_id_fk3 references utilisateur ); -- Ajout des privilèges insert into categorie_privilege (code, libelle, ordre) values ('missionenseignement', 'Gestion des missions d''enseignement', 1000); INSERT INTO privilege (categorie_id, code, libelle, ordre) WITH d(code, lib, ordre) AS ( SELECT 'missionenseignement_visualiser', 'Visualiser les missions d''enseignement', 10 UNION SELECT 'missionenseignement_modifier', 'Ajouter/Retirer des missions d''enseignement', 20 ) SELECT cp.id, d.code, d.lib, d.ordre FROM d JOIN categorie_privilege cp ON cp.CODE = 'missionenseignement' ; -- Affectation aux profils INSERT INTO PROFIL_PRIVILEGE (PRIVILEGE_ID, PROFIL_ID) with data(categ, priv) as ( select 'missionenseignement', 'missionenseignement_visualiser' ) select p.id as PRIVILEGE_ID, profil.id as PROFIL_ID from data join PROFIL on profil.ROLE_ID in ('ADMIN_TECH', 'GEST_FORMATION', 'BDD', 'DOCTORANT', 'D', 'K', 'ADMIN', 'OBSERV', 'OBSERVATOIRE') join CATEGORIE_PRIVILEGE cp on cp.CODE = data.categ join PRIVILEGE p on p.CATEGORIE_ID = cp.id and p.code = data.priv where not exists ( select * from PROFIL_PRIVILEGE where PRIVILEGE_ID = p.id and PROFIL_ID = profil.id ) ; INSERT INTO PROFIL_PRIVILEGE (PRIVILEGE_ID, PROFIL_ID) with data(categ, priv) as ( select 'missionenseignement', 'missionenseignement_modifier' ) select p.id as PRIVILEGE_ID, profil.id as PROFIL_ID from data join PROFIL on profil.ROLE_ID in ('ADMIN_TECH', 'GEST_FORMATION', 'BDD', 'ADMIN') join CATEGORIE_PRIVILEGE cp on cp.CODE = data.categ join PRIVILEGE p on p.CATEGORIE_ID = cp.id and p.code = data.priv where not exists ( select * from PROFIL_PRIVILEGE where PRIVILEGE_ID = p.id and PROFIL_ID = profil.id ) ; -- Rebascule des privilèges depuis les profils vers les roles insert into ROLE_PRIVILEGE (ROLE_ID, PRIVILEGE_ID) select p2r.ROLE_ID, pp.PRIVILEGE_ID from PROFIL_TO_ROLE p2r join profil pr on pr.id = p2r.PROFIL_ID join PROFIL_PRIVILEGE pp on pp.PROFIL_ID = pr.id where not exists ( select * from role_privilege where role_id = p2r.role_id and privilege_id = pp.privilege_id ) ; delete from profil_privilege pp1 where exists ( select * from profil_privilege pp join profil on pp.profil_id = profil.id and role_id in ('RESP_ED', 'GEST_ED') join privilege p on pp.privilege_id = p.id where p.code in ('valider-sien', 'valider-tout', 'devalider-sien', 'devalider-tout') and pp.profil_id = pp1.profil_id and pp.privilege_id = pp1.privilege_id ); delete from ROLE_PRIVILEGE rp where not exists ( select * from PROFIL_TO_ROLE p2r join PROFIL_PRIVILEGE pp on pp.PROFIL_ID = p2r.PROFIL_ID where rp.role_id = p2r.role_id and rp.privilege_id = pp.privilege_id ); ``` No newline at end of file module/Application/view/default/confirmation.phtml 0 → 100644 +48 −0 Original line number Diff line number Diff line <?php /** * @var string $title * @var string $text * @var string $action * @var bool $justificationOui * @var bool $justificationNon */ ?> <p class="lead"> <?php echo $text; ?> </p> <table style="width: 100%;"> <tr><td style="width: 50%;"> <form method="post" action="<?php echo $action; ?>"> <input type="hidden" name="reponse" value="oui"> <?php if (isset($justificationOui) && $justificationOui === true) : ?> <label for="justification-oui"> Justification </label> <textarea id="justification-oui" name="justification-oui" style="width: 95%;" placeholder="Merci de justifier"></textarea><br/> <?php endif; ?> <input type="submit" name="reponse" class="btn btn-success action" value="Oui, je suis sûr·e"> </form> </td><td style="width: 50%;"> <form method="post" action="<?php echo $action; ?>"> <input type="hidden" name="reponse" value="non"> <?php if (isset($justificationNon) && $justificationNon === true) : ?> <label for="justification-non"> Justification </label> <textarea id="justification-non" name="justification-non" style="width: 95%;" placeholder="Merci de justifier"></textarea><br/> <?php endif; ?> <input type="submit" id="non" name="reponse" class="btn btn-danger action" value="Non, je ne veux pas"> </form> </td></tr> </table> <script> $(function() { $("input#non").click(function(e){ $('div.modal').modal('hide'); e.preventDefault(e); }); }); </script> module/Application/view/default/default-form.phtml 0 → 100644 +36 −0 Original line number Diff line number Diff line <?php /** * @var Form $form */ use Laminas\Form\Form; echo $this->form($form); ?> <script> $(document).ready(function() { tinymce.remove(); tinymce.init({ selector: '.tinymce', toolbar: 'newdocument undo redo | bold italic removeformat | bullist', resize: true, language: 'fr_FR', plugins: 'lists', statusbar: true, browser_spellcheck : true, branding: false, menu: {}, body_id: 'description', setup: function (editor) { editor.on("focusout", function () { console.log(tinymce.get('description').getContent()); $('textarea').val(tinymce.get('description').getContent()); }); } }); $('select').selectpicker(); }); </script> module/Application/view/default/message-info.phtml 0 → 100644 +17 −0 Original line number Diff line number Diff line <?php /** * @var string $title * @var string $message */ $this->headTitle($title); ?> <h1 class="page-header"> <?php echo $title; ?> </h1> <div class="lead"> <?php echo $message; ?> </div> Loading
CHANGELOG.md +1 −0 Original line number Diff line number Diff line Loading @@ -9,6 +9,7 @@ Journal des modifications - Rapport d'activité : implémentation pour les rapports de fin de contrat du même circuit de validation/avis que les annuels. - Affichage du nom complet d'un individu : choc de simplification en supprimant 2 options d'affichage dans le formatteur. - Rapport activité : augmentation à 10 min du timeout CSRF dans le formulaire de création/modification. - Possibilité de déclarer des missions d'enseignement 6.0.2 ----- Loading
doc/release-notes/v6.0.3.md +98 −1 Original line number Diff line number Diff line Loading @@ -19,4 +19,101 @@ systemctl reload php8.0-fpm ## 2. Dans la base de données Néant. No newline at end of file ```postgresql -- creation de la table de stockage create table doctorant_mission_enseignement ( id serial not null constraint doctorant_mission_enseignement_pk primary key, doctorant_id integer not null constraint doctorant_mission_enseignement_doctorant_id_fk references doctorant on delete cascade, annee_univ integer not null, histo_creation timestamp default now() not null, histo_createur_id integer default 1 not null constraint doctorant_mission_enseignement_utilisateur_id_fk references utilisateur, histo_modification timestamp, histo_modificateur_id integer constraint doctorant_mission_enseignement_utilisateur_id_fk2 references utilisateur, histo_destruction timestamp, histo_destructeur_id integer constraint doctorant_mission_enseignement_utilisateur_id_fk3 references utilisateur ); -- Ajout des privilèges insert into categorie_privilege (code, libelle, ordre) values ('missionenseignement', 'Gestion des missions d''enseignement', 1000); INSERT INTO privilege (categorie_id, code, libelle, ordre) WITH d(code, lib, ordre) AS ( SELECT 'missionenseignement_visualiser', 'Visualiser les missions d''enseignement', 10 UNION SELECT 'missionenseignement_modifier', 'Ajouter/Retirer des missions d''enseignement', 20 ) SELECT cp.id, d.code, d.lib, d.ordre FROM d JOIN categorie_privilege cp ON cp.CODE = 'missionenseignement' ; -- Affectation aux profils INSERT INTO PROFIL_PRIVILEGE (PRIVILEGE_ID, PROFIL_ID) with data(categ, priv) as ( select 'missionenseignement', 'missionenseignement_visualiser' ) select p.id as PRIVILEGE_ID, profil.id as PROFIL_ID from data join PROFIL on profil.ROLE_ID in ('ADMIN_TECH', 'GEST_FORMATION', 'BDD', 'DOCTORANT', 'D', 'K', 'ADMIN', 'OBSERV', 'OBSERVATOIRE') join CATEGORIE_PRIVILEGE cp on cp.CODE = data.categ join PRIVILEGE p on p.CATEGORIE_ID = cp.id and p.code = data.priv where not exists ( select * from PROFIL_PRIVILEGE where PRIVILEGE_ID = p.id and PROFIL_ID = profil.id ) ; INSERT INTO PROFIL_PRIVILEGE (PRIVILEGE_ID, PROFIL_ID) with data(categ, priv) as ( select 'missionenseignement', 'missionenseignement_modifier' ) select p.id as PRIVILEGE_ID, profil.id as PROFIL_ID from data join PROFIL on profil.ROLE_ID in ('ADMIN_TECH', 'GEST_FORMATION', 'BDD', 'ADMIN') join CATEGORIE_PRIVILEGE cp on cp.CODE = data.categ join PRIVILEGE p on p.CATEGORIE_ID = cp.id and p.code = data.priv where not exists ( select * from PROFIL_PRIVILEGE where PRIVILEGE_ID = p.id and PROFIL_ID = profil.id ) ; -- Rebascule des privilèges depuis les profils vers les roles insert into ROLE_PRIVILEGE (ROLE_ID, PRIVILEGE_ID) select p2r.ROLE_ID, pp.PRIVILEGE_ID from PROFIL_TO_ROLE p2r join profil pr on pr.id = p2r.PROFIL_ID join PROFIL_PRIVILEGE pp on pp.PROFIL_ID = pr.id where not exists ( select * from role_privilege where role_id = p2r.role_id and privilege_id = pp.privilege_id ) ; delete from profil_privilege pp1 where exists ( select * from profil_privilege pp join profil on pp.profil_id = profil.id and role_id in ('RESP_ED', 'GEST_ED') join privilege p on pp.privilege_id = p.id where p.code in ('valider-sien', 'valider-tout', 'devalider-sien', 'devalider-tout') and pp.profil_id = pp1.profil_id and pp.privilege_id = pp1.privilege_id ); delete from ROLE_PRIVILEGE rp where not exists ( select * from PROFIL_TO_ROLE p2r join PROFIL_PRIVILEGE pp on pp.PROFIL_ID = p2r.PROFIL_ID where rp.role_id = p2r.role_id and rp.privilege_id = pp.privilege_id ); ``` No newline at end of file
module/Application/view/default/confirmation.phtml 0 → 100644 +48 −0 Original line number Diff line number Diff line <?php /** * @var string $title * @var string $text * @var string $action * @var bool $justificationOui * @var bool $justificationNon */ ?> <p class="lead"> <?php echo $text; ?> </p> <table style="width: 100%;"> <tr><td style="width: 50%;"> <form method="post" action="<?php echo $action; ?>"> <input type="hidden" name="reponse" value="oui"> <?php if (isset($justificationOui) && $justificationOui === true) : ?> <label for="justification-oui"> Justification </label> <textarea id="justification-oui" name="justification-oui" style="width: 95%;" placeholder="Merci de justifier"></textarea><br/> <?php endif; ?> <input type="submit" name="reponse" class="btn btn-success action" value="Oui, je suis sûr·e"> </form> </td><td style="width: 50%;"> <form method="post" action="<?php echo $action; ?>"> <input type="hidden" name="reponse" value="non"> <?php if (isset($justificationNon) && $justificationNon === true) : ?> <label for="justification-non"> Justification </label> <textarea id="justification-non" name="justification-non" style="width: 95%;" placeholder="Merci de justifier"></textarea><br/> <?php endif; ?> <input type="submit" id="non" name="reponse" class="btn btn-danger action" value="Non, je ne veux pas"> </form> </td></tr> </table> <script> $(function() { $("input#non").click(function(e){ $('div.modal').modal('hide'); e.preventDefault(e); }); }); </script>
module/Application/view/default/default-form.phtml 0 → 100644 +36 −0 Original line number Diff line number Diff line <?php /** * @var Form $form */ use Laminas\Form\Form; echo $this->form($form); ?> <script> $(document).ready(function() { tinymce.remove(); tinymce.init({ selector: '.tinymce', toolbar: 'newdocument undo redo | bold italic removeformat | bullist', resize: true, language: 'fr_FR', plugins: 'lists', statusbar: true, browser_spellcheck : true, branding: false, menu: {}, body_id: 'description', setup: function (editor) { editor.on("focusout", function () { console.log(tinymce.get('description').getContent()); $('textarea').val(tinymce.get('description').getContent()); }); } }); $('select').selectpicker(); }); </script>
module/Application/view/default/message-info.phtml 0 → 100644 +17 −0 Original line number Diff line number Diff line <?php /** * @var string $title * @var string $message */ $this->headTitle($title); ?> <h1 class="page-header"> <?php echo $title; ?> </h1> <div class="lead"> <?php echo $message; ?> </div>