1 {% extends 'base.html' %}
3 {% block title %}RH - DAE{% endblock %}
4 {% block titre %}Ressources humaines{% endblock %}
6 Demande d'autorisation d'embauche
10 <script src=
"{{ MEDIA_URL }}js/jquery-1.5.1.min.js"
11 type=
"text/javascript"></script>
12 <script src=
"{{ MEDIA_URL }}js/jquery-ui-1.8.11.custom.min.js"
13 type=
"text/javascript"></script>
14 <link href=
"{{ MEDIA_URL }}/css/redmond/jquery-ui-1.8.11.custom.css"
18 .row {padding:
10px
0px; clear: both; display:block;}
19 .row * {float: left; margin:
0px; padding:
0px; margin-right:
4px;}
20 .row li {list-style-type: none;}
21 .underline {text-decoration: underline;}
22 .clear {display: block; clear: both;}
23 .note {text-decoration: underline; font-style: italic; margin-left:
12px;}
24 .info {font-size:
13px; font-style: italic;}
25 .noborder {border:none; margin:
0; padding;
0}
26 tr.noborder td {border:none; padding-left:
0;}
31 <h1>Demande d'autorisation de création de poste
</h1>
33 <form action=
"" method=
"post" enctype=
"multipart/form-data">
39 Poste existant : {{ poste.nom }} ({{ poste.implantation.nom }})
45 <th>{{ form.poste.label_tag }} :
<br />{{ form.poste.errors }}
</th>
46 <td>{{ form.poste }}
</td>
49 <th>{{ form.nom.label_tag }} :
<br />{{ form.nom.errors }}
</th>
50 <td>{{ form.nom }}
</td>
53 <th>{{ form.type_poste.label_tag }} :
<br />{{ form.type_poste.errors }}
</th>
54 <td>{{ form.type_poste }}
</td>
57 <th>{{ form.implantation.label_tag }} :
<br />{{ form.implantation.errors }}
</th>
58 <td>{{ form.implantation }}
</td>
61 <th>{{ form.service.label_tag }} :
<br />{{ form.service.errors }}
</th>
62 <td>{{ form.service }}
</td>
65 <th>{{ form.responsable.label_tag }} :
<br />{{ form.responsable.errors }}
</th>
66 <td>{{ form.responsable }}
</td>
77 <th>{{ form.statut_residence.label_tag }} :
<br />{{ form.statut_residence.errors }}
</th>
80 {{ form.statut_residence }}
81 {{ form.mise_a_disposition.label_tag }}
82 {{ form.mise_a_disposition.errors }}
83 {{ form.mise_a_disposition }}
88 <th>{{ form.appel.label_tag }} :
<br />{{ form.appel.errors }}
</th>
100 <h2>Durée prévue du poste
</h2>
101 <span class=
"info">Indépendamment du titulaire du poste
</span>
105 <th rowspan=
"2">Durée :
</th>
108 {{ form.date_debut }}
<br />
109 <span class=
"info">({{form.date_debut.help_text }})
</span><br />
110 {{ form.date_debut.errors }}
114 {{ form.date_fin }}
<br />
115 <span class=
"info">({{form.date_fin.help_text }})
</span><br />
116 {{ form.date_fin.errors }}
120 <td colspan=
"4" class=
"info">Pour une durée indéterminée, spécifier uniquement la date de début.
</td>
123 <th>{{ form.regime_travail.label_tag }} :
<br />{{ form.regime_travail.errors }}
</th>
125 {{ form.regime_travail }}
126 <span class=
"info">{{ form.regime_travail.help_text }}
</span>
131 {{ form.regime_travail_nb_heure_semaine.label_tag }} :
<br />
132 {{ form.regime_travail_nb_heure_semaine.errors }}
134 <td colspan=
"4">{{ form.regime_travail_nb_heure_semaine }}
</td>
141 <h2>Classement du poste
</h2>
148 <th>Valeur du point
</th>
150 <th colspan=
"2">Salaire de base
</th>
151 <th colspan=
"2">Indemnité, responsabilité (le cas échéant)
</th>
152 <th colspan=
"2">Autres
</th>
153 <th colspan=
"2">TOTAL
</th>
154 <th>Taux
> €
</th>
155 <th colspan=
"2">Conversion EUR
</th>
160 {{ form.classement_min }}
161 {{ form.classement_min.errors }}
164 {{ form.coefficient_min }}
165 {{ form.coefficient_min.errors }}
168 {{ form.valeur_point_min }}
169 {{ form.valeur_point_min.errors }}
172 {{ form.devise_min }}
173 {{ form.devise_min.errors }}
176 {{ form.salaire_min }}
177 {{ form.salaire_min.errors }}
179 <td><span class=
"devise_min_code">EUR
</span></td>
180 <td>{{ form.indemn_min }}
</td>
181 <td><span class=
"devise_min_code">EUR
</span></td>
182 <td>{{ form.autre_min }}
</td>
183 <td><span class=
"devise_min_code">EUR
</span></td>
184 <td id=
"total_min" class=
"cell-nombre">0.00</td>
185 <td><span class=
"devise_min_code">EUR
</span></td>
186 <td id=
"taux_min_euro_display">1</td>
187 <td id=
"total_min_euro" class=
"cell-nombre">0.00</td>
193 {{ form.classement_max }}
194 {{ form.classement_max.errors }}
197 {{ form.coefficient_max }}
198 {{ form.coefficient_max.errors }}
201 {{ form.valeur_point_max }}
202 {{ form.valeur_point_max.errors }}
205 {{ form.devise_max }}
206 {{ form.devise_max.errors }}
209 {{ form.salaire_max }}
210 {{ form.salaire_max.errors }}
212 <td><span class=
"devise_max_code">EUR
</span></td>
213 <td>{{ form.indemn_max }}
</td>
214 <td><span class=
"devise_max_code">EUR
</span></td>
215 <td>{{ form.autre_max }}
</td>
216 <td><span class=
"devise_max_code">EUR
</span></td>
217 <td id=
"total_max" class=
"cell-nombre">0.00</td>
218 <td><span class=
"devise_max_code">EUR
</span></td>
219 <td id=
"taux_max_euro_display">1</td>
220 <td id=
"total_max_euro" class=
"cell-nombre">0.00</td>
226 <p class=
"info">N.B Conversion en EUROS au taux de change budgétaire
</p>
229 {% comment %}{% if new %}{% endcomment %}
231 <h2>Éléments de comparaison
</h2>
232 <p class=
"info">Compléter uniquement lors de la création d'un poste
</p>
238 {{ form.devise_comparaison }}
239 {{ form.devise_comparaison.errors }}
248 <th colspan=
"2">Entreprise locale
</th>
249 <th colspan=
"2">Université
</th>
250 <th colspan=
"2">Fonction publique
</th>
251 <th colspan=
"2">ONG
</th>
252 <th colspan=
"2">Autre
</th>
256 <td>{{ form.comp_locale_min }}
</td>
257 <td><span class=
"devise_comp_code">€
</span></td>
258 <td>{{ form.comp_universite_min }}
</td>
259 <td><span class=
"devise_comp_code">€
</span></td>
260 <td>{{ form.comp_fonctionpub_min }}
</td>
261 <td><span class=
"devise_comp_code">€
</span></td>
262 <td>{{ form.comp_ong_min }}
</td>
263 <td><span class=
"devise_comp_code">€
</span></td>
264 <td>{{ form.comp_autre_min }}
</td>
265 <td><span class=
"devise_comp_code">€
</span></td>
269 <td>{{ form.comp_locale_max }}
</td>
270 <td><span class=
"devise_comp_code">€
</span></td>
271 <td>{{ form.comp_universite_max }}
</td>
272 <td><span class=
"devise_comp_code">€
</span></td>
273 <td>{{ form.comp_fonctionpub_max }}
</td>
274 <td><span class=
"devise_comp_code">€
</span></td>
275 <td>{{ form.comp_ong_max }}
</td>
276 <td><span class=
"devise_comp_code">€
</span></td>
277 <td>{{ form.comp_autre_max }}
</td>
278 <td><span class=
"devise_comp_code">€
</span></td>
283 {% comment %}{% endif %}{% endcomment %}
286 <h2>Pièces jointes
</h2>
287 <p class=
"info">Compléter uniquement lors de la création d'un poste
</p>
288 {% include
"dae/pieces.html" %}
290 <input type=
"submit" name=
"save" value=
"Sauvegarder" />
296 <table cellspacing=
"0" id=
"financing">
305 {% for fin in poste.financements.all %}
307 <td>{{ fin.get_type_display }}
</td>
308 <td>{{ fin.montant }}
</td>
314 <td>{{ fin.pourcentage }}
</td>
315 <td>{{ fin.commentaire }}
</td>
316 <td><a href=
"{% url financement poste_key fin.id %}">Modifier
</a></td>
322 Vous devez enregister ce nouveau poste avant de pouvoir spécifier
323 la ou les sources de financement.
325 Aucun financement au registre
332 <a href=
"{% url financement poste_key %}" class=
"new">
333 Ajouter une source de financement
337 <div id=
"financing-form"></div>
340 <script type=
"text/javascript">
341 $('#id_poste').change(function() {
342 window.location = '{% url poste %}/' + $(this).val();
344 $('#financing a, a.new').click(function() {
345 $('#financing-form').load($(this).attr('href') + '?ajax=
1')
355 $(document).ready(function() {
356 valeur_min = '
<input type=
"hidden" id=
"valeur_min" name=
"valeur_min" value=
"0" disabled=
"disabled">'
357 devise_min_code = '
<input type=
"hidden" id=
"devise_min_code" name=
"devise_min_code" value=
"EUR" disabled=
"disabled">'
358 taux_min_euro = '
<input type=
"hidden" id=
"taux_min_euro" name=
"taux_min_euro" value=
"1" disabled=
"disabled">'
359 $('#id_valeur_point_min').after(valeur_min)
360 $('#id_devise_min').after(devise_min_code)
361 $('#total_min_euro').after(taux_min_euro)
363 /* valeur_point, devise et taux de l'implantation par défaut */
365 implantation = $('id_implantation').val();
366 valeur_point_min = $('#id_valeur_point_min').val();
367 if (valeur_point_min == '' and implantation != '')
369 /* simuler id_valeur_point_min change */
372 /* simuler id_devise_min change */
373 devise_min = $('#id_devise_min').val();
374 url_devise_code =
"{% url dae_devise_code %}";
375 $.post(url_devise_code, {'devise':devise_min}, function(data){
376 $('#devise_min_code').val(data[
"devise_code"]);
377 $('#taux_min_euro').val(data[
"taux_euro"]);
378 $('#taux_min_euro_display').empty();
379 $('#taux_min_euro_display').text(data[
"taux_euro"]);
380 $('.devise_min_code').trigger('update_devise_min_code');
381 $('#total_min_euro').trigger('update_total_min_euro');
384 $('#total_min').trigger('update_total_min');
386 $('#total_min_euro').trigger('update_total_min_euro');
389 $('#id_coefficient_min').bind('coeff_min_modified', function(){
390 $('#id_salaire_min').trigger('update_salaire_min');
392 $('.devise_min_code').bind('update_devise_min_code', function(){
393 devise_code = $('#devise_min_code').val();
394 $('.devise_min_code').empty();
395 $('.devise_min_code').text(devise_code);
397 $('#id_salaire_min').bind('update_salaire_min', function(){
398 valeur = $('#valeur_min').val();
399 coeff = $('#id_coefficient_min').val();
400 salaire = coeff * valeur;
401 salaire = clean_float(salaire);
402 $(this).val(salaire);
403 $('#total_min').trigger('update_total_min');
405 $('#total_min').bind('update_total_min', function(){
407 salaire = $('#id_salaire_min').val();
408 indemn = $('#id_indemn_min').val();
409 autre = $('#id_autre_min').val();
410 salaire = clean_float(salaire);
411 indemn = clean_float(indemn);
412 autre = clean_float(autre);
413 total = salaire + indemn + autre;
415 $(this).text(total.toFixed(
2));
416 $('#total_min_euro').trigger('update_total_min_euro');
418 $('#total_min_euro').bind('update_total_min_euro', function(){
419 total = $('#total_min').text();
420 taux_euro = $('#taux_min_euro').val();
421 total = clean_float(total);
422 taux_euro = clean_float(taux_euro);
423 total_euro = total * taux_euro;
425 $(this).text(total_euro.toFixed(
2));
428 $('#id_coefficient_min').change(function(){
429 $(this).trigger('coeff_min_modified');
431 $('#id_classement_min').change(function() {
432 url =
"{% url dae_coefficient %}";
433 $.post(url, {'classement':$(this).val()}, function(data){
434 $('#id_coefficient_min').val(data[
"coefficient"]);
435 $('#id_coefficient_min').trigger('coeff_min_modified');
438 $('#id_valeur_point_min').change(function() {
439 url_valeur =
"{% url dae_valeur %}";
440 url_devise =
"{% url dae_devise %}";
441 min_now = $('#id_valeur_point_min').val();
442 max_now = $('#id_valeur_point_max').val();
443 $.post(url_valeur, {'valeur_point':min_now}, function(data){
444 $('#valeur_min').val(data[
"valeur"]);
445 $('#id_salaire_min').trigger('update_salaire_min');
446 $('#total_min_euro').trigger('update_total_min_euro');
448 $('#id_valeur_point_max').val(min_now);
449 $('#valeur_max').val(data[
"valeur"]);
450 $('#id_salaire_max').trigger('update_salaire_max');
451 $('#total_max_euro').trigger('update_total_max_euro');
454 $.post(url_devise, {'valeur_point':min_now}, function(data){
455 $('#id_devise_min').val(data[
"devise"]);
456 $('#devise_min_code').val(data[
"devise_code"]);
457 $('#taux_min_euro').val(data[
"taux_euro"]);
458 $('#taux_min_euro_display').empty();
459 $('#taux_min_euro_display').text(data[
"taux_euro"]);
460 $('.devise_min_code').trigger('update_devise_min_code');
461 $('#total_min_euro').trigger('update_total_min_euro');
463 $('#id_devise_max').val(data[
"devise"]);
464 $('#devise_max_code').val(data[
"devise_code"]);
465 $('#taux_max_euro').val(data[
"taux_euro"]);
466 $('#taux_max_euro_display').empty();
467 $('#taux_max_euro_display').text(data[
"taux_euro"]);
468 $('.devise_max_code').trigger('update_devise_max_code');
469 $('#total_max_euro').trigger('update_total_max_euro');
473 $('#id_devise_min').change(function(){
474 devise_min = $('#id_devise_min').val();
475 url_devise_code =
"{% url dae_devise_code %}";
476 $.post(url_devise_code, {'devise':devise_min}, function(data){
477 $('#devise_min_code').val(data[
"devise_code"]);
478 $('#taux_min_euro').val(data[
"taux_euro"]);
479 $('#taux_min_euro_display').empty();
480 $('#taux_min_euro_display').text(data[
"taux_euro"]);
481 $('.devise_min_code').trigger('update_devise_min_code');
482 $('#total_min_euro').trigger('update_total_min_euro');
485 $('#id_salaire_min').change(function(){
486 $('#total_min').trigger('update_total_min');
488 $('#id_indemn_min').change(function(){
489 $('#total_min').trigger('update_total_min');
491 $('#id_autre_min').change(function(){
492 $('#total_min').trigger('update_total_min');
496 $(document).ready(function() {
497 valeur_max = '
<input type=
"hidden" id=
"valeur_max" name=
"valeur_max" value=
"0" disabled=
"disabled">'
498 devise_max_code = '
<input type=
"hidden" id=
"devise_max_code" name=
"devise_max_code" value=
"EUR" disabled=
"disabled">'
499 taux_max_euro = '
<input type=
"hidden" id=
"taux_max_euro" name=
"taux_max_euro" value=
"1" disabled=
"disabled">'
500 $('#id_valeur_point_max').after(valeur_max)
501 $('#id_devise_max').after(devise_max_code)
502 $('#total_max_euro').after(taux_max_euro)
504 /* simuler id_devise_max change */
505 devise_max = $('#id_devise_max').val();
506 url_devise_code =
"{% url dae_devise_code %}";
507 $.post(url_devise_code, {'devise':devise_max}, function(data){
508 $('#devise_max_code').val(data[
"devise_code"]);
509 $('#taux_max_euro').val(data[
"taux_euro"]);
510 $('#taux_max_euro_display').empty();
511 $('#taux_max_euro_display').text(data[
"taux_euro"]);
512 $('.devise_max_code').trigger('update_devise_max_code');
513 $('#total_max_euro').trigger('update_total_max_euro');
516 $('#total_max').trigger('update_total_max');
518 $('#total_max_euro').trigger('update_total_max_euro');
521 $('#id_coefficient_max').bind('coeff_max_modified', function(){
522 $('#id_salaire_max').trigger('update_salaire_max');
524 $('.devise_max_code').bind('update_devise_max_code', function(){
525 devise_code = $('#devise_max_code').val();
526 $('.devise_max_code').empty();
527 $('.devise_max_code').text(devise_code);
529 $('#id_salaire_max').bind('update_salaire_max', function(){
530 valeur = $('#valeur_max').val();
531 coeff = $('#id_coefficient_max').val();
532 salaire = coeff * valeur;
533 salaire = clean_float(salaire);
534 $(this).val(salaire);
535 $('#total_max').trigger('update_total_max');
537 $('#total_max').bind('update_total_max', function(){
539 salaire = $('#id_salaire_max').val();
540 indemn = $('#id_indemn_max').val();
541 autre = $('#id_autre_max').val();
542 salaire = clean_float(salaire);
543 indemn = clean_float(indemn);
544 autre = clean_float(autre);
545 total = salaire + indemn + autre;
547 $(this).text(total.toFixed(
2));
548 $('#total_max_euro').trigger('update_total_max_euro');
550 $('#total_max_euro').bind('update_total_max_euro', function(){
551 total = $('#total_max').text();
552 taux_euro = $('#taux_max_euro').val();
553 total = clean_float(total);
554 taux_euro = clean_float(taux_euro);
555 total_euro = total * taux_euro;
557 $(this).text(total_euro.toFixed(
2));
560 $('#id_coefficient_max').change(function(){
561 $(this).trigger('coeff_max_modified');
563 $('#id_classement_max').change(function() {
564 url =
"{% url dae_coefficient %}";
565 $.post(url, {'classement':$(this).val()}, function(data){
566 $('#id_coefficient_max').val(data[
"coefficient"]);
567 $('#id_coefficient_max').trigger('coeff_max_modified');
570 $('#id_valeur_point_max').change(function() {
571 url_valeur =
"{% url dae_valeur %}";
572 url_devise =
"{% url dae_devise %}";
573 min_now = $('#id_valeur_point_min').val();
574 max_now = $('#id_valeur_point_max').val();
575 $.post(url_valeur, {'valeur_point':max_now}, function(data){
576 $('#valeur_max').val(data[
"valeur"]);
577 $('#id_salaire_max').trigger('update_salaire_max');
578 $('#total_max_euro').trigger('update_total_max_euro');
580 $('#id_valeur_point_min').val(max_now);
581 $('#valeur_min').val(data[
"valeur"]);
582 $('#id_salaire_min').trigger('update_salaire_min');
583 $('#total_min_euro').trigger('update_total_min_euro');
586 $.post(url_devise, {'valeur_point':max_now}, function(data){
587 $('#id_devise_max').val(data[
"devise"]);
588 $('#devise_max_code').val(data[
"devise_code"]);
589 $('#taux_max_euro').val(data[
"taux_euro"]);
590 $('#taux_max_euro_display').empty();
591 $('#taux_max_euro_display').text(data[
"taux_euro"]);
592 $('.devise_max_code').trigger('update_devise_max_code');
593 $('#total_max_euro').trigger('update_total_max_euro');
595 $('#id_devise_min').val(data[
"devise"]);
596 $('#devise_min_code').val(data[
"devise_code"]);
597 $('#taux_min_euro').val(data[
"taux_euro"]);
598 $('#taux_min_euro_display').empty();
599 $('#taux_min_euro_display').text(data[
"taux_euro"]);
600 $('.devise_min_code').trigger('update_devise_min_code');
601 $('#total_min_euro').trigger('update_total_min_euro');
605 $('#id_devise_max').change(function(){
606 devise_max = $('#id_devise_max').val();
607 url_devise_code =
"{% url dae_devise_code %}";
608 $.post(url_devise_code, {'devise':devise_max}, function(data){
609 $('#devise_max_code').val(data[
"devise_code"]);
610 $('#taux_max_euro').val(data[
"taux_euro"]);
611 $('#taux_max_euro_display').empty();
612 $('#taux_max_euro_display').text(data[
"taux_euro"]);
613 $('.devise_max_code').trigger('update_devise_max_code');
614 $('#total_max_euro').trigger('update_total_max_euro');
617 $('#id_salaire_max').change(function(){
618 $('#total_max').trigger('update_total_max');
620 $('#id_indemn_max').change(function(){
621 $('#total_max').trigger('update_total_max');
623 $('#id_autre_max').change(function(){
624 $('#total_max').trigger('update_total_max');
629 $(document).ready(function() {
630 devise_comp_code = '
<input type=
"hidden" id=
"devise_comp_code" name=
"devise_comp_code" value=
"EUR" disabled=
"disabled">'
631 $('#id_devise_comparaison').after(devise_comp_code)
633 /* simuler id_devise_comparaison change */
634 devise_comparaison = $('#id_devise_comparaison').val();
635 url_devise_code =
"{% url dae_devise_code %}";
636 $.post(url_devise_code, {'devise':devise_comparaison}, function(data){
637 $('#devise_comp_code').val(data[
"devise_code"]);
638 $('.devise_comp_code').trigger('update_devise_comp_code');
641 $('.devise_comp_code').bind('update_devise_comp_code', function(){
642 devise_code = $('#devise_comp_code').val();
643 $('.devise_comp_code').empty();
644 $('.devise_comp_code').text(devise_code);
646 $('#id_devise_comparaison').change(function(){
647 devise_comparaison = $('#id_devise_comparaison').val();
648 url_devise_code =
"{% url dae_devise_code %}";
649 $.post(url_devise_code, {'devise':devise_comparaison}, function(data){
650 $('#devise_comp_code').val(data[
"devise_code"]);
651 $('.devise_comp_code').trigger('update_devise_comp_code');
656 function clean_float(value){
657 if (value == undefined)
660 output = parseFloat(value);
661 output = Math.round(output*
100)/
100;