| 1 | {**************************************************************************} |
| 2 | {* *} |
| 3 | {* Copyright (C) 2003-2006 Polytechnique.org *} |
| 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'} |
| 50 | [<a href="{$smarty.server.PHP_SELF}?old_tab={$smarty.request.old_tab}&adrid_del[{$adrid}]=1" style="color:inherit">La supprimer !</a>] |
| 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 | |
| 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` :"} |
| 66 | {else} |
| 67 | {assign var="titre" value="Nouvelle adresse :"} |
| 68 | {/if} |
| 69 | {include file="geoloc/form.address.tpl" adr=$adr titre=$titre url="`$smarty.server.PHP_SELF`?old_tab=`$smarty.request.old_tab`"} |
| 70 | <tr> |
| 71 | <td class="colg"> |
| 72 | <span class="titre">Adresse:</span> |
| 73 | </td> |
| 74 | <td class="cold"> |
| 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 | |
| 84 | </td> |
| 85 | <td class="cold"> |
| 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 | |
| 95 | </td> |
| 96 | <td class="cold"> |
| 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> |
| 100 | {foreach from=$adr.tels item="tel"} |
| 101 | <tr class="flags"> |
| 102 | <td class="colg"> |
| 103 | <input type="hidden" name="telid{$tel.telid}[{$adrid}]" value="{$tel.telid}"/> |
| 104 | {if $tel.new_tel} |
| 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} :</span> |
| 108 | <input id="tel_type{$adrid}_{$tel.telid}" style="display:none" type="text" size="5" maxlength="20" name="tel_type{$tel.telid}[{$adrid}]" value="{$tel.tel_type}"/> |
| 109 | </td> |
| 110 | <td> |
| 111 | <input type="text" size="19" maxlength="28" name="tel{$tel.telid}[{$adrid}]" value="{$tel.tel}" /> |
| 112 | </td> |
| 113 | {include file="include/flags.radio.tpl" name="tel_pub`$tel.telid`[$adrid]" val=$tel.tel_pub display="mini"} |
| 114 | </tr> |
| 115 | {/foreach} |
| 116 | <tr><td colspan="5"> </td></tr> |
| 117 | {/section} |
| 118 | <tr><td colspan="5"> </td></tr> |
| 119 | </table> |
| 120 | </div> |
| 121 | |
| 122 | {* vim:set et sw=2 sts=2 sws=2: *} |