mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-08-14 02:18:31 +02:00
Etemplate: Allow to specify the read only true/false values for checkbox customfields
This commit is contained in:
@ -439,9 +439,15 @@ var et2_customfields_list = /** @class */ (function (_super) {
|
||||
};
|
||||
et2_customfields_list.prototype._setup_checkbox = function (field_name, field, attrs) {
|
||||
// Read-only checkbox is just text
|
||||
if (attrs.readonly) {
|
||||
if (attrs.readonly && this.getType() !== "customfields") {
|
||||
attrs.ro_true = field.label;
|
||||
}
|
||||
else if (field.hasOwnProperty('ro_true')) {
|
||||
attrs.ro_true = field.ro_true;
|
||||
}
|
||||
if (field.hasOwnProperty('ro_false')) {
|
||||
attrs.ro_false = field.ro_false;
|
||||
}
|
||||
return true;
|
||||
};
|
||||
/**
|
||||
|
Reference in New Issue
Block a user