Split merge_issues.php into two to fix merges faster.
[platal.git] / templates / profile / jobs.job.tpl
CommitLineData
0337d704 1{**************************************************************************}
2{* *}
9f5bd98e 3{* Copyright (C) 2003-2010 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
237f662f 23
3ac45f10 24<script type="text/javascript" src="javascript/jquery.jstree.js"></script>
541e8d03 25{assign var=jobid value="job_"|cat:$i}
37d44b3b 26{assign var=jobpref value="jobs[`$i`]"}
b814a8b8
SJ
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}
237f662f
FB
30{if !hasPerm('directory_private') && ($job.pub eq 'private') && !$new}
31{assign var=hiddenjob value=true}
32{else}
33{assign var=hiddenjob value=false}
34{/if}
2dcac0f5
FB
35<div id="{$jobid}">
36 <input type="hidden" name="{$jobpref}[removed]" value="0" />
37 <input type="hidden" name="{$jobpref}[new]" value="{if $new}1{else}0{/if}" />
afaa2cc7
SJ
38 <input type="hidden" name="{$jobpref}[id]" value="{$i}" />
39 <input type="hidden" name="{$jobpref}[jobid]" value="{$job.jobid}" />
2dcac0f5
FB
40 <table id="{$jobid}_grayed" class="bicol" style="display: none; margin-bottom: 1em">
41 <tr>
42 <th class="grayed">
43 <div style="float: right">
9fce7016 44 <a href="javascript:restoreJob('{$jobid}','{$jobpref}')">{icon name=arrow_refresh title="Restaure l'emploi"}</a>
77842972 45 </div>
237f662f 46 Restaurer l'entreprise n°{$i+1}&nbsp;:&nbsp;{if $hiddenjob}(masquée){else}<span id="{$jobid}_grayed_name"></span>{/if}
2dcac0f5
FB
47 </th>
48 </tr>
49 </table>
afaa2cc7 50
2dcac0f5
FB
51 <table id="{$jobid}_cont" class="bicol" summary="Entreprise n°{$i+1}" style="margin-bottom: 1em">
52 <tr>
53 <th colspan="2" style="text-align: right">
54 <div class="flags" style="float: left; text-align: left">
237f662f 55 {include file="include/flags.radio.tpl" name="`$jobpref`[pub]" val=$job.pub disabled=$hiddenjob}
77842972 56 </div>
4f06d57b 57 Entreprise n°{$i+1}&nbsp;:
237f662f
FB
58 {if $hiddenjob}
59 (masquée)
60 {if !$job.tmp_name}
61 <input type="hidden" name="{$jobpref}[name]" value="{$job.name}" />
62 {/if}
63 {else}
b814a8b8 64 {if $job.tmp_name}{$job.tmp_name} <small>(en cours de validation)</small>{else}
d1d01361 65 <input type="text" class="enterpriseName{if $job.name_error} error{/if}" size="35" maxlength="100"
c7139c07 66 name="{$jobpref}[name]" value="{$job.name}" />
b814a8b8 67 {/if}
237f662f 68 {/if}
9fce7016 69 <a href="javascript:removeJob('{$jobid}','{$jobpref}')">
4f06d57b
SJ
70 {icon name=cross title="Supprimer cet emploi"}
71 </a>
72 </th>
b814a8b8 73 </tr>
afaa2cc7 74 {if !$job.tmp_name && !$job.name}
237f662f 75 <tr class="{$entreprise}" {if $hiddenjob}style="display: none"{/if}>
b814a8b8 76 <td class="center" colspan="2">
237f662f 77 <small>Si l'entreprise ne figure pas dans la liste,
b814a8b8
SJ
78 <a href="javascript:addEntreprise({$i})">clique ici</a> et complète les informations la concernant.</small>
79 </td>
80 </tr>
b814a8b8
SJ
81 <tr class="{$entreprise}" style="display: none">
82 <td class="titre">Acronyme</td>
83 <td>
ea9cfc3e 84 <input type="text" size="35" maxlength="255" name="{$jobpref}[hq_acronym]" />
b814a8b8
SJ
85 </td>
86 </tr>
87 <tr class="{$entreprise}" style="display: none">
4f06d57b 88 <td class="titre">Page web</td>
b814a8b8 89 <td>
ea9cfc3e 90 <input type="text" size="35" maxlength="255" name="{$jobpref}[hq_url]" />
b814a8b8
SJ
91 </td>
92 </tr>
93 <tr class="{$entreprise}" style="display: none">
94 <td class="titre">Email de contact</td>
95 <td>
ea9cfc3e 96 <input type="text" maxlength="60" name="{$jobpref}[hq_email]" />
b814a8b8
SJ
97 </td>
98 </tr>
0bcc8717 99 <tr class="{$entreprise}" style="display: none">
ea9cfc3e
SJ
100 <td class="titre">Adresse du siège</td>
101 <td>
102 <textarea name="{$jobpref}[hq_address]" cols="30" rows="4"></textarea>
b814a8b8 103 </td>
0bcc8717 104 </tr>
b814a8b8
SJ
105 <tr class="{$entreprise}" style="display: none">
106 <td class="titre">Téléphone</td>
107 <td>
ea9cfc3e 108 <input type="text" maxlength="28" name="{$jobpref}[hq_fixed]" />
b814a8b8
SJ
109 </td>
110 </tr>
111 <tr class="{$entreprise}" style="display: none">
112 <td class="titre">Fax</td>
113 <td>
ea9cfc3e 114 <input type="text" maxlength="28" name="{$jobpref}[hq_fax]" />
37d44b3b 115 </td>
2dcac0f5 116 </tr>
ea9cfc3e 117 {/if}
c7139c07 118
237f662f
FB
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>
c7139c07 121 </tr>
f4da867a 122 <tr class="pair" id="{$sector_text}" {if $hiddenjob}style="display: none"{/if}>
3ac45f10
PC
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">
128 /* <![CDATA[ */
129 $(function() {ldelim}
130 {foreach from=$job.terms item=term}
131 addJobTerm("{$i}", "{$term.jtid}", "{$term.full_name|replace:'"':'\\"'}");
132 {/foreach}
133 $('#job_{$i} .term_search').autocomplete(platal_baseurl + 'profile/jobterms',
134 {ldelim}
135 "formatItem" : displayJobTerm,
136 "extraParams" : {ldelim} "jobid" : "{$i}" {rdelim},
137 "width" : $('#job_{$i} .term_search').width()*2,
138 "onItemSelect" : selectJobTerm,
139 "matchSubset" : false
140 {rdelim});
141 {rdelim});
142 /* ]]> */
143 </script>
144 </td>
145 </tr>
237f662f 146 <tr class="pair" {if $hiddenjob}style="display: none"{/if}>
3ac45f10 147 <td colspan="2" class="term_tree">
c7139c07
SJ
148 </td>
149 </tr>
237f662f 150 <tr class="pair" {if $hiddenjob}style="display: none"{/if}>
c7139c07
SJ
151 <td class="titre">Description</td>
152 <td>
153 <input type="text" size="35" maxlength="120" {if $job.description_error}class="error"{/if}
541e8d03 154 name="{$jobpref}[description]" value="{$job.description}" />
30c895be
SJ
155 </td>
156 </tr>
237f662f 157 <tr class="pair" {if $hiddenjob}style="display: none"{/if}>
0bcc8717
SJ
158 <td class="titre">Page&nbsp;perso</td>
159 <td>
541e8d03
SJ
160 <input type="text" size="35" maxlength="255" {if $job.w_rul}class="error"{/if}
161 name="{$jobpref}[w_url]" value="{$job.w_url}" />
0bcc8717
SJ
162 </td>
163 </tr>
237f662f 164 <tr class="pair" {if $hiddenjob}style="display: none"{/if}>
2dcac0f5
FB
165 <td colspan="2">
166 <div style="float: left">
167 <div class="titre">Adresse</div>
168 <div class="flags">
541e8d03 169 {include file="include/flags.radio.tpl" name="`$jobpref`[w_address][pub]" val=$job.w_address.pub}
2dcac0f5
FB
170 </div>
171 <div style="margin-top: 20px; clear: both">
541e8d03
SJ
172 {include file="geoloc/form.address.tpl" prefname="`$jobpref`[w_address]"
173 prefid=$jobid address=$job.w_address}
2dcac0f5 174 </div>
77842972 175 </div>
bde2be3b
GB
176 </td>
177 </tr>
237f662f
FB
178 {if $hiddenjob}
179 <tr class="pair" {if $hiddenjob}style="display: none"{/if}>
180 <td colspan="2">
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}" />
183 </td>
184 </tr>
185 {else}
0bcc8717
SJ
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}
237f662f
FB
188 {/if}
189 <tr class="pair" {if $hiddenjob}style="display: none"{/if}>
bde2be3b 190 <td colspan="2">
541e8d03
SJ
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}
bde2be3b
GB
194 </div>
195 {/foreach}
541e8d03
SJ
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}
2dcac0f5 199 </div>
bde2be3b 200 {/if}
541e8d03 201 <div id="{$jobid}_w_phone_add" class="center" style="clear: both; padding-top: 4px;">
9fce7016 202 <a href="javascript:addTel('{$jobid}_w_phone','{$jobpref}[w_phone]')">
bde2be3b
GB
203 {icon name=add title="Ajouter un numéro de téléphone"} Ajouter un numéro de téléphone
204 </a>
2dcac0f5
FB
205 </div>
206 </td>
207 </tr>
208 </table>
209</div>
0337d704 210
a7de4ef7 211{* vim:set et sw=2 sts=2 sws=2 enc=utf-8: *}