Ver código fonte

HUE-6398 [jobsub] Fix loading edit design page

Removed the page refresh on complete of edit-design Ajax call.
Partial revert of - https://github.com/cloudera/hue/commit/c4edebadae5ba0c62c4a77f4689ef086d1f8677b
krish 8 anos atrás
pai
commit
1b8ae04f8e
1 arquivos alterados com 1 adições e 11 exclusões
  1. 1 11
      apps/jobsub/src/jobsub/static/jobsub/js/jobsub.ko.js

+ 1 - 11
apps/jobsub/src/jobsub/static/jobsub/js/jobsub.ko.js

@@ -17,7 +17,6 @@
 /**
  * Design representation
  */
-var jobsubAjaxQueue = 0;
 var Design = (function($, ko, NodeFields) {
   var module = function(options) {
     var self = this;
@@ -155,16 +154,7 @@ var Design = (function($, ko, NodeFields) {
         dataType: 'json',
         type: 'GET',
         success: $.noop,
-        error: $.noop,
-        beforeSend: function () {
-          jobsubAjaxQueue = jobsubAjaxQueue + 1;
-        },
-        complete: function () {
-          jobsubAjaxQueue = Math.max(jobsubAjaxQueue - 1, 0);
-          if (jobsubAjaxQueue == 0) {
-            $(document).trigger('reload.designs');
-          }
-        }
+        error: $.noop
       }, options || {});
 
       $.ajax(request);