CC-4904: Library -> Sort by status doesn't work
- added 2 columns to cc_files (is_scheduled, is_playlist) - split library status column into two columns (scheduled, playlist) - is_scheduled gets updated when a track plays out, or when a file gets added/removed from/to a show - is_playlist gets updated when a file gets added/removed from/to a playlist/block, when a playlist/block gets deleted, or when a playlist/block's contents is cleared
This commit is contained in:
parent
384298f680
commit
8309593a0f
14 changed files with 376 additions and 59 deletions
|
@ -81,8 +81,18 @@ var AIRTIME = (function(AIRTIME){
|
|||
return mod.showInstances;
|
||||
};
|
||||
|
||||
mod.refresh = function() {
|
||||
mod.refresh = function(schedId) {
|
||||
mod.resetTimestamp();
|
||||
|
||||
// once a track plays out we need to check if we can update
|
||||
// the is_scheduled flag in cc_files
|
||||
$.post(baseUrl+"schedule/update-future-is-scheduled",
|
||||
{"format": "json", "schedId": schedId}, function(json) {
|
||||
var data = $.parseJSON(json);
|
||||
if (data.redrawLibTable) {
|
||||
$("#library_content").find("#library_display").dataTable().fnStandingRedraw();
|
||||
}
|
||||
});
|
||||
oSchedTable.fnDraw();
|
||||
};
|
||||
|
||||
|
@ -797,7 +807,7 @@ var AIRTIME = (function(AIRTIME){
|
|||
if(refreshInterval > maxRefreshInterval){
|
||||
refreshInterval = maxRefreshInterval;
|
||||
}
|
||||
mod.timeout = setTimeout(mod.refresh, refreshInterval); //need refresh in milliseconds
|
||||
mod.timeout = setTimeout(function() {mod.refresh(aData.id)}, refreshInterval); //need refresh in milliseconds
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue