Revision 0d761a49
[#1571] Ajout du champ Vigilo Template
Change-Id: Ib31d45245cbbbeb845df30f013bec479878ee627
Reviewed-on: https://vigilo-dev.si.c-s.fr/review/2321
Reviewed-by: Francois POIROTTE <francois.poirotte@c-s.fr>
Tested-by: Francois POIROTTE <francois.poirotte@c-s.fr>
Vigilo/VigiloHost.php | ||
---|---|---|
67 | 67 |
} |
68 | 68 |
|
69 | 69 |
$this->children[] = new VigiloHostTemplate($model);*/ |
70 |
|
|
70 |
|
|
71 | 71 |
|
72 | 72 |
$template_number = $this->computer->getField("vigilo_template"); |
73 |
if ($template_number !== '0') { |
|
73 |
if ($template_number !== '0' && $template_number !== 'N/A') {
|
|
74 | 74 |
$common_dbtm = new CommonDBTM(); |
75 |
$template_name = $this->computer->getVigiloTemplateName($template_number); |
|
75 |
$template_name = PluginVigiloVigiloTemplate::getVigiloTemplateNameByID($template_number); |
|
76 |
$this->children[] = new VigiloHostTemplate($template_name); |
|
76 | 77 |
} |
77 | 78 |
else { |
78 |
$template_name = "default"; |
|
79 |
if (empty($this->children)) { |
|
80 |
$template_name = "default"; |
|
81 |
$this->children[] = new VigiloHostTemplate($template_name); |
|
82 |
} |
|
79 | 83 |
} |
80 |
$this->children[] = new VigiloHostTemplate($template_name); |
|
81 | 84 |
} |
82 | 85 |
|
83 | 86 |
protected function selectGroups() |
Also available in: Unified diff