Add unregistration for channel admins

This commit is contained in:
calzoneman 2013-05-13 15:41:29 -04:00
parent 27cfbcb61a
commit 4620fb2d56
9 changed files with 82 additions and 2 deletions

View file

@ -75,6 +75,15 @@ Callbacks = {
}
},
unregisterChannel: function(data) {
if(data.success) {
alert("Channel unregistered");
}
else {
alert(data.error);
}
},
updateMotd: function(data) {
$("#motdtext").val(data.motd);
if(data.motd != "")

View file

@ -456,6 +456,13 @@ $("#show_acl").click(function() {
}
});
$("#drop_channel").click(function() {
var res = confirm("You are about to unregister your channel. This will PERMANENTLY delete your channel data, including ranks, bans, and library videos. This cannot be undone. Are you sure you want to continue?");
if(res) {
socket.emit("unregisterChannel");
}
});
function splitreEntry(str) {
var split = [];
var current = [];

View file

@ -644,6 +644,9 @@ function handleRankChange() {
$("#clearplaylist").css("display", "none");
$("#shuffleplaylist").css("display", "none");
}
if(RANK >= 10) {
$("#drop_channel").parent().css("display", "");
}
}
function onWindowFocus() {