Revision 2ef80588
[#1570] Ajout du TCP dans les tests personnalisés, ajouts de tests pour éviter des warnings PHP, prise en charge du futur champ vigilo_template
Change-Id: I8652384cd1116ce54cdc66e48977c5174b1188be
Reviewed-on: https://vigilo-dev.si.c-s.fr/review/2311
Reviewed-by: Francois POIROTTE <francois.poirotte@c-s.fr>
Tested-by: Francois POIROTTE <francois.poirotte@c-s.fr>
Vigilo/VigiloHost.php | ||
---|---|---|
43 | 43 |
if ($template_name && $template_name !== "N/A") { |
44 | 44 |
$this->children[] = new VigiloHostTemplate($this->computer->getField("template_name")); |
45 | 45 |
} |
46 |
$refs = array( |
|
46 |
/*$refs = array(
|
|
47 | 47 |
"glpi_operatingsystems" => "operatingsystems_id", |
48 | 48 |
"glpi_operatingsystemversions" => "operatingsystemversions_id", |
49 | 49 |
"glpi_operatingsystemservicepacks" => "operatingsystemservicepacks_id", |
... | ... | |
66 | 66 |
$model = implode(" - ", $model); |
67 | 67 |
} |
68 | 68 |
|
69 |
$this->children[] = new VigiloHostTemplate($model); |
|
69 |
$this->children[] = new VigiloHostTemplate($model);*/ |
|
70 |
|
|
71 |
|
|
72 |
$template_number = $this->computer->getField("vigilo_template"); |
|
73 |
if ($template_number !== '0') { |
|
74 |
$common_dbtm = new CommonDBTM(); |
|
75 |
$template_name = $this->computer->getVigiloTemplateName($template_number); |
|
76 |
} |
|
77 |
else { |
|
78 |
$template_name = "default"; |
|
79 |
} |
|
80 |
$this->children[] = new VigiloHostTemplate($template_name); |
|
70 | 81 |
} |
71 | 82 |
|
72 | 83 |
protected function selectGroups() |
Also available in: Unified diff