/[openfoncier]/trunk/obj/consultation.class.php
ViewVC logotype

Diff of /trunk/obj/consultation.class.php

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 584 by nhaye, Wed Oct 31 14:58:44 2012 UTC revision 585 by nhaye, Fri Nov 2 17:16:05 2012 UTC
# Line 21  class consultation extends consultation_ Line 21  class consultation extends consultation_
21      function setvalF($val) {      function setvalF($val) {
22          parent::setValF($val);          parent::setValF($val);
23          // Si un retour d'avis est modifie on passe "lu" a false          // Si un retour d'avis est modifie on passe "lu" a false
24          if($this->val[array_search("avis_consultation",$this->champs)] != $val["avis_consultation"] OR          if($this->maj==1 AND ($this->val[array_search("avis_consultation",$this->champs)] != $val["avis_consultation"] OR
25             $this->val[array_search("date_retour",$this->champs)] != $val["date_retour"] OR             $this->val[array_search("date_retour",$this->champs)] != $val["date_retour"] OR
26             $this->val[array_search("motivation",$this->champs)] != $val["motivation"] OR             $this->val[array_search("motivation",$this->champs)] != $val["motivation"] OR
27             $this->val[array_search("fichier",$this->champs)] != $val["fichier"]) {             $this->val[array_search("fichier",$this->champs)] != $val["fichier"])) {
28              $this->valF["lu"]=FALSE;              $this->valF["lu"]=FALSE;
29              $this->valF["date_retour"]=$this->dateDB(date('d/m/Y'));              $this->valF["date_retour"]=$this->dateDB(date('d/m/Y'));
30          }          }
# Line 45  class consultation extends consultation_ Line 45  class consultation extends consultation_
45                  $form->setType('lu', 'hidden');                  $form->setType('lu', 'hidden');
46                  $form->setType('date_reception', 'hidden');                  $form->setType('date_reception', 'hidden');
47              }else{   // modify              }else{   // modify
48                  $form->setType('date_envoi', 'hiddenstaticdate');                  if($this->f->isAccredited('consultation_retour_avis_service')) {
49                  $form->setType('date_limite', 'hiddenstaticdate');                      $form->setType('dossier', 'hidden');
50                  $form->setType('service', 'selecthiddenstatic');                      $form->setType('service', 'hidden');
51                  $form->setType('date_retour', 'date2');                      $form->setType('date_envoi', 'hidden');
52                  $form->setType('avis_consultation', 'select');                      $form->setType('date_retour', 'hidden');
53                  $form->setType('motivation', 'textarea');                      $form->setType('date_reception', 'hidden');
54                  $form->setType('fichier', 'upload2');                      $form->setType('date_limite', 'hidden');
                   
                 //Affichage du champ en modification pour le prifil instructeur  
                 if(!$this->f->isAccredited('consultation_modifier_lu')) {  
55                      $form->setType('lu', 'hidden');                      $form->setType('lu', 'hidden');
56                    } else {
57                        $form->setType('date_envoi', 'hiddenstaticdate');
58                        $form->setType('date_limite', 'hiddenstaticdate');
59                        $form->setType('service', 'selecthiddenstatic');
60                        $form->setType('date_retour', 'date2');
61                        $form->setType('avis_consultation', 'select');
62                        $form->setType('motivation', 'textarea');
63                        $form->setType('fichier', 'upload2');
64                        //Affichage du champ en modification pour le prifil instructeur
65                        if(!$this->f->isAccredited('consultation_modifier_lu')) {
66                            $form->setType('lu', 'hidden');
67                        }
68                  }                  }
69              }              }
70              $form->setType('dossier', 'hiddenstatic');              $form->setType('dossier', 'hiddenstatic');
71          }          }
72          $form->setType('consultation', 'hidden');          $form->setType('consultation', 'hidden');
73          //setType pour  profil service          //setType pour  profil service
         if($this->f->isAccredited('consultation_retour_avis_service')) {  
             $form->setType('dossier', 'hidden');  
             $form->setType('service', 'hidden');  
             $form->setType('date_envoi', 'hidden');  
             $form->setType('date_retour', 'hidden');  
             $form->setType('date_reception', 'hidden');  
             $form->setType('date_limite', 'hidden');  
             $form->setType('lu', 'hidden');  
         }  
74    
75      }      }
76    

Legend:
Removed from v.584  
changed lines
  Added in v.585

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26