szollosil 1 год назад
Родитель
Сommit
6d4ab23c4d
1 измененных файлов с 2 добавлено и 3 удалено
  1. 2 3
      core/class/commonobject.class.php

+ 2 - 3
core/class/commonobject.class.php

@@ -8407,10 +8407,9 @@ abstract class CommonObject
 									$entrepotObj = new Entrepot($this->db);
 									$entrepotObj->fetch($_REQUEST['inventory_id']);
 									if ($entrepotObj->array_options['options_entrepot_type'] == 1) {
-										$extrafields->attributes['inventory']['param'][$key]['options'] = array_slice($extrafields->attributes['inventory']['param'][$key]['options'], -2);
+										$extrafields->attributes['inventory']['param'][$key]['options'] = array_slice($extrafields->attributes['inventory']['param'][$key]['options'], -2, true);
 									}else{
-										$extrafields->attributes['inventory']['param'][$key]['options'] = array_slice($extrafields->attributes['inventory']['param'][$key]['options'], 0, 4);
-									}
+										$extrafields->attributes['inventory']['param'][$key]['options'] = array_slice($extrafields->attributes['inventory']['param'][$key]['options'], 0, 4, true);									}
 									$out .= $extrafields->showInputField($key, $value, '', $keysuffix, '', 0, $this->id, $this->table_element);
 								} else {
 									$out .= $extrafields->showInputField($key, $value, '', $keysuffix, '', 0, $this->id, $this->table_element);