/[openfoncier]/branches/3.14.x/obj/bible.class.php
ViewVC logotype

Diff of /branches/3.14.x/obj/bible.class.php

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

revision 3 by fraynaud, Thu Feb 10 20:46:18 2011 UTC revision 4 by fraynaud, Thu Feb 10 22:02:08 2011 UTC
# Line 5  require_once ("../gen/obj/bible.class.ph Line 5  require_once ("../gen/obj/bible.class.ph
5    
6  class bible extends bible_gen {  class bible extends bible_gen {
7    
8  function bible($id,&$db,$debug) {      function bible($id,&$db,$debug) {
9          $this->constructeur($id,$db,$debug);          $this->constructeur($id,$db,$debug);
10  }// fin constructeur      }// fin constructeur
11        
12        function verifier($val,&$db,$DEBUG) {
13            parent::verifier($val,$db,$DEBUG);
14            $f="&nbsp!    ";
15            $imgv="<img src='../img/punaise.png' style='vertical-align:middle' hspace='2' border='0'>";
16            if ($this->valF['contenu']==""){
17               $this->correct=false;
18               $this->msg= $this->msg.$imgv.
19                        $this->lang("contenu")."&nbsp;".
20                        $this->lang("obligatoire").$f;
21            }
22        }
23    
24        function setType(&$form,$maj) {
25            parent::setType($form,$maj);
26            if ($maj < 2) {
27                $form->setType('evenement', 'hiddenstatic');
28                $form->setType('complement', 'select');
29                $form->setType('automatique', 'select');
30                if ($maj==1){
31                   $form->setType('bible', 'hiddenstatic');
32            }else
33                $form->setType('bible', 'hidden');
34            }
35        }
36        
37        function setSelect(&$form, $maj,&$db,$debug) {
38            parent::setSelect($form, $maj,$db,$debug);
39            // complement
40            $contenu=array();
41            $contenu[0]=array('1','2','3','4','5','6','7','8','9','10','11');
42            $contenu[1]=array($this->lang('complement').' 1',
43                              $this->lang('complement').' 2',
44                              $this->lang('complement').' 3',
45                              $this->lang('complement').' 4',
46                              $this->lang('complement').' 5',
47                              $this->lang('complement').' 6',
48                              $this->lang('complement').' 7',
49                              $this->lang('complement').' 8',
50                              $this->lang('complement').' 9',
51                              $this->lang('complement').' 10',
52                              $this->lang('complement').' 11',
53                               );
54            $form->setSelect("complement",$contenu);
55            // automatique
56            $contenu=array();
57            $contenu[0]=array('Non','Oui');
58            $contenu[1]=array($this->lang('Non'),$this->lang('Oui'));
59            $form->setSelect("automatique",$contenu);
60        }
61    
62    
63  }// fin classe  }// fin classe
64  ?>  ?>

Legend:
Removed from v.3  
changed lines
  Added in v.4

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26