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

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

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

revision 417 by nhaye, Fri Sep 21 14:32:37 2012 UTC revision 579 by nhaye, Fri Nov 2 13:36:51 2012 UTC
# Line 13  class service extends service_gen { Line 13  class service extends service_gen {
13          parent::setType($form,$maj);          parent::setType($form,$maj);
14          if ($maj < 2) {          if ($maj < 2) {
15            $form->setType('delai', 'select');            $form->setType('delai', 'select');
16                $form->setType('type_consultation', 'select');
17          }          }
18      }      }
19    
20      function setSelect(&$form, $maj,$db,$debug) {      function setSelect(&$form, $maj,$db,$debug) {
21          parent::setSelect($form, $maj,$db,$debug) ;          parent::setSelect($form, $maj, $db, $debug) ;
22          $contenu=array();          $contenu=array();
23          $contenu[0]=array('0','1','2','3',          $contenu[0]=array('0','1','2','3',
24                            '4','5','6',                            '4','5','6',
# Line 41  class service extends service_gen { Line 42  class service extends service_gen {
42                            '24 '._('mois')                            '24 '._('mois')
43                            );                            );
44          $form->setSelect("delai",$contenu);          $form->setSelect("delai",$contenu);
45            
46            $contenu=array();
47            $contenu[0]=array('avec_avis_attendu',
48                              'pour_information',
49                              'pour_conformite');
50            $contenu[1]=array(_('Avec avis attendu'),
51                              _('Pour information'),
52                              _('Pour conformite'));
53            $form->setSelect("type_consultation",$contenu);
54      }      }
55        
56        function setVal(&$form,$maj,$validation){
57    
58            if ($maj > 1){
59                //Traitement des donnĂ©es pour l'affichage du select
60                $temp = $this->val[array_search('type_consultation', array_keys($form->val))];
61                
62                if ( strcmp($temp, 'pour_information') == 0 ){
63                
64                    $temp = _('Pour information');
65                
66                }elseif( strcmp($temp, 'avec_avis_attendu') == 0 ) {
67                    
68                    $temp = _('Avec avis attendu');
69                    
70                }elseif( strcmp($temp, 'pour_conformite') == 0 ) {
71                    
72                    $temp = _('Pour conformite');
73                    
74                }
75                
76                $form->setVal('type_consultation', $temp);
77            }
78        }
79        
80        
81  }// fin classe  }// fin classe
82  ?>  ?>

Legend:
Removed from v.417  
changed lines
  Added in v.579

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26