浏览代码

[oozie] Move Save button to Properties tab

As the cancel action in Workflow Editor is moved to Hue 2.2,
moving the Save button to not be confusing.
Fix js bug
Romain Rigaux 13 年之前
父节点
当前提交
59cf1c9
共有 1 个文件被更改,包括 25 次插入22 次删除
  1. 25 22
      apps/oozie/src/oozie/templates/editor/edit_workflow.mako

+ 25 - 22
apps/oozie/src/oozie/templates/editor/edit_workflow.mako

@@ -121,6 +121,9 @@ ${ layout.menubar(section='workflows') }
             ${ graph }
           </div>
         </div>
+        <div class="form-actions center">
+          <a href="${ url('oozie:list_workflows') }" class="btn">${ _('Back') }</a>
+        </div>
       </div>
 
       <div class="tab-pane" id="properties">
@@ -138,6 +141,12 @@ ${ layout.menubar(section='workflows') }
              </fieldset>
            </div>
         </div>
+        <div class="form-actions center">
+          <a href="${ url('oozie:list_workflows') }" class="btn">${ _('Back') }</a>
+          % if user_can_edit_job:
+            <button data-bind="click: submit" class="btn btn-primary">${ _('Save') }</button>
+          % endif
+        </div>
       </div>
 
       <div class="tab-pane" id="history">
@@ -163,13 +172,6 @@ ${ layout.menubar(section='workflows') }
         % endif
       </div>
     </div>
-
-    <div class="form-actions center">
-      <a href="${ url('oozie:list_workflows') }" class="btn">${ _('Back') }</a>
-      % if user_can_edit_job:
-        <button data-bind="click: submit" class="btn btn-primary">${ _('Save') }</button>
-      % endif
-    </div>
   </form>
 </div>
 
@@ -192,23 +194,24 @@ ${ layout.menubar(section='workflows') }
       window.location = $(this).attr('data-edit');
     });
 
-  $(".modalWindow").click(function(){
-    var _this = $(this);
-    $.ajax({
-      url: _this.attr("data-modal-url"),
-      beforeSend: function(xhr){
-        xhr.setRequestHeader("X-Requested-With", "Hue");
-      },
-      dataType: "html",
-      success: function(data){
-        var id = _this.attr("data-modal-id");
-        $(id).html(data);
-        $(id).modal("show");
-      }
+    $(".modalWindow").click(function(){
+      var _this = $(this);
+      $.ajax({
+        url: _this.attr("data-modal-url"),
+        beforeSend: function(xhr){
+          xhr.setRequestHeader("X-Requested-With", "Hue");
+        },
+        dataType: "html",
+        success: function(data){
+          var id = _this.attr("data-modal-id");
+          $(id).html(data);
+          $(id).modal("show");
+        }
+      });
     });
-  });
 
-  $("a[data-row-selector='true']").jHueRowSelector();
+    $("a[data-row-selector='true']").jHueRowSelector();
+  });
 </script>
 
 ${ utils.path_chooser_libs(True) }