|
- <?php
-
- use yii\helpers\Html;
- use yii\bootstrap\ActiveForm;
-
- /*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
-
- $this->title = 'Envoi d\'un email à tous les utilisateurs';
-
- ?>
-
- <h1><?= Html::encode($this->title) ?></h1>
-
- <?php
-
- $form = ActiveForm::begin(['id' => 'email-masse-form','enableClientValidation' => false]); ?>
- <?= $form->field($model, 'subject') ?>
- <?= $form->field($model, 'body')->textArea(['rows' => 6]) ?>
-
- <div class="form-group">
- <label class="control-label">Envoyer à</label>
- <p>Cliquer sur les utilisateurs pour modifier leur état.<br />
- Légende : <span class="label label-default">à envoyer</span> <span class="label label-danger">ne pas envoyer</span> <span class="label label-success">envoyé</span></p>
- <div id="ids-users">
- <?php foreach($users as $u): ?>
- <a href="javascript:void(0);" class="label <?php if($u->no_mail): ?>label-danger<?php else: ?>label-default<?php endif; ?>" data-send="0" data-id="<?php echo $u->id; ?>"><?php echo Html::encode($u->prenom.' '.$u->nom); ?></a>
- <?php endforeach; ?>
- </div>
- <input name="id_user" type="hidden" value="" />
- </div>
- <br />
-
- <div class="form-group">
- <?= Html::submitButton('Envoyer', ['class' => 'btn btn-default', 'name' => 'email-masse-button']) ?>
- </div>
- <?php ActiveForm::end(); ?>
-
|