Commit | Line | Data |
---|---|---|
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 | {literal} | |
4d8e2051 | 24 | <script type="text/javascript">//<![CDATA[ |
555fde86 | 25 | function chgMainWinLoc(strPage) |
26 | { | |
63c89179 | 27 | strPage = $.plURL(strPage); |
2c326273 | 28 | if (parent.opener) { |
007c44cb | 29 | try { |
30 | parent.opener.document.location = strPage; | |
31 | window.close(); | |
32 | } catch(e) { | |
33 | window.open(strPage); | |
34 | } | |
2c326273 | 35 | } else { |
36 | document.location = strPage; | |
37 | } | |
0337d704 | 38 | } |
0c9edc89 FB |
39 | |
40 | $($.closeOnEsc); | |
41 | ||
4d8e2051 | 42 | //]]></script> |
0337d704 | 43 | {/literal} |
03a6316f | 44 | <div id="fiche"> |
45 | <div id="photo" class="part"> | |
68f988a8 | 46 | {assign var=photo value=$profile->getPhoto(false)} |
7e019d24 | 47 | {if $photo}<img alt="Photo de {$profile->fullName()}" src="photo/{$profile->hrid()}{if $with_pending_pic}/req{/if}" width="{$photo->width()}"/>{/if} |
5f8ad70d | 48 | |
22771578 | 49 | {if $logged && $view->isVisible(#Visibility::EXPORT_AX#) && ( $profile->section|smarty:nodefaults || $profile->getBinets()|smarty:nodefaults || ($owner && $owner->groups(true,true)|smarty:nodefaults))} |
6e828e47 | 50 | <h2>À l'X…</h2> |
68f988a8 | 51 | {if $profile->section}<div><em class="intitule">Section : </em><span>{$profile->section}</span></div>{/if} |
5f8ad70d | 52 | |
7f3c6bf4 | 53 | {assign var=binets value=$profile->getFullBinets()} |
5f8ad70d | 54 | {if $binets|@count}<div><em class="intitule">Binet{if count($binets) > 1}s{/if} : </em> |
7f3c6bf4 TM |
55 | <span> <br /> |
56 | {foreach from=$binets item=binet name=binets} | |
57 | {if !$smarty.foreach.binets.first}, {/if} | |
58 | <span title="{$binet.text}">{if $binet.url}<a href="{$binet.url}">{/if}{$binet.text}{if $binet.url}</a>{/if}</span> | |
59 | {/foreach} | |
60 | </span></div>{/if} | |
5f8ad70d | 61 | |
22771578 | 62 | {if $owner && $view->isVisible(#Visibility::EXPORT_AX#)} |
56cd7aee | 63 | {assign var=groups value=$owner->groups(true,true)} |
5f8ad70d RB |
64 | {if $groups|@count}<div><em class="intitule">Groupe{if count($groups) > 1}s{/if} et institution{if count($groups) > 1}s{/if} X : </em> |
65 | <span><br/> | |
c3a9fa2b SJ |
66 | {foreach from=$groups item=group name=groups} |
67 | {if !$smarty.foreach.groups.first}, {/if} | |
68 | <span title="{$group.nom}"><a href="{if $group.site}{$group.site}{else}http://www.polytechnique.net/{$group.nom}{/if}">{$group.nom}</a></span> | |
69 | {/foreach} | |
5f8ad70d RB |
70 | </span></div>{/if} |
71 | {/if} | |
72 | ||
03a6316f | 73 | {/if} |
5f8ad70d | 74 | |
79270914 | 75 | {assign var=networking value=$profile->getNetworking(#Profile::NETWORKING_ALL#)} |
5f8ad70d | 76 | {if count($networking) > 0} |
92c3f9e5 | 77 | <h2>Sur le web...</h2> |
5f8ad70d | 78 | {foreach from=$networking item=network} |
1f5cd004 PC |
79 | <img style="width: auto; padding: 0" src="profile/networking/{$network.nwid}" alt="{$network.name}" title="{$network.name}"/> |
80 | {if $network.link} | |
81 | <a href="{$network.link|replace:'%s':$network.address}">{$network.address}</a> | |
d1a2252a GB |
82 | {else} |
83 | {$network.address} | |
84 | {/if} | |
85 | <br/> | |
86 | {/foreach} | |
87 | {/if} | |
5f8ad70d | 88 | |
68f988a8 | 89 | {if $profile->freetext} |
5f8ad70d | 90 | <h2>Commentaires :</h2> |
68f988a8 | 91 | <span>{$profile->freetext|miniwiki|smarty:nodefaults}</span> |
581c3341 | 92 | {/if} |
5f8ad70d | 93 | |
03a6316f | 94 | </div> |
5f8ad70d | 95 | |
03a6316f | 96 | <div id="fiche_identite" class="part"> |
97 | <div class="civilite"> | |
68f988a8 | 98 | {if $profile->isFemale()}•{/if} |
22771578 | 99 | {if $view->isVisible(#Visibility::EXPORT_PRIVATE#)}{$profile->private_name}{else}{$profile->public_name}{/if} |
5f8ad70d | 100 | |
581c3341 | 101 | {if $logged} |
68f988a8 | 102 | {if !$profile->isDead()}<a href="vcard/{$owner->login()}.vcf">{* |
5f8ad70d RB |
103 | *}{icon name=vcard title="Afficher la carte de visite"}</a>{/if} |
104 | ||
2ab391bc | 105 | {if !$smarty.session.user->isContact($profile)} |
68f988a8 | 106 | <a href="javascript:chgMainWinLoc('carnet/contacts?action=ajouter&user={$owner->login()}&token={xsrf_token}')"> |
5f8ad70d RB |
107 | {icon name=add title="Ajouter à mes contacts"}</a> |
108 | {else} | |
68f988a8 | 109 | <a href="javascript:chgMainWinLoc('carnet/contacts?action=retirer&user={$owner->login()}&token={xsrf_token}')"> |
5f8ad70d RB |
110 | {icon name=cross title="Retirer de mes contacts"}</a> |
111 | {/if} | |
112 | ||
113 | {if hasPerm('admin')} | |
68f988a8 | 114 | <a href="javascript:chgMainWinLoc('admin/user/{$owner->login()}')"> |
5f8ad70d RB |
115 | {icon name=wrench title="administrer user"}</a> |
116 | {/if} | |
117 | ||
6fbc3476 | 118 | {if $smarty.session.user->isMyProfile($profile)} |
5f8ad70d | 119 | <a href="javascript:chgMainWinLoc('profile/edit')">{icon name="user_edit" title="Modifier ma fiche"}</a> |
6fbc3476 FB |
120 | {elseif hasPerm('admin') || $smarty.session.user->canEdit($profile)} |
121 | <a href="javascript:chgMainWinLoc('profile/edit/{$profile->hrpid}')"> | |
122 | {icon name=user_edit title="modifier la fiche"} | |
123 | </a> | |
5f8ad70d | 124 | {/if} |
03a6316f | 125 | {/if} |
126 | </div> | |
5f8ad70d | 127 | |
22771578 | 128 | {if $logged && $view->isVisible(#Visibility::EXPORT_AX#) && $owner && $owner->state eq 'active'} |
03a6316f | 129 | <div class='maj'> |
130 | Fiche mise à jour<br /> | |
68f988a8 | 131 | le {$profile->last_change|date_format} |
03a6316f | 132 | </div> |
133 | {/if} | |
5f8ad70d | 134 | |
3c985c08 RB |
135 | {* 121634816 is Profile::PHONE_LINK_PROFILE | Profile::PHONE_TYPE_ANY = 0x7400000 *} |
136 | {assign var=phones value=$profile->getPhones(121634816)} | |
22771578 | 137 | {if ($logged && $view->isVisible(#Visibility::EXPORT_AX#)) || count($phones) > 0} |
03a6316f | 138 | <div class="contact"> |
22771578 | 139 | {if $logged && $view->isVisible(#Visibility::EXPORT_AX#)} |
03a6316f | 140 | <div class='email'> |
68f988a8 RB |
141 | {if $profile->isDead()} |
142 | Décédé{if $profile->isFemale()}e{/if} le {$profile->deathdate|date_format} | |
5f96fea9 | 143 | {elseif $owner && $owner->lost} |
68f988a8 RB |
144 | Ce{if $profile->isFemale()}tte{/if} camarade n'a plus d'adresse de redirection valide,<br /> |
145 | <a href="marketing/broken/{$owner->login()}" class="popup">clique ici si tu connais son adresse email !</a> | |
5f96fea9 | 146 | {elseif $owner && $owner->state != 'active'} |
03a6316f | 147 | Cette personne n'est pas inscrite à Polytechnique.org,<br /> |
68f988a8 | 148 | <a href="marketing/public/{$owner->login()}" class="popup">clique ici si tu connais son adresse email !</a> |
0337d704 | 149 | {else} |
22771578 | 150 | {if $virtualalias && $view->isVisible(#Visibility::EXPORT_PRIVATE#)} |
03a6316f | 151 | <a href="mailto:{$virtualalias}">{$virtualalias}</a><br /> |
0337d704 | 152 | {/if} |
68f988a8 RB |
153 | <a href="mailto:{$owner->bestEmail()}">{$owner->bestEmail()}</a> |
154 | {if $owner->bestEmail() neq $owner->forlifeEmail()}<br /> | |
155 | <a href="mailto:{$owner->forlifeEmail()}">{$owner->forlifeEmail()}</a> | |
c6db254a | 156 | {/if} |
0337d704 | 157 | {/if} |
158 | </div> | |
0337d704 | 159 | {/if} |
5f8ad70d | 160 | {if count($phones) > 0} |
9533d793 | 161 | <div style="float: right"> |
68f988a8 | 162 | {display_phones tels=$phones dcd=$profile->isDead()} |
9533d793 | 163 | </div> |
6261a1b5 | 164 | {/if} |
03a6316f | 165 | <div class='spacer'></div> |
166 | </div> | |
eb173bf1 SJ |
167 | {else} |
168 | <div class='spacer'></div> | |
03a6316f | 169 | {/if} |
5f8ad70d | 170 | |
03a6316f | 171 | <div class='formation'> |
6420023b SJ |
172 | {foreach from=$profile->nationalities() item=country key=code} |
173 | <img src='images/flags/{$code}.gif' alt='{$code}' height='11' title='{$country}' /> | |
5f8ad70d RB |
174 | {/foreach} |
175 | ||
d718e91c | 176 | {$profile->promo('details')} |
5f8ad70d | 177 | |
22771578 | 178 | {if $logged && $view->isVisible(#Visibility::EXPORT_AX#) && $profile->mentor_expertise} |
68f988a8 | 179 | [<a href="referent/{$profile->hrid()}" class='popup2'>Ma fiche référent</a>] |
03a6316f | 180 | {/if} |
5f8ad70d | 181 | |
bdce9ed9 | 182 | {assign var=educations value=$profile->getEducations(32)} |
5f8ad70d | 183 | {if count($educations) > 0} |
c7eac294 | 184 | <ul> |
5f8ad70d | 185 | {foreach from=$educations item=edu} |
8f3d549b | 186 | <li>{display_education edu=$edu profile=$profile full=true}</li> |
c7eac294 SJ |
187 | {/foreach} |
188 | </ul> | |
03a6316f | 189 | {/if} |
5f8ad70d | 190 | |
68f988a8 | 191 | {assign var=corps value=$profile->getCorps()} |
5f8ad70d | 192 | {if $corps && ($corps->current || $corps->original)} |
e792fdb8 | 193 | <ul> |
5f8ad70d | 194 | {if $corps->current} |
e792fdb8 RB |
195 | <li> |
196 | Corps actuel : {$corps->current_name} | |
197 | {if $corps->current_rank}({$corps->current_rank}){/if} | |
198 | </li> | |
5f8ad70d | 199 | {/if} |
e792fdb8 | 200 | {if $corps->current != $corps->original && $corps->original} |
fc6e024d | 201 | <li>Corps d'origine : {$corps->original_name}</li> |
5f8ad70d | 202 | {/if} |
e792fdb8 | 203 | </ul> |
078dc884 | 204 | {/if} |
5f8ad70d | 205 | |
03a6316f | 206 | </div> |
207 | </div> | |
5f8ad70d | 208 | |
68f988a8 | 209 | {assign var=addr value=$profile->getAddresses(3)} |
5f8ad70d | 210 | {if count($addr) > 0} |
03a6316f | 211 | <div class="part"> |
e8439508 | 212 | <h2>Contact : </h2> |
68f988a8 | 213 | {if $profile->isDead()} |
44c7ed76 SJ |
214 | {assign var=address_name value="Dernière adresse"} |
215 | {else} | |
216 | {assign var=address_name value="Adresse"} | |
217 | {/if} | |
5f8ad70d RB |
218 | {foreach from=$addr item="address" name=addresses} |
219 | {if $smarty.foreach.addresses.iteration is even} | |
6261a1b5 | 220 | {assign var=pos value="right"} |
221 | {else} | |
222 | {assign var=pos value="left"} | |
223 | {/if} | |
5f8ad70d | 224 | {if $address->hasFlag('current')} |
44c7ed76 | 225 | {include file="geoloc/address.tpl" address=$address titre_div=true titre=$address_name|@cat:" actuelle :" |
efb74b8f | 226 | for="`$profile->firstname` `$profile->lastname`" pos=$pos phones=null} |
5f8ad70d | 227 | {elseif $address->hasFlag('secondary')} |
44c7ed76 | 228 | {include file="geoloc/address.tpl" address=$address titre_div=true titre=$address_name|@cat:" secondaire :" |
efb74b8f | 229 | for="`$profile->firstname` `$profile->lastname`" pos=$pos phones=null} |
03a6316f | 230 | {else} |
44c7ed76 | 231 | {include file="geoloc/address.tpl" address=$address titre_div=true titre=$address_name|@cat:" principale :" |
efb74b8f | 232 | for="`$profile->firstname` `$profile->lastname`" pos=$pos phones=null} |
03a6316f | 233 | {/if} |
5f8ad70d | 234 | {if $smarty.foreach.addresses.iteration is even}<div class="spacer"></div>{/if} |
03a6316f | 235 | {/foreach} |
236 | </div> | |
0337d704 | 237 | {/if} |
5f8ad70d | 238 | |
68f988a8 | 239 | {assign var=jobs value=$profile->getJobs(2)} |
5f8ad70d | 240 | {if count($jobs) > 0} |
03a6316f | 241 | <div class="part"> |
e8439508 | 242 | <h2>Informations professionnelles :</h2> |
5f8ad70d | 243 | {foreach from=$jobs item="job" key="i"} |
16f20f22 | 244 | {if $i neq 0}<hr />{/if} |
5f8ad70d | 245 | {include file="include/emploi.tpl" job=$job} |
efb74b8f | 246 | {assign var=jobPhones value=$job->phones()} |
5f8ad70d | 247 | {if $job->address()} |
efb74b8f SJ |
248 | {include file="geoloc/address.tpl" address=$job->address() titre="Adresse : " for=$job->company->name pos="left" phones=$jobPhones} |
249 | {elseif $jobPhones|@count neq 0} | |
250 | {display_phones tels=$jobPhones} | |
5f8ad70d | 251 | {/if} |
16f20f22 | 252 | <div class="spacer"> </div> |
03a6316f | 253 | {/foreach} |
254 | </div> | |
0337d704 | 255 | {/if} |
5f8ad70d | 256 | |
68f988a8 | 257 | {assign var=medals value=$profile->getMedals()} |
5f8ad70d RB |
258 | {if count($medals) > 0} |
259 | <div class="part"> | |
260 | <h2>Distinctions : </h2> | |
261 | {foreach from=$medals item=m} | |
262 | <div class="medal_frame"> | |
263 | <img src="profile/medal/thumb/{$m.mid}" height="50px" alt="{$m.text}" title="{$m.text}" style='float: left;' /> | |
264 | <div class="medal_text"> | |
15d26d45 | 265 | {$m.text}{if $m.level} ({$m.level}){/if}<br />{$m.grade} |
5f8ad70d | 266 | </div> |
03a6316f | 267 | </div> |
5f8ad70d RB |
268 | {/foreach} |
269 | <div class="spacer"> </div> | |
03a6316f | 270 | </div> |
0337d704 | 271 | {/if} |
5f8ad70d | 272 | |
68f988a8 | 273 | {if $logged && $profile->cv} |
03a6316f | 274 | <div class="part"> |
e8439508 | 275 | <h2>Curriculum Vitae :</h2> |
68f988a8 | 276 | {$profile->cv|miniwiki:title|smarty:nodefaults} |
03a6316f | 277 | </div> |
0337d704 | 278 | {/if} |
5f8ad70d | 279 | |
22771578 | 280 | {if $view->level() eq #Visibility::VIEW_PUBLIC#} |
03a6316f | 281 | <div class="part"> |
581c3341 | 282 | <small> |
03a6316f | 283 | Cette fiche est publique et visible par tout internaute,<br /> |
68f988a8 | 284 | vous pouvez aussi voir <a href="profile/private/{$profile->hrid()}?display=light">celle réservée aux X</a>. |
581c3341 | 285 | </small> |
03a6316f | 286 | </div> |
22771578 | 287 | {elseif $view->level() eq #Visibility::VIEW_AX#} |
24f4c06a FB |
288 | <div class="part"> |
289 | <small> | |
290 | Cette fiche est privée et ne recense que les informations transmises à l'AX. | |
291 | </small> | |
292 | </div> | |
0337d704 | 293 | {/if} |
5f8ad70d | 294 | |
03a6316f | 295 | <div class="spacer"></div> |
296 | </div> | |
0337d704 | 297 | |
a7de4ef7 | 298 | {* vim:set et sw=2 sts=2 sws=2 enc=utf-8: *} |