Commit d36f65af authored by Côme Chilliet's avatar Côme Chilliet
Browse files

:ambulance: fix(opsi): Fix a PHP error in OPSI product properties tab

issue #5745
Showing with 3 additions and 2 deletions
+3 -2
......@@ -227,16 +227,17 @@ class opsiProductProperties extends simplePlugin
return;
}
$property = $this->properties[$productid][$propertyid];
$defaultValue = (isset($property['defaultValues'][0]) ? $property['defaultValues'][0] : '');
if ($property['editable']) {
$attr = new StringAttribute(
'', $property['description'],
$property['propertyId'], FALSE, $property['defaultValues'][0]
$property['propertyId'], FALSE, $defaultValue
);
} else {
$attr = new SelectAttribute(
'', $property['description'],
$property['propertyId'], FALSE,
$property['possibleValues'], $property['defaultValues'][0],
$property['possibleValues'], $defaultValue,
array_map(
function ($a)
{
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment