mirror of
https://github.com/KevinMidboe/zoff.git
synced 2025-12-07 20:18:49 +00:00
Delete all songs button added. DANGER
This commit is contained in:
@@ -1538,7 +1538,7 @@ nav ul li:hover, nav ul li.active {
|
||||
background-color: rgba(0,0,0,0.1);
|
||||
}
|
||||
|
||||
.change_user_pass:hover {
|
||||
.change_user_pass:hover, .delete-all:hover {
|
||||
background-color: initial;
|
||||
}
|
||||
|
||||
|
||||
2
server/public/assets/dist/embed.min.js
vendored
2
server/public/assets/dist/embed.min.js
vendored
File diff suppressed because one or more lines are too long
2
server/public/assets/dist/main.min.js
vendored
2
server/public/assets/dist/main.min.js
vendored
File diff suppressed because one or more lines are too long
@@ -38,6 +38,9 @@ var Admin = {
|
||||
$('#chan_thumbnail').tooltip("remove");
|
||||
w_p = true;
|
||||
break;
|
||||
case "deleted_songs":
|
||||
msg="All songs in the channel has been deleted!";
|
||||
break;
|
||||
case "shuffled":
|
||||
msg=Helper.rnd(["♫ You stir me right round, baby. ♫","♫ Stir, stir, stir my boat ♫","I vigorously stirred your playlist!", "I hope you like your list stirred, not shaken.", "I shuffled your playlist with the cosmic background radiation as a seed. Enjoy.", "100% randomized, for your listening pleasure!", "I hope you enjoy your fresh playlist!"]);
|
||||
break;
|
||||
@@ -123,6 +126,7 @@ var Admin = {
|
||||
$("#password").val("");
|
||||
$("#password").attr("placeholder", "Change admin password");
|
||||
$(".user-password-li").removeClass("hide");
|
||||
$(".delete-all").removeClass("hide");
|
||||
if($(".password_protected").prop("checked")) {
|
||||
$(".change_user_pass").removeClass("hide");
|
||||
}
|
||||
@@ -206,6 +210,10 @@ var Admin = {
|
||||
$(".user-password-li").addClass("hide")
|
||||
}
|
||||
|
||||
if(!$(".delete-all").hasClass("hide")) {
|
||||
$(".delete-all").addClass("hide");
|
||||
}
|
||||
|
||||
if($(".password_protected").prop("checked")) {
|
||||
$(".change_user_pass").removeClass("hide");
|
||||
}
|
||||
|
||||
@@ -1105,6 +1105,11 @@ $(document).on("click", ".close-user-password", function() {
|
||||
}
|
||||
});
|
||||
|
||||
$(document).on("click", ".delete-all-songs", function(e){
|
||||
e.preventDefault();
|
||||
socket.emit("delete_all", {channel: chan.toLowerCase(), adminpass: adminpass == "" ? "" : Crypt.crypt_pass(adminpass), pass: embed ? '' : Crypt.crypt_pass(Crypt.get_userpass(chan.toLowerCase()))});
|
||||
});
|
||||
|
||||
$(document).on("click", ".not-exported-container .not-exported-element #extra-export-container-text .extra-add-text", function(){
|
||||
this.select();
|
||||
});
|
||||
|
||||
@@ -32,10 +32,13 @@ var Player = {
|
||||
if(!obj.np){
|
||||
|
||||
document.getElementById('song-title').innerHTML = "Empty channel. Add some songs!";
|
||||
document.title = "Zoff - the shared YouTube based radio";
|
||||
//$("#player_overlay").height($("#player").height());
|
||||
|
||||
if(!window.MSStream && !chromecastAvailable) {
|
||||
$("#player_overlay").toggleClass("hide");
|
||||
if($("#player_overlay").hasClass("hide")) {
|
||||
$("#player_overlay").removeClass("hide");
|
||||
}
|
||||
}
|
||||
try{
|
||||
if(!chromecastAvailable) {
|
||||
|
||||
@@ -91,7 +91,6 @@
|
||||
<input name="removeplay" type="checkbox" class="conf" /><span class="lever"></span>
|
||||
<span class="right-span">Remove</span>
|
||||
</label></div></li>
|
||||
|
||||
<li class="user-password-li hide"><span class="switch-text">
|
||||
Channel password
|
||||
</span>
|
||||
@@ -103,6 +102,9 @@
|
||||
<li class="change_user_pass hide">
|
||||
<a href="#!" class="change_user_pass_btn btn waves-effect blue">Change password</a>
|
||||
</li>
|
||||
<li class="delete-all hide">
|
||||
<a href="#" class="delete-all-songs btn red">Delete all songs</a>
|
||||
</li>
|
||||
</ul>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user