1 {**************************************************************************}
3 {* Copyright (C) 2003-2010 Polytechnique.org *}
4 {* http://opensource.polytechnique.org/ *}
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. *}
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. *}
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 *}
21 {**************************************************************************}
24 <script type="text/javascript" src="javascript/jquery.jstree.js"></script>
25 {assign var=jobid value="job_"|cat:$i}
26 {assign var=jobpref value="jobs[`$i`]"}
27 {assign var=sector_text value="sector_text_"|cat:$i}
28 {assign var=sector value="sector_"|cat:$i}
29 {assign var=entreprise value="entreprise_"|cat:$i}
30 {if !hasPerm('directory_private') && ($job.pub eq 'private') && !$new}
31 {assign var=hiddenjob value=true}
33 {assign var=hiddenjob value=false}
36 <input type="hidden" name="{$jobpref}[removed]" value="0" />
37 <input type="hidden" name="{$jobpref}[new]" value="{if $new}1{else}0{/if}" />
38 <input type="hidden" name="{$jobpref}[id]" value="{$i}" />
39 <input type="hidden" name="{$jobpref}[jobid]" value="{$job.jobid}" />
40 <table id="{$jobid}_grayed" class="bicol" style="display: none; margin-bottom: 1em">
43 <div style="float: right">
44 <a href="javascript:restoreJob('{$jobid}','{$jobpref}')">{icon name=arrow_refresh title="Restaure l'emploi"}</a>
46 Restaurer l'entreprise n°{$i+1} : {if $hiddenjob}(masquée){else}<span id="{$jobid}_grayed_name"></span>{/if}
51 <table id="{$jobid}_cont" class="bicol" summary="Entreprise n°{$i+1}" style="margin-bottom: 1em">
53 <th colspan="2" style="text-align: right">
54 <div class="flags" style="float: left; text-align: left">
55 {include file="include/flags.radio.tpl" name="`$jobpref`[pub]" val=$job.pub disabled=$hiddenjob}
57 Entreprise n°{$i+1} :
60 {if !t($job.tmp_name)}
61 <input type="hidden" name="{$jobpref}[name]" value="{$job.name}" />
64 {if t($job.tmp_name)}{$job.tmp_name} <small>(en cours de validation)</small>{else}
65 <input type="text" class="enterpriseName{if t($job.name_error)} error{/if}" size="35" maxlength="100"
66 name="{$jobpref}[name]" value="{$job.name}" />
69 <a href="javascript:removeJob('{$jobid}','{$jobpref}')">
70 {icon name=cross title="Supprimer cet emploi"}
74 {if !t($job.tmp_name)}{if !t($job.name)}
75 <tr class="{$entreprise}" {if $hiddenjob}style="display: none"{/if}>
76 <td class="center" colspan="2">
77 <small>Si l'entreprise ne figure pas dans la liste,
78 <a href="javascript:addEntreprise({$i})">clique ici</a> et complète les informations la concernant.</small>
81 <tr class="{$entreprise}" style="display: none">
82 <td class="titre">Acronyme</td>
84 <input type="text" size="35" maxlength="255" name="{$jobpref}[hq_acronym]" />
87 <tr class="{$entreprise}" style="display: none">
88 <td class="titre">Page web</td>
90 <input type="text" size="35" maxlength="255" name="{$jobpref}[hq_url]" />
93 <tr class="{$entreprise}" style="display: none">
94 <td class="titre">Email de contact</td>
96 <input type="text" maxlength="60" name="{$jobpref}[hq_email]" />
99 <tr class="{$entreprise}" style="display: none">
100 <td class="titre">Adresse du siège</td>
102 <textarea name="{$jobpref}[hq_address]" cols="30" rows="4"></textarea>
105 <tr class="{$entreprise}" style="display: none">
106 <td class="titre">Téléphone</td>
108 <input type="text" maxlength="28" name="{$jobpref}[hq_fixed]" />
111 <tr class="{$entreprise}" style="display: none">
112 <td class="titre">Fax</td>
114 <input type="text" maxlength="28" name="{$jobpref}[hq_fax]" />
119 <tr class="pair" {if $hiddenjob}style="display: none"{/if}>
120 <td colspan="2" class="center" style="font-style: italic">Place dans l'entreprise</td>
122 <tr class="pair" id="{$sector_text}" {if $hiddenjob}style="display: none"{/if}>
123 <td class="titre">Mots-clefs</td>
124 <td class="job_terms">
125 <input type="text" class="term_search" size="35"/>
126 <a href="javascript:toggleJobTermsTree({$i})">{icon name="table" title="Tous les mots-clefs"}</a>
127 <script type="text/javascript">
129 $(function() {ldelim}
130 {foreach from=$job.terms item=term}
131 addJobTerm("{$i}", "{$term.jtid}", "{$term.full_name|replace:'"':'\\"'}");
133 $('#job_{$i} .term_search').autocomplete(platal_baseurl + 'profile/jobterms',
135 "formatItem" : displayJobTerm,
136 "extraParams" : {ldelim} "jobid" : "{$i}" {rdelim},
137 "width" : $('#job_{$i} .term_search').width()*2,
138 "onItemSelect" : selectJobTerm,
139 "matchSubset" : false
146 <tr class="pair" {if $hiddenjob}style="display: none"{/if}>
147 <td colspan="2" class="term_tree">
150 <tr class="pair" {if $hiddenjob}style="display: none"{/if}>
151 <td class="titre">Description</td>
153 <input type="text" size="35" maxlength="120" {if t($job.description_error)}class="error"{/if}
154 name="{$jobpref}[description]" value="{$job.description}" />
157 <tr class="pair" {if $hiddenjob}style="display: none"{/if}>
158 <td class="titre">Page perso</td>
160 <input type="text" size="35" maxlength="255" {if t($job.w_rul)}class="error"{/if}
161 name="{$jobpref}[w_url]" value="{$job.w_url}" />
164 <tr class="pair" {if $hiddenjob}style="display: none"{/if}>
166 <div style="float: left">
167 <div class="titre">Adresse</div>
169 {include file="include/flags.radio.tpl" name="`$jobpref`[w_address][pub]" val=$job.w_address.pub}
171 <div style="margin-top: 20px; clear: both">
172 {include file="geoloc/form.address.tpl" prefname="`$jobpref`[w_address]"
173 prefid=$jobid address=$job.w_address}
179 <tr class="pair" {if $hiddenjob}style="display: none"{/if}>
181 <input type="hidden" name="{$jobpref}[w_email]" value="{$job.w_email}" />
182 <input type="hidden" name="{$jobpref}[w_email_pub]" value="{$job.w_email_pub}" />
186 {include file="include/emails.combobox.tpl" name=$jobpref|cat:'[w_email]' val=$job.w_email
187 class="pair" i=$i error=$job.w_email_error prefix="w_" pub=$job.w_email_pub id=$i}
189 <tr class="pair" {if $hiddenjob}style="display: none"{/if}>
191 {foreach from=$job.w_phone key=t item=phone}
192 <div id="{"`$jobid`_w_phone_`$t`"}" style="clear: both">
193 {include file="profile/phone.tpl" prefname="`$jobpref`[w_phone]" prefid="`$jobid`_w_phone" telid=$t tel=$phone}
196 {if $job.w_phone|@count eq 0}
197 <div id="{"`$jobid`_w_phone_0"}" style="clear: both">
198 {include file="profile/phone.tpl" prefname="`$jobpref`[w_phone]" prefid="`$jobid`_w_phone" telid=0 tel=0}
201 <div id="{$jobid}_w_phone_add" class="center" style="clear: both; padding-top: 4px;">
202 <a href="javascript:addTel('{$jobid}_w_phone','{$jobpref}[w_phone]')">
203 {icon name=add title="Ajouter un numéro de téléphone"} Ajouter un numéro de téléphone
211 {* vim:set et sw=2 sts=2 sws=2 enc=utf-8: *}