Arrange templates by module
[platal.git] / templates / profile / adresses.tpl
CommitLineData
0337d704 1{**************************************************************************}
2{* *}
50a40a33 3{* Copyright (C) 2003-2006 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
24<div class="blocunite_tab">
25 <table class="bicol" cellspacing="0" cellpadding="0" summary="Profil: Adresses personnelles">
26 <tr>
27 <th colspan="5">
28 Adresses personnelles
29 </th>
30 </tr>
31
32 {section name=i loop=$nb_adr start=1 max=$nb_adr}
33 {*
34 $adrid = $ordre_adrid[$i];
35 $adr = &$adresses[$adrid];
36 *}
37 {assign var='adrid' value=$ordre_adrid[i]}
38 {assign var='adr' value=$adresses.$adrid}
39 <tr>
40 <th colspan="5">
41 <a id='adr{$adrid}'></a>
42 {if $adr.nouvelle != 'new'}Adresse n°{$smarty.section.i.index}{else}Rentre ici une nouvelle adresse{/if}
43 <input type="hidden" name="adrid[{$adrid}]" value="{$adrid}" />
44 {if $adr.nouvelle == 'new'}
45 <input type="hidden" name="numero_formulaire[{$adrid}]" value="0" />
46 {else}
47 <input type="hidden" name="numero_formulaire[{$adrid}]" value="{$smarty.section.i.index}" />
48 {/if}
49 {if $adr.nouvelle != 'new'}
5ee95138 50 <a href="profile/edit/{$onglet}?adrid_del[{$adrid}]=1" style="color:inherit">{icon name=cross title="Supprimer cette adresse"}</a>
0337d704 51 {/if}
52 </th>
53 </tr>
54 {include file="include/flags.radio.tpl" name="pub[$adrid]" val=$adr.pub}
55 <tr>
56 <td class="left">
57 &nbsp;
58 </td>
59 <td colspan="4" class="right">
60 <em>c'est à cette adresse que je suis actuellement</em>
61 <input name="adrid_active" type="radio" value="{$adrid}" {if $adr.active}checked="checked"{/if} />
62 </td>
63 </tr>
64 {if $adr.nouvelle != 'new'}
65 {assign var="titre" value="Adresse n°`$smarty.section.i.index`&nbsp;:"}
66 {else}
67 {assign var="titre" value="Nouvelle adresse&nbsp;:"}
68 {/if}
42d9575b 69 {include file="geoloc/form.address.tpl" adr=$adr titre=$titre}
0337d704 70 <tr>
71 <td class="colg">
79a5acea 72 <span class="titre">Adresse:</span>
0337d704 73 </td>
a778f541 74 <td class="cold" colspan="4">
0337d704 75 <input type="radio" name="temporaire[{$adrid}]" value="0" {if !$adr.temporaire}checked="checked"{/if} />
76 permanente
77 <input type="radio" name="temporaire[{$adrid}]" value="1" {if $adr.temporaire}checked="checked"{/if} />
78 temporaire
79 </td>
80 </tr>
81 <tr>
82 <td class="colg">
83 &nbsp;
84 </td>
a778f541 85 <td class="cold" colspan="4">
0337d704 86 <input type="radio" name="secondaire[{$adrid}]" value="0" {if !$adr.secondaire}checked="checked"{/if} />
87 ma résidence principale
88 <input type="radio" name="secondaire[{$adrid}]" value="1" {if $adr.secondaire}checked="checked"{/if} />
89 une résidence secondaire
90 </td>
91 </tr>
92 <tr>
93 <td class="colg">
94 &nbsp;
95 </td>
a778f541 96 <td class="cold" colspan="4">
0337d704 97 <input type="checkbox" name="courrier[{$adrid}]" value="1" {if $adr.courrier}checked="checked"{/if} /> on peut m'y envoyer du courrier par la poste
98 </td>
99 </tr>
79a5acea 100 {foreach from=$adr.tels item="tel"}
8303b851 101 <tr class="flags">
102 <td class="colg">
103 <input type="hidden" name="telid{$tel.telid}[{$adrid}]" value="{$tel.telid}"/>
5ee95138 104 {if $tel.new_tel && !$tel.tel}
8303b851 105 <input type="hidden" name="new_tel{$tel.telid}[{$adrid}]" value="1"/>
106 {/if}
107 <span class="titre" onclick="this.style.display='none';var d = document.getElementById('tel_type{$adrid}_{$tel.telid}');d.style.display='inline';d.select();d.focus();">{$tel.tel_type}&nbsp;:</span>
e9cd41fb 108 <input id="tel_type{$adrid}_{$tel.telid}" style="display:none" type="text" size="5" maxlength="30" name="tel_type{$tel.telid}[{$adrid}]" value="{$tel.tel_type}"/>
8303b851 109 </td>
110 <td>
111 <input type="text" size="19" maxlength="28" name="tel{$tel.telid}[{$adrid}]" value="{$tel.tel}" />
5ee95138 112 {if $tel.tel}
113 <a href="profile/edit/{$onglet}?adrid={$adrid}&telid={$tel.telid}&deltel=1">{icon name=cross title="Supprimer ce tél."}</a>
114 {/if}
8303b851 115 </td>
116 {include file="include/flags.radio.tpl" name="tel_pub`$tel.telid`[$adrid]" val=$tel.tel_pub display="mini"}
117 </tr>
79a5acea 118 {/foreach}
0337d704 119 <tr><td colspan="5">&nbsp;</td></tr>
120 {/section}
121 <tr><td colspan="5">&nbsp;</td></tr>
122 </table>
123</div>
124
125{* vim:set et sw=2 sts=2 sws=2: *}