Commit f8d68784 authored by Jean-Philippe Metivier's avatar Jean-Philippe Metivier
Browse files

test

parent e9d08b39
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -316,6 +316,7 @@ class EntretienProfessionnelController extends AbstractActionController
                'title' => "Validation de l'entretien",
                'text' => "Validation de l'entretien",
                'action' => $this->url()->fromRoute('entretien-professionnel/valider-element', ["type" => $type, "entretien" => $entityId], [], true),
                'refus' => false,
            ]);
        }
        return $vm;
@@ -479,6 +480,7 @@ class EntretienProfessionnelController extends AbstractActionController
            $form->setData($data);
            if ($form->isValid()) {
                $this->getEntretienProfessionnelObservationService()->create($observation);
                $this->getMailingService()->sendMailType("NOTIFICATION_OBSERVATION_AGENT", ['campagne' => $entretien->getCampagne(), 'entretien' => $entretien, 'mailing' => 'zzz'.$entretien->getResponsable()->getEmail()]);
            }
        }

+3 −0
Original line number Diff line number Diff line
@@ -284,6 +284,9 @@ class MailingService
                $date = $this->getDateTime()->format('d/m/Y');
                return $date;
            /** APPLICATION *******************************************************************************************/
            case 'VAR[PREECOG#nom]' :
                $lien = '<strong>PrECoG</strong>';
                return $lien;
            case 'VAR[PREECOG#lien]' :
                $lien = '<a href="' . 'https://preecog.unicaen.fr' . '">PrEECoG</a>';
                return $lien;
+1 −0
Original line number Diff line number Diff line
@@ -15,6 +15,7 @@ use Zend\Form\Form;

    let macros = [
        {title: 'Date : aujourd\'hui', description: 'Date du jour (dd/mm/yyyy)', content: 'VAR[DATE#aujourdhui]'},
        {title: 'PrEECoG : Nom', description: 'Nom de l\'application', content: 'VAR[PREECOG#nom]'},
        {title: 'PrEECoG : Lien', description: 'Lien vers l\'application', content: 'VAR[PREECOG#lien]'},
        {title: 'Campagne : année', description: 'Année de la campagne d\'entretien professionnel', content: 'VAR[CAMPAGNE#annee]'},
        {title: 'Campagne : début', description: 'Date de début de la campagne d\'entretien professionnel', content: 'VAR[CAMPAGNE#debut]'},
+12 −6
Original line number Diff line number Diff line
@@ -4,8 +4,10 @@
 * @var string $title
 * @var string $text
 * @var string $action
 * @var boolean $refus
 */

$refusable = ($refus === null OR $refus === true)
?>

<p class="lead">
@@ -18,12 +20,16 @@
                <input type="hidden" name="reponse" value="oui">
                <input type="submit" name="reponse" class="btn btn-success action" value="Valider">
            </form>
        </td><td>
        </td>
        <?php if ($refusable) : ?>
            <td>
                <form method="post" action="<?php echo $action; ?>">
                    <input type="hidden" name="reponse" value="non">
                    <input type="submit" name="reponse" class="btn btn-danger action"  value="Refuser">
                </form>
        </td></tr>
            </td>
        <?php endif; ?>
    </tr>
</table>

<script>