Made the default music bot group configurable
parent
f217bc5dd0
commit
b0a0e61a85
|
@ -2,6 +2,8 @@
|
|||
|
||||
* **24.09.18**:
|
||||
- Added server passwords within login modal
|
||||
- Fixed native encoding for opera and firefox
|
||||
- Made the default music bot group configurable
|
||||
|
||||
* **0.0.1-Alpha**:
|
||||
- First public upload of the Web client
|
||||
|
|
|
@ -211,9 +211,6 @@ namespace Modals {
|
|||
|
||||
function server_applyMisc(properties: ServerProperties, server: ServerEntry, tag: JQuery) {
|
||||
{ //TODO notify on tmp channeladmin group and vice versa
|
||||
//virtualserver_default_server_group
|
||||
//virtualserver_default_channel_group
|
||||
//virtualserver_default_channel_admin_group
|
||||
{
|
||||
let groups_tag = tag.find(".default_server_group");
|
||||
groups_tag.change(function (this: HTMLSelectElement) {
|
||||
|
@ -228,6 +225,20 @@ namespace Modals {
|
|||
group_tag.appendTo(groups_tag);
|
||||
}
|
||||
}
|
||||
{
|
||||
let groups_tag = tag.find(".default_music_group");
|
||||
groups_tag.change(function (this: HTMLSelectElement) {
|
||||
properties.virtualserver_default_music_group = parseInt($(this.item(this.selectedIndex)).attr("group-id"));
|
||||
});
|
||||
|
||||
for(let group of server.channelTree.client.groups.serverGroups.sort(GroupManager.sorter())) {
|
||||
if(group.type != 2) continue;
|
||||
let group_tag = $.spawn("option").text(group.name + " [" + (group.properties.savedb ? "perm" : "tmp") + "]").attr("group-id", group.id);
|
||||
if(group.id == server.properties.virtualserver_default_music_group)
|
||||
group_tag.prop("selected", true);
|
||||
group_tag.appendTo(groups_tag);
|
||||
}
|
||||
}
|
||||
|
||||
{
|
||||
let groups_tag = tag.find(".default_channel_group");
|
||||
|
|
|
@ -38,6 +38,7 @@ class ServerProperties {
|
|||
|
||||
virtualserver_codec_encryption_mode: number = 0;
|
||||
|
||||
virtualserver_default_music_group: number = 0;
|
||||
virtualserver_default_server_group: number = 0;
|
||||
virtualserver_default_channel_group: number = 0;
|
||||
virtualserver_default_channel_admin_group: number = 0;
|
||||
|
|
|
@ -335,6 +335,9 @@
|
|||
<div class="key">Server group</div>
|
||||
<select class="value default_server_group"></select>
|
||||
|
||||
<div class="key">Music bot group</div>
|
||||
<select class="value default_music_group"></select>
|
||||
|
||||
<div class="key">Channel group</div>
|
||||
<select class="value default_channel_group"></select>
|
||||
|
||||
|
|
Loading…
Reference in New Issue