Browse Source

HUE-6077 [oozie] Scroll the right element on action drop

(cherry picked from commit 06a3090727f6d12179af0e0e55dec1abf2c4f58a)
Enrico Berti 8 years ago
parent
commit
1b495cf
1 changed files with 6 additions and 0 deletions
  1. 6 0
      apps/oozie/src/oozie/templates/editor2/workflow_editor.mako

+ 6 - 0
apps/oozie/src/oozie/templates/editor2/workflow_editor.mako

@@ -679,9 +679,15 @@ ${ dashboard.import_bindings() }
       "width": 450
     });
     $("#addActionDemiModal").width(_el.width()).css("top", _el.position().top + 25).css("left", _el.position().left).modal("show");
+    %if is_embeddable:
+    $(".page-content").animate({
+    scrollTop: $("#addActionDemiModal").offset().top - 200
+    }, 200);
+    %else:
     $("html, body").animate({
       scrollTop: $("#addActionDemiModal").offset().top - 200
     }, 200);
+    %endif
   }
 
   function addActionDemiModalFieldPreview(field) {