replace multiple="dynamic" with expand_multiple_rows="4" and remove button to switch to multiple

This commit is contained in:
ralf 2022-03-18 22:27:33 +02:00
parent a45d26511b
commit 238a22ba01
2 changed files with 3 additions and 21 deletions

View File

@ -1291,22 +1291,6 @@ class AdminApp extends EgwApp
this.et2.getWidgetById('acc_sieve_enabled').set_value(1); this.et2.getWidgetById('acc_sieve_enabled').set_value(1);
} }
/**
* Switch to select multiple accounts
*
* @param {object} _event event-object or information about event
* @param {et2_baseWidget} _widget widget causing the event
*/
edit_multiple(_event, _widget)
{
// hide multiple button
_widget.set_disabled(true);
// switch account-selection to multiple
var account_id = this.et2.getWidgetById('account_id');
account_id.set_multiple(true);
}
/** /**
* Hide not applying fields, used as: * Hide not applying fields, used as:
* - onchange handler on account_id * - onchange handler on account_id
@ -1339,7 +1323,6 @@ class AdminApp extends EgwApp
{ {
// switch back to single selectbox // switch back to single selectbox
account_id.set_multiple(false); account_id.set_multiple(false);
this.et2.getWidgetById('button[multiple]').set_disabled(false);
} }
} }
// switched to single user // switched to single user
@ -1584,4 +1567,4 @@ class AdminApp extends EgwApp
} }
} }
app.classes.admin = AdminApp; app.classes.admin = AdminApp;

View File

@ -338,8 +338,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>
<select-account account_type="both" id="account_id" onchange="app.admin.account_hide_not_applying" empty_label="Everyone" multiple="dynamic"/> <select-account account_type="both" id="account_id" onchange="app.admin.account_hide_not_applying" empty_label="Everyone" expand_multiple_rows="4"/>
<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>
<description/> <description/>
@ -377,4 +376,4 @@
<button align="right" label="Delete identity" id="button[delete_identity]" onclick="et2_dialog.confirm(widget,'Delete identity','Delete')" image="delete" background_image="1"/> <button align="right" label="Delete identity" id="button[delete_identity]" onclick="et2_dialog.confirm(widget,'Delete identity','Delete')" image="delete" background_image="1"/>
</hbox> </hbox>
</template> </template>
</overlay> </overlay>