1 |
fraynaud |
339 |
<?php |
2 |
|
|
//$Id$ |
3 |
|
|
//gen openMairie le 27/06/2012 11:37 |
4 |
|
|
require_once ("../gen/obj/om_sig_map_wms.class.php"); |
5 |
|
|
|
6 |
|
|
class om_sig_map_wms extends om_sig_map_wms_gen { |
7 |
|
|
|
8 |
|
|
function om_sig_map_wms($id,&$db,$debug) { |
9 |
|
|
$this->constructeur($id,$db,$debug); |
10 |
|
|
}// fin constructeur |
11 |
|
|
function setType(&$form,$maj) { |
12 |
|
|
parent::setType($form,$maj); |
13 |
|
|
if($maj<2){ |
14 |
|
|
$form->setType('om_sig_wms','select'); |
15 |
|
|
$form->setType('om_sig_map', 'hidden'); |
16 |
|
|
$form->setType('visibility', 'checkbox'); |
17 |
|
|
$form->setType('panier', 'checkbox'); |
18 |
|
|
$form->setType('pa_type_geometrie','select'); |
19 |
|
|
} |
20 |
|
|
} |
21 |
|
|
|
22 |
|
|
function verifier($val = array(), &$db = NULL, $DEBUG = false) { |
23 |
|
|
// On appelle la methode de la classe parent |
24 |
|
|
parent::verifier($val, $db, $DEBUG); |
25 |
|
|
// On verifie si le champ n'est pas vide |
26 |
|
|
if ($this->valF['om_sig_wms']==""){ |
27 |
|
|
$this->msg= $this->msg." choix flux WMS obligatoire"; |
28 |
|
|
$this->correct=False; |
29 |
|
|
} |
30 |
|
|
if ($this->valF['ol_map']==""){ |
31 |
|
|
$this->msg= $this->msg." nom map OpenLayer obligatoire"; |
32 |
|
|
$this->correct=False; |
33 |
|
|
} |
34 |
|
|
if ($this->valF['ordre']==""){ |
35 |
|
|
$this->msg= $this->msg." ordre obligatoire"; |
36 |
|
|
$this->correct=False; |
37 |
|
|
} |
38 |
|
|
} |
39 |
|
|
|
40 |
|
|
function setTaille(&$form,$maj) { |
41 |
|
|
parent::setTaille($form,$maj); |
42 |
|
|
//taille des champs affiches (text) |
43 |
|
|
$form->setTaille('om_sig_wms',20); |
44 |
|
|
$form->setTaille('ol_map',50); |
45 |
|
|
$form->setTaille('ordre',4); |
46 |
|
|
$form->setTaille('pa_nom',20); |
47 |
|
|
$form->setTaille('pa_layer',50); |
48 |
|
|
$form->setTaille('pa_attribut',50); |
49 |
|
|
$form->setTaille('pa_encaps',3); |
50 |
|
|
$form->setTaille('pa_type_geometrie',30); |
51 |
|
|
} |
52 |
|
|
|
53 |
|
|
function setMax(&$form,$maj) { |
54 |
|
|
parent::setMax($form,$maj); |
55 |
|
|
$form->setMax('ol_map',50); |
56 |
|
|
$form->setMax('ordre',4); |
57 |
|
|
$form->setMax('pa_nom',50); |
58 |
|
|
$form->setMax('pa_layer',50); |
59 |
|
|
$form->setMax('pa_attribut',50); |
60 |
|
|
$form->setMax('pa_encaps',3); |
61 |
|
|
} |
62 |
|
|
|
63 |
|
|
function setLib(&$form,$maj) { |
64 |
|
|
parent::setLib($form,$maj); |
65 |
|
|
//libelle des champs |
66 |
|
|
$form->setLib('om_sig_wms',_('flux WMS : ')); |
67 |
|
|
$form->setLib('ol_map',_('nom map OpenLayer : ')); |
68 |
|
|
$form->setLib('ordre',_('ordre : ')); |
69 |
|
|
$form->setLib('visibility',_('visible par défaut :')); |
70 |
|
|
$form->setLib('pa_nom',_('nom du panier :')); |
71 |
|
|
$form->setLib('pa_layer',_('couche :')); |
72 |
|
|
$form->setLib('pa_attribut',_('attribut :')); |
73 |
|
|
$form->setLib('pa_encaps',_('champ encapsulation :')); |
74 |
|
|
$form->setLib('pa_sql',_('requète (&lst) :')); |
75 |
|
|
$form->setLib('pa_type_geometrie',_('type de géométrie')); |
76 |
|
|
} |
77 |
|
|
|
78 |
|
|
function setSelect(&$form, $maj,&$db,$debug) { |
79 |
|
|
parent::setSelect($form, $maj,$db,$debug); |
80 |
|
|
if($maj<2){ |
81 |
|
|
if(file_exists ("../dyn/var_sig.inc")) |
82 |
|
|
include ("../dyn/var_sig.inc"); |
83 |
|
|
$form->setSelect("pa_type_geometrie",$type_geometrie); |
84 |
|
|
} |
85 |
|
|
} |
86 |
|
|
|
87 |
|
|
}// fin classe |
88 |
|
|
?> |