Преглед на файлове

Fixed default value for radio extrafield (#27066)

William Mead преди 1 година
родител
ревизия
92afb654db
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      htdocs/core/class/commonobject.class.php

+ 1 - 1
htdocs/core/class/commonobject.class.php

@@ -8288,7 +8288,7 @@ abstract class CommonObject
 						}
 
 						// HTML, text, select, integer and varchar: take into account default value in database if in create mode
-						if (in_array($extrafields->attributes[$this->table_element]['type'][$key], array('html', 'text', 'varchar', 'select', 'int', 'boolean'))) {
+						if (in_array($extrafields->attributes[$this->table_element]['type'][$key], array('html', 'text', 'varchar', 'select', 'radio', 'int', 'boolean'))) {
 							if ($action == 'create') {
 								$value = (GETPOSTISSET($keyprefix.'options_'.$key.$keysuffix) || $value) ? $value : $extrafields->attributes[$this->table_element]['default'][$key];
 							}