CC-84: Smart Playlists
- ui cleanup
This commit is contained in:
parent
2a38527161
commit
7c5291fe0c
4 changed files with 71 additions and 68 deletions
|
@ -93,7 +93,7 @@ select {
|
|||
}
|
||||
/* Version Notification Ends*/
|
||||
|
||||
.override_help_icon, .icecast_metadata_help_icon {
|
||||
.override_help_icon, .icecast_metadata_help_icon {
|
||||
cursor: help;
|
||||
position: relative;
|
||||
|
||||
|
@ -104,7 +104,7 @@ select {
|
|||
line-height:16px !important;
|
||||
}
|
||||
|
||||
.airtime_auth_help_icon, .custom_auth_help_icon, .stream_username_help_icon {
|
||||
.airtime_auth_help_icon, .custom_auth_help_icon, .stream_username_help_icon, .playlist_type_help_icon {
|
||||
cursor: help;
|
||||
position: relative;
|
||||
display:inline-block; zoom:1;
|
||||
|
@ -416,6 +416,8 @@ input[type="text"]:focus, input[type="password"]:focus, textarea:focus, .input_t
|
|||
padding: 2px 2px 2px 0;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
/***** SMART PLAYLIST SPECIFIC STYLES BEGIN *****/
|
||||
.sp_input_select{
|
||||
width: 130px;
|
||||
}
|
||||
|
@ -429,24 +431,35 @@ input.input_text.sp_input_text{
|
|||
}
|
||||
|
||||
input.input_text.sp_extra_input_text{
|
||||
width: 85px !important;
|
||||
width: 87px !important;
|
||||
}
|
||||
|
||||
.sp-ui-button-icon-only .ui-icon{
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
.sp_text_font{
|
||||
font-size:13px;
|
||||
font-family:Helvetica, Arial, sans-serif;
|
||||
color: #5B5B5B;
|
||||
}
|
||||
|
||||
.sp-ui-button-icon-only {
|
||||
position: relative;
|
||||
top: 5px;
|
||||
margin-top: -10px;
|
||||
left: 50%;
|
||||
}
|
||||
|
||||
.sp-add.sp-ui-button-icon-only .ui-icon{
|
||||
margin-left: 20px !important;
|
||||
margin-left: 5px;
|
||||
}
|
||||
|
||||
.sp-ui-button-icon-only .ui-icon-closethick:hover, .sp-ui-button-icon-only .ui-icon-plusthick:hover {
|
||||
background-image:url(redmond/images/ui-icons_ff5d1a_256x240.png)
|
||||
}
|
||||
|
||||
.sp-button{
|
||||
float: right !important;
|
||||
width: 60px;
|
||||
height: 24px !important;
|
||||
margin-right: 0px !important;
|
||||
margin-left: 10px !important;
|
||||
}
|
||||
/***** SMART PLAYLIST SPECIFIC STYLES END *****/
|
||||
|
||||
label {
|
||||
font-size:13px;
|
||||
color:#5b5b5b;
|
||||
|
|
|
@ -1,5 +1,29 @@
|
|||
$(document).ready(function() {
|
||||
setSmartPlaylistEvents();
|
||||
|
||||
$(".playlist_type_help_icon").qtip({
|
||||
content: {
|
||||
text: "A static playlist will save the criteria and generate the playlist content immediately." +
|
||||
"This allows you to edit and view it in the Playlist Builder before adding it to a show.<br /><br />" +
|
||||
"A dynamic playlist will only save the criteria. The playlist content will get generated upon " +
|
||||
"adding it to a show. You will not be able to view and edit it in the Playlist Builder."
|
||||
},
|
||||
hide: {
|
||||
delay: 500,
|
||||
fixed: true
|
||||
},
|
||||
style: {
|
||||
border: {
|
||||
width: 0,
|
||||
radius: 4
|
||||
},
|
||||
classes: "ui-tooltip-dark ui-tooltip-rounded"
|
||||
},
|
||||
position: {
|
||||
my: "left bottom",
|
||||
at: "right center"
|
||||
},
|
||||
})
|
||||
});
|
||||
|
||||
function setSmartPlaylistEvents() {
|
||||
|
@ -171,7 +195,7 @@ function setupUI() {
|
|||
var playlist_type = $('input:radio[name=sp_type]:checked').val();
|
||||
if (playlist_type == "0") {
|
||||
$('button[id="generate_button"]').show();
|
||||
$('button[id="shuffle_button"]').show();
|
||||
$('button[id="shuffle_button"]').show();
|
||||
$('#spl_sortable').unblock();
|
||||
$('#spl_sortable').css("position", "static");
|
||||
} else {
|
||||
|
@ -262,53 +286,19 @@ function callback(data, type) {
|
|||
form.find('.success').text('Criteria saved');
|
||||
form.find('.success').show();
|
||||
}
|
||||
setTimeout('removeSuccessMsg()', 5000);
|
||||
}
|
||||
}
|
||||
|
||||
/*function generateCallback(data) {
|
||||
var form = $('#smart-playlist-form'),
|
||||
json = $.parseJSON(data);
|
||||
|
||||
form.find('span[class="errors sp-errors"]').remove();
|
||||
|
||||
if (json.result == "1") {
|
||||
form.find('.success').hide();
|
||||
$.each(json.errors, function(index, error){
|
||||
$.each(error.msg, function(index, message){
|
||||
$('#'+error.element).parent().append("<span class='errors sp-errors'>"+message+"</span>");
|
||||
});
|
||||
});
|
||||
} else {
|
||||
AIRTIME.playlist.fnOpenPlaylist(json);
|
||||
form = $('#smart-playlist-form')
|
||||
form.find('.success').text('Smart playlist generated');
|
||||
form.find('.success').show();
|
||||
form.find('#smart_playlist_options').removeClass("closed");
|
||||
}
|
||||
function removeSuccessMsg() {
|
||||
var form = $('#smart-playlist-form');
|
||||
form.find('.success').text('');
|
||||
form.find('.success').hide();
|
||||
}
|
||||
|
||||
function saveCallback(json) {
|
||||
var form = $('#smart-playlist-form'),
|
||||
json = $.parseJSON(json);
|
||||
|
||||
form.find('span[class="errors sp-errors"]').remove();
|
||||
|
||||
if (json.result == "1") {
|
||||
form.find('.success').hide();
|
||||
$.each(json.errors, function(index, error){
|
||||
$.each(error.msg, function(index, message){
|
||||
$('#'+error.element).parent().append("<span class='errors sp-errors'>"+message+"</span>");
|
||||
});
|
||||
});
|
||||
} else {
|
||||
form.find('.success').text('Criteria saved');
|
||||
form.find('.success').show();
|
||||
}
|
||||
}*/
|
||||
|
||||
function appendAddButton() {
|
||||
var rows = $('#smart-playlist-form');
|
||||
var add_button = "<a class='ui-button sp-add sp-ui-button-icon-only criteria_add'>" +
|
||||
var add_button = "<a class='ui-button sp-ui-button-icon-only criteria_add'>" +
|
||||
"<span class='ui-icon ui-icon-plusthick'></span></a>";
|
||||
|
||||
rows.find('.criteria_add').remove();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue