Happy New Year!
[platal.git] / templates / xnetgrp / mail.tpl
CommitLineData
0337d704 1{**************************************************************************}
2{* *}
5e1513f6 3{* Copyright (C) 2003-2011 Polytechnique.org *}
0337d704 4{* http://opensource.polytechnique.org/ *}
5{* *}
6{* This program is free software; you can redistribute it and/or modify *}
7{* it under the terms of the GNU General Public License as published by *}
8{* the Free Software Foundation; either version 2 of the License, or *}
9{* (at your option) any later version. *}
10{* *}
11{* This program is distributed in the hope that it will be useful, *}
12{* but WITHOUT ANY WARRANTY; without even the implied warranty of *}
13{* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *}
14{* GNU General Public License for more details. *}
15{* *}
16{* You should have received a copy of the GNU General Public License *}
17{* along with this program; if not, write to the Free Software *}
18{* Foundation, Inc., *}
19{* 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA *}
20{* *}
21{**************************************************************************}
22
23
34ade5a6 24<h1>{$asso->nom}&nbsp;: Envoyer un email</h1>
0337d704 25
26<p class="descr">
e8439508 27Ton message peut être personnalisé&nbsp;: si tu rentres les mots &lt;cher&gt;, &lt;prenom&gt;,
a7de4ef7 28&lt;nom&gt;, ces mots seront remplacés, pour chacun des destinataires, par "cher" accordé au
29masculin ou féminin, par son prénom, ou son nom.
0337d704 30</p>
fdbeba4f 31
32<script type="text/javascript">//<![CDATA[
33 {literal}
d2164ce7
SJ
34 function check(form)
35 {
36 if(form.sujet.value == "" && !confirm("Le sujet de l'email est vide, veux-tu continuer ?")) {
37 form.sujet.focus();
38 return false;
39 }
40 }
41
fdbeba4f 42 function updateWikiView(box) {
43 if (!box.checked) {
44 document.getElementById("preview_bt").style.display = "none";
45 document.getElementById("preview").style.display = "none";
46 } else {
47 document.getElementById("preview_bt").style.display = "";
48 }
49 }
50 {/literal}
51//]]></script>
aab2ffdd 52
d2164ce7 53<form action="{$platal->ns}mail" method="post" enctype="multipart/form-data" onsubmit="return check(this);">
e7fdf9dd 54 {xsrf_token_field}
0359898c 55 <table class='bicol'>
0337d704 56 <tr>
faefdbb7 57 <th colspan="2">Écrire un email&nbsp;:</th>
0337d704 58 </tr>
59 <tr>
e8439508 60 <td class="titre">Expéditeur&nbsp;:</td>
0337d704 61 <td>
62 <input type="text" name="from" size="55" maxlength="70"
7912097e 63 value="{if $smarty.request.from}{$smarty.request.from}{else}&quot;{$user->fullName()}&quot; &lt;{$user->bestEmail()}&gt;{/if}" />
0337d704 64 </td>
65 </tr>
9898b36e 66 <tr>
e8439508 67 <td class="titre">Répondre à&nbsp;:</td>
9898b36e 68 <td>
69 <input type="text" name="replyto" size="55" maxlength="70" value="{$smarty.request.replyto}" />
70 </td>
71 </tr>
0337d704 72
73 <tr>
74 <th colspan="2">Destinataires</th>
75 </tr>
76 <tr valign="top">
77 <td style='padding-left: 1em' class='titre'>
0359898c 78 <em>annuaire</em>
0337d704 79 </td>
80 <td>
a44f405e
SJ
81 <label><input type="checkbox" name="membres[X]" value="1" {if $smarty.request.membres.X}checked="checked"{/if} />
82 <em>écrire à tous les X de l'annuaire du groupe</em></label><br />
83 <label><input type="checkbox" name="membres[ext]" value="1" {if $smarty.request.membres.ext}checked="checked"{/if} />
84 <em>écrire à tous les extérieurs de l'annuaire du groupe</em></label><br />
85 <label><input type="checkbox" name="membres[groupe]" value="1" {if $smarty.request.membres.groupe}checked="checked"{/if} />
cd78feae 86 <em>écrire à toutes les personnes morales de l'annuaire du groupe</em></label>
06db561e 87 <a href="{$platal->ns}annuaire" class='popup'>(voir annuaire)</a><br />
0337d704 88 </td>
89 </tr>
90
91 {foreach from=$listes item=l}
92 <tr>
93 <td style='padding-left: 1em' class='titre'>
0359898c 94 {$l.list}
0337d704 95 </td>
96 <td>
a44f405e
SJ
97 <label><input type="checkbox" name="ml[{$l.list}]" value="1" {if $smarty.request.ml[$l.list]}checked="checked"{/if} />
98 {$l.addr}</label>
7b2413f6 99 <a href="{$platal->ns}lists/admin/{$l.list}" class="popup">(voir composition)</a>
0337d704 100 </td>
101 </tr>
102 {/foreach}
103
0337d704 104 <tr>
faefdbb7 105 <th colspan="2">Contenu de l'email</th>
0337d704 106 </tr>
107 <tr>
108 <td class="titre">
e8439508 109 Sujet&nbsp;:
0337d704 110 </td>
cd78feae 111 <td><input type="text" name="sujet" value="{$smarty.request.sujet}" size="55" maxlength="70" /></td>
0337d704 112 </tr>
113 <tr>
5b21237d 114 <td colspan="2" class="smaller">
cd78feae 115 <input type="checkbox" name="wiki" value="1" checked="checked" onchange="updateWikiView(this);" id="wiki_syntaxe"/>
a44f405e
SJ
116 <label for="wiki_syntaxe">activer </label><a href="wiki_help" class="popup3">la syntaxe wiki</a>
117 <label for="wiki_syntaxe">pour le formattage du message</label>
5b21237d 118 </td>
119 </tr>
fdbeba4f 120 <tr id="preview" class="pair" style="display: none">
cd78feae 121 <td colspan="2">
fdbeba4f 122 <div id="mail_preview"></div>
cd78feae 123 <div class="center"><input type="submit" name="send" value="Envoyer le message" /></div>
fdbeba4f 124 </td>
125 </tr>
5b21237d 126 <tr>
648020d2 127 <td colspan="2" class="center">
fdbeba4f 128 <textarea name="body" id="mail_text" cols="72" rows="25">
648020d2 129{if $smarty.request.body}
130{$smarty.request.body}
131{else}
132&lt;cher&gt; &lt;prenom&gt;,
fdbeba4f 133
34ade5a6 134Nous avons le plaisir de t'adresser la lettre mensuelle du groupe {$asso->nom}.
0337d704 135
6e828e47 136(insérer le texte&hellip;)
0337d704 137
34ade5a6 138Le bureau du groupe {$asso->nom}.
ccf0feca 139{/if}</textarea>
0337d704 140 </td>
141 </tr>
142 <tr>
91a14f73 143 <td class="titre">
9da274fa 144 {icon name=email_attach} Attacher un fichier
91a14f73 145 </td>
146 <td>
147 <input type="file" name="uploaded" />
148 </td>
149 </tr>
150 <tr>
fdbeba4f 151 <td colspan="2" align="center">
152 <input type="submit" name="preview" id="preview_bt" value="Aperçu" onclick="previewWiki('mail_text', 'mail_preview', true, 'preview'); return false;" />
153 <input type="submit" name="send" value="Envoyer le message" />
154 </td>
0337d704 155 </tr>
156 </table>
157</form>
158
a7de4ef7 159{* vim:set et sw=2 sts=2 sws=2 enc=utf-8: *}