浏览代码

HUE-1643 [pig] Progress does not update

Fixed logs refresh trigger that failed on slow submissions
Enrico Berti 12 年之前
父节点
当前提交
8e0583d
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      apps/pig/static/js/pig.ko.js

+ 1 - 1
apps/pig/static/js/pig.ko.js

@@ -509,7 +509,6 @@ var PigViewModel = function (props) {
     self.currentScript(script);
     $(document).trigger("showLogs");
     $(document).trigger("running");
-    $(document).trigger("startLogsRefresh");
     $("#submitModal").modal("hide");
     $.post(self.RUN_URL,
         {
@@ -528,6 +527,7 @@ var PigViewModel = function (props) {
           }
           script.isRunning(true);
           script.watchUrl(data.watchUrl);
+          $(document).trigger("startLogsRefresh");
           $(document).trigger("refreshDashboard");
           self.updateScripts();
         }, "json").fail( function(xhr, textStatus, errorThrown) {