CC-5709: Airtime Analyzer

* Make the Recent Uplods file actions a bit clearer
This commit is contained in:
Albert Santoni 2014-03-25 15:35:50 -04:00
parent 03267fe83b
commit 9e9e676b54

View file

@ -67,8 +67,15 @@ $(document).ready(function() {
};
self.renderFileActions = function ( data, type, full ) {
return '<a class="deleteFileAction">Delete</a>';
};
if (full.import_status == 0) {
return '<a class="deleteFileAction">' + $.i18n._('Delete from Library') + '</a>';
} else if (full.import_status == 1) {
//No actions for pending files
return $.i18n._('N/A');
} else { //Failed downloads
return '<a class="deleteFileAction">' + $.i18n._('Clear') + '</a>';
}
};
$("#recent_uploads_table").on("click", "a.deleteFileAction", function () {
//Grab the file object for the row that was clicked.