Bug #5045

when the location field contains a location and sublocation the plugin fail with an error

Added by benoitmortier about 5 years ago. Updated about 5 years ago.

Status:NewStart date:08/28/2014
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:-
Target version:-

Description

Hello,

i have a glpi with generic objects 2.3.2 and the location field contains

Eurostation > 1040

When i try to move from one entity to a lower entity i got this message

Fatal error: Call to undefined function addslashes_deep() in /var/www/glpi/plugins/genericobject/inc/object.class.php on line 882


$tmp = array();
$where = "";
// if ($dropdown instanceof CommonTreeDropdown) {
// $tmp['completename'] = $dropdown->fields['completename'];
// $where = "`completename`='".
// addslashes_deep($tmp['completename'])."'";
// } else {
// $tmp['name'] = $dropdown->fields['name'];
// $where = "`name`='".addslashes_deep($tmp['name'])."'";
// }
$tmp['entities_id'] = $new_entity;
$where .= " AND `entities_id`='".$tmp['entities_id']."'";

when commenting the part above the error disapears, of course i don't know what others effet this can have with this part commented

Cheers

History

#1 Updated by mtpl about 5 years ago

the project has moved to github, please open an issue on it.
https://github.com/TECLIB/glpi-plugin-genericobject

thanks

Also available in: Atom PDF