Closed machobymb closed 2 years ago
Heureka!
I found this information in GitHub: the showInteger function is deprecated. I changed the line 315 in room.class.php:
if (version_compare(GLPI_VERSION, '9.2', '<')) { Dropdown::showInteger("size", $this->fields["size"],0, 500); } else { Dropdown::showNumber("size", array('value' => $this->fields["size"], 'min' => 0, 'max' => 500)); }
This code was perfect! I thought that showDateFormItem is deprecated too in line 331. I changed the line 331 (now 335) in room.class.php:
if (version_compare(GLPI_VERSION, '9.2', '<')) { Dropdown::showDateFormItem("buy", $this->fields["buy"],true, true); } else { Dropdown::showDateField("buy", array('value' => $this->fields["buy"], 'maybeempty' => true, 'canedit' => true, 'min' => '', 'max' => '')); }
The form is good now. Where can I found full documentation from GLPI functions. I'd like develop a specific event calendar plugin to my workplace.
works in 9.4 now
I tried it in GLPI 9.2.
I viewed the source (room.class.php). The form rendering is incorrect, because in debug mode wrote this error message: "Fatal error: Call to undefined method Dropdown::showInteger() in /var/www/html/glpi/plugins/room/inc/room.class.php on line 315"
Dropdown::showInteger("size", $this->fields["size"],0, 500);