forked from extern/egroupware
* Admin/Mail: fix saving mail-accounts for multiple accounts
This commit is contained in:
parent
fba069e4b6
commit
ba366467b0
@ -347,9 +347,7 @@
|
|||||||
<row class="emailadmin_no_user dialogHeader2">
|
<row class="emailadmin_no_user dialogHeader2">
|
||||||
<description for="account_id" value="Valid for"/>
|
<description for="account_id" value="Valid for"/>
|
||||||
<hbox>
|
<hbox>
|
||||||
<menulist>
|
<select type="select-account" id="account_id" onchange="app.admin.account_hide_not_applying" options="Everyone,both" multiple="dynamic"/>
|
||||||
<menupopup type="select-account" id="account_id" onchange="app.admin.account_hide_not_applying" options="Everyone,both"/>
|
|
||||||
</menulist>
|
|
||||||
<buttononly label="Select multiple" id="button[multiple]" onclick="app.admin.edit_multiple" options="users"/>
|
<buttononly label="Select multiple" id="button[multiple]" onclick="app.admin.edit_multiple" options="users"/>
|
||||||
<checkbox label="account editable by user" id="acc_user_editable"/>
|
<checkbox label="account editable by user" id="acc_user_editable"/>
|
||||||
</hbox>
|
</hbox>
|
||||||
|
@ -25,6 +25,8 @@
|
|||||||
var et2_selectbox = (function(){ "use strict"; return et2_inputWidget.extend(
|
var et2_selectbox = (function(){ "use strict"; return et2_inputWidget.extend(
|
||||||
{
|
{
|
||||||
attributes: {
|
attributes: {
|
||||||
|
// todo fully implement attr[multiple] === "dynamic" to render widget with a button to switch to multiple
|
||||||
|
// as it is used in account_id selection in admin >> mailaccount (app.admin.edit_multiple method client-side)
|
||||||
"multiple": {
|
"multiple": {
|
||||||
"name": "multiple",
|
"name": "multiple",
|
||||||
"type": "boolean",
|
"type": "boolean",
|
||||||
|
@ -23,6 +23,8 @@ use calendar_timezones;
|
|||||||
* eTemplate select widget
|
* eTemplate select widget
|
||||||
*
|
*
|
||||||
* @todo unavailable cats (eg. private cats of an other user) need to be preserved!
|
* @todo unavailable cats (eg. private cats of an other user) need to be preserved!
|
||||||
|
* @todo fully implement attr[multiple] === "dynamic" to render widget with a button to switch to multiple
|
||||||
|
* as it is used in account_id selection in admin >> mailaccount (app.admin.edit_multiple method client-side)
|
||||||
*/
|
*/
|
||||||
class Select extends Etemplate\Widget
|
class Select extends Etemplate\Widget
|
||||||
{
|
{
|
||||||
@ -148,7 +150,7 @@ class Select extends Etemplate\Widget
|
|||||||
if ($child->type == 'option') $allowed[] = (string)$child->attrs['value'];
|
if ($child->type == 'option') $allowed[] = (string)$child->attrs['value'];
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!$multiple ) $allowed[] = '';
|
if (!$multiple || $this->attrs['multiple'] === "dynamic") $allowed[] = '';
|
||||||
|
|
||||||
foreach((array) $value as $val)
|
foreach((array) $value as $val)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user