Disable publish button when finished publishing to selected source(s)

This commit is contained in:
Duncan Sommerville 2015-11-16 17:27:51 -05:00
parent 7707378c2b
commit be7c60253b
1 changed files with 1 additions and 0 deletions

View File

@ -87,6 +87,7 @@ var AIRTIME = (function (AIRTIME) {
if (data && Object.keys(data).length > 0) { if (data && Object.keys(data).length > 0) {
$http.put(endpoint + mediaId + '/publish', {csrf_token: jQuery("#csrf").val(), sources: data}) $http.put(endpoint + mediaId + '/publish', {csrf_token: jQuery("#csrf").val(), sources: data})
.success(function () { .success(function () {
tab.contents.find(".publish-btn").prop("disabled", true);
fetchSourceData(); fetchSourceData();
$scope.publishData = {}; // Reset the publishData in case the user publishes $scope.publishData = {}; // Reset the publishData in case the user publishes
// and unpublishes without closing the tab // and unpublishes without closing the tab