mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-08 23:19:04 +01:00
Hopefully fix boolean reflected attributes not properly getting set
The previous way worked eventually, but attributes did not get immediately synced to properties
This commit is contained in:
parent
cbbe8c4400
commit
5b0427fe0c
@ -1416,17 +1416,15 @@ function transformAttributes(widget, mgr : et2_arrayMgr, attributes)
|
|||||||
if(widget.getAttributeNames().indexOf(attribute) >= 0 || property.reflect && attrValue)
|
if(widget.getAttributeNames().indexOf(attribute) >= 0 || property.reflect && attrValue)
|
||||||
{
|
{
|
||||||
// Set as attribute (reflected in DOM)
|
// Set as attribute (reflected in DOM)
|
||||||
widget.setAttribute(attribute, attrValue);
|
widget.setAttribute(attribute, attrValue === true ? "" : attrValue);
|
||||||
}
|
}
|
||||||
else if (attribute === 'options')
|
else if(attribute === 'options')
|
||||||
{
|
{
|
||||||
console.trace('Ignored setting depricated "options" attribute for widget #'+widget.id, widget);
|
console.trace('Ignored setting depricated "options" attribute for widget #' + widget.id, widget);
|
||||||
}
|
continue;
|
||||||
else
|
|
||||||
{
|
|
||||||
// Set as property, not attribute
|
|
||||||
widget[attribute] = attrValue;
|
|
||||||
}
|
}
|
||||||
|
// Set as property
|
||||||
|
widget[attribute] = attrValue;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(widget_class.getPropertyOptions("value") && widget.set_value)
|
if(widget_class.getPropertyOptions("value") && widget.set_value)
|
||||||
|
Loading…
Reference in New Issue
Block a user