close_xss = 1; // 关闭xss验证 $this->is_edit = false; // 不允许修改字段类别 $this->fieldtype = ['TEXT']; $this->defaulttype = 'TEXT'; } /** * 字段相关属性参数 * * @param array $value 值 * @param array $field 字段集合 * @return string */ public function option($option, $field = NULL) { $Merge = []; $option['value'] = isset($option['value']) ? $option['value'] : ''; if ($field) { foreach ($field as $t) { if ($t['fieldtype'] == 'Merge') { $t['setting'] = dr_string2array($t['setting']); if (preg_match_all('/\{(.+)\}/U', $t['setting']['option']['value'], $value)) { foreach ($value[1] as $v) { $Merge[] = $v; } } } } $_field = []; $_field[] = ''; foreach ($field as $t) { $t['fieldtype'] != 'Merge' && !dr_in_array($t['fieldname'], $Merge) && $_field[] = ''; } $_field = implode('', array_unique($_field)); } return ['