mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-22 05:49:03 +01:00
fixed not working options for readonly radiobutton eg. "something,♥": missing legacyOptions for et2_radionbox_ro and no entity_decoding from attributes in template (they require it because of xml)
This commit is contained in:
parent
86bfd86826
commit
6df2fa827d
@ -156,7 +156,7 @@ function et2_checkType(_val, _type, _attr, _widget)
|
||||
{
|
||||
if (typeof _val == "string")
|
||||
{
|
||||
return _val;
|
||||
return html_entity_decode(_val);
|
||||
}
|
||||
|
||||
// Handle some less common possibilities
|
||||
@ -790,3 +790,14 @@ function et2_call(_func)
|
||||
}
|
||||
return func.apply(parent, args);
|
||||
}
|
||||
|
||||
/**
|
||||
* Decode html entities so they can be added via .text(_str), eg. html_entity_decode('&') === '&'
|
||||
*
|
||||
* @param {string} _str
|
||||
* @returns {string}
|
||||
*/
|
||||
function html_entity_decode(_str)
|
||||
{
|
||||
return _str && _str.indexOf('&') != -1 ? jQuery('<span>'+_str+'</span>').text() : _str;
|
||||
}
|
@ -169,6 +169,8 @@ var et2_radiobox_ro = et2_valueWidget.extend([et2_IDetachedDOM],
|
||||
}
|
||||
},
|
||||
|
||||
legacyOptions: ["set_value", "ro_true", "ro_false"],
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user