/[openfoncier]/trunk/sql/pgsql/consultation_tous_retours.inc.php
ViewVC logotype

Annotation of /trunk/sql/pgsql/consultation_tous_retours.inc.php

Parent Directory Parent Directory | Revision Log Revision Log


Revision 525 - (hide annotations)
Fri Oct 19 14:15:50 2012 UTC (12 years, 3 months ago) by nhaye
File size: 3333 byte(s)
Surcharge des liens de consultation vers sous-form direct

1 nhaye 509 <?php
2     //$Id$
3     //gen openMairie le 10/02/2011 20:32
4     include('../gen/sql/pgsql/consultation.inc.php');
5    
6     $champAffiche = array(
7 nhaye 525 'consultation.consultation as "'._("consultation").'"',
8 nhaye 509 'consultation.dossier as "'._("dossier").'"',
9 nhaye 525 'service.abrege as "'._("service").'"',
10 nhaye 509 'service.libelle as "'._("service").'"',
11     'to_char(consultation.date_reception ,\'DD/MM/YYYY\') as "'._("date_reception").'"',
12     'to_char(consultation.date_retour ,\'DD/MM/YYYY\') as "'._("date_retour").'"',
13     'to_char(consultation.date_limite ,\'DD/MM/YYYY\') as "'._("date_limite").'"',
14     'avis_consultation.libelle as "'._("avis_consultation").'"',
15     'CASE WHEN dossier.enjeu IS TRUE THEN \''._("Oui").'\' ELSE \''._("Non").'\' END as "'._("dossier a enjeu").'"',
16     'om_utilisateur.nom as "'._("instructeur").'"'
17     );
18    
19     $table .= "LEFT OUTER JOIN ".DB_PREFIXE."om_utilisateur
20     ON om_utilisateur.om_utilisateur=dossier.instructeur ";
21    
22     // XXX Ajouter le critere concernant la division de l'instructeur connecte
23     $selection=" WHERE consultation.lu IS FALSE";
24    
25     $tri=" ORDER BY dossier.enjeu DESC, consultation.date_retour";
26    
27     $champRecherche = array(
28     'dossier.dossier as "'._("dossier").'"',
29     'om_utilisateur.nom as "'._("instructeur").'"',
30     );
31    
32     $tab_actions['corner']['ajouter']=NULL;
33 nhaye 525 $tab_actions['left']['consulter']=array('lien' => '../spg/direct_link.php?obj=dossier&amp;action=3'.
34     '&amp;direct_field=dossier&direct_form=consultation&direct_action=3&direct_idx=',
35     'id' => '',
36 nhaye 509 'lib' => '<span class="om-icon om-icon-16 om-icon-fix consult-16" title="'._('Consulter').'">'._('Consulter').'</span>',
37     'rights' => array('list' => array($obj, $obj.'_consulter'), 'operator' => 'OR'),
38     'ordre' => 10,);
39     $tab_actions['content'] = $tab_actions['left']['consulter'];
40    
41    
42     $champs = array();
43    
44     $champs['service_abrege'] = array(
45     'table' => 'service',
46     'colonne' => 'abrege',
47     'type' => 'text',
48     'libelle' => _('Service (abrege)'));
49    
50     $champs['service'] = array(
51     'table' => 'service',
52     'colonne' => 'libelle',
53     'type' => 'text',
54     'libelle' => _('Service'));
55    
56     $champs['date_envoi'] =
57     array('colonne' => 'date_envoi',
58     'table' => 'consultation',
59     'libelle' => _('Date d\'envoi'),
60     'type' => 'date',
61     'where' => 'intervaldate');
62     $champs['date_retour'] =
63     array('colonne' => 'date_retour',
64     'table' => 'consultation',
65     'libelle' => _('Date de retour'),
66     'type' => 'date',
67     'where' => 'intervaldate');
68    
69     $champs['date_limite'] =
70     array('colonne' => 'date_limite',
71     'table' => 'consultation',
72     'libelle' => _('Date limite'),
73     'type' => 'date',
74     'where' => 'intervaldate');
75    
76     $options[] = array('type' => 'search',
77     'display' => true,
78     'advanced' => $champs,
79     'default_form' => 'advanced',
80     'absolute_object' => 'consultation');
81    
82     /**
83     * Options
84     */
85    
86     $options[] = array(
87     "type" => "condition",
88     "field" => "case consultation.lu when 't' then 'Oui' else 'Non' end",
89     "case" => array(
90     "0" => array(
91     "values" => array("Non", ),
92     "style" => "consultation_non_lue",
93     ),
94     ),
95     );
96    
97     ?>

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26