Fix #12179.
In WebKit browsers, when a schema is saved, existing column field types are reset to "Text". This is not a bug in WebKit, and will happen in any browser that implements Option() as documented. Option() is not supposed to have an immediate action if only the default selection is updated on a newly added select object. See: http://download.oracle.com/docs/cd/E19957-01/816-6408-10/option.htm . Repeat-By: 1. New Content->basic->Datatable 2. data 3. Edit Schema 4. col1, Number, Add Column 5. col2, E-mail, Add Column 6. col3, URL, Add Column 7. Edit Schema (note that the field types got reset to "Text") 8 Save (now the field types incorrectly got overwritten in the DataTable) Fixed by adding 4th arguments to actually make the new selection to be equal to the default one.
This commit is contained in:
parent
ed0c400440
commit
8e7beabaf0
1 changed files with 3 additions and 1 deletions
|
|
@ -459,10 +459,12 @@ WebGUI.Form.DataTable
|
|||
format.name = "format_" + i;
|
||||
|
||||
for ( var x = 0; x < availableFormats.length; x++ ) {
|
||||
var selected = cols[i].formatter == availableFormats[x].value;
|
||||
var opt = new Option(
|
||||
availableFormats[x].label,
|
||||
availableFormats[x].value,
|
||||
cols[i].formatter == availableFormats[x].value
|
||||
selected,
|
||||
selected
|
||||
);
|
||||
format.appendChild( opt );
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue