PHRAS-1177_change-multi-on-field

- add : now the "multi" attribute on a field can be changed after creation
- change : field template
#time 3h
This commit is contained in:
Jean-Yves Gaulier
2016-06-23 20:22:25 +02:00
parent e6762531cc
commit deafb8b957
7 changed files with 103 additions and 77 deletions

View File

@@ -451,8 +451,9 @@ class databox extends base implements ThumbnailedElement
$multi = isset($field['multi']) ? (Boolean) (string) $field['multi'] : false;
$meta_struct_field = databox_field::create($this->app, $this, $fname, $multi);
$meta_struct_field = databox_field::create($this->app, $this, $fname);
$meta_struct_field
->set_multi($multi)
->set_readonly(isset($field['readonly']) ? (string) $field['readonly'] : 0)
->set_indexable(isset($field['index']) ? (string) $field['index'] : '1')
->set_separator(isset($field['separator']) ? (string) $field['separator'] : '')