Merge pull request #55 from radiorabe/feature/autodj

Robbs AutoDJ
This commit is contained in:
Robb 2017-03-11 18:41:08 -05:00 committed by GitHub
commit 2be8ef0f2b
65 changed files with 1611 additions and 126 deletions

View file

@ -267,6 +267,12 @@ function setAddShowEvents(form) {
}
});
if(!form.find("#add_show_has_autoplaylist").attr('checked')) {
form.find("#add_show_playlist_dropdown").hide();
}
else {
$("#add_show_playlist_dropdown").show();
}
if(!form.find("#add_show_repeats").attr('checked')) {
form.find("#schedule-show-when > fieldset:last").hide();
@ -291,6 +297,21 @@ function setAddShowEvents(form) {
var submitButton = $(".button-bar.bottom").find(".add-show-submit");
$("[id^=add_show_instance_description]").toggle(submitButton.attr("data-action") === "edit-repeating-show-instance");
form.find("#add_show_has_autoplaylist").click(function(){
$(this).blur();
form.find("#add_show_playlist_dropdown").toggle();
var checkBoxSelected = false;
//must switch rebroadcast displays
if(form.find("#add_show_has_autoplaylist").attr('checked')) {
form.find("#add_show_playlist_dropdown").show();
}
else {
form.find("#add_show_playlist_downdown").hide();
}
});
form.find("#add_show_repeats").click(function(){
$(this).blur();
form.find("#schedule-show-when > fieldset:last").toggle();