浏览代码

[oozie] Add properties to action

Romain Rigaux 11 年之前
父节点
当前提交
4da321c
共有 2 个文件被更改,包括 15 次插入1 次删除
  1. 14 1
      apps/oozie/src/oozie/templates/editor/workflow_editor.mako
  2. 1 0
      apps/oozie/src/oozie/views/editor2.py

+ 14 - 1
apps/oozie/src/oozie/templates/editor/workflow_editor.mako

@@ -274,7 +274,20 @@ ${ dashboard.layout_skeleton() }
           </button>
           <br/>
           ${ _('Job XML') } <input type="text" data-bind="value: properties.job_xml" /></br>
-          proeperties <input type="text" data-bind="value: properties.properties" /></br>
+          ${ _('Properties') }   
+          <ul data-bind="foreach: properties.properties">
+            <li>
+              <input data-bind="value: name"/>
+              <input data-bind="value: value"/>
+              <a href="#" data-bind="click: function(){ $parent.properties.properties.remove(this); }">
+                <i class="fa fa-minus"></i>
+              </a>
+            </li>
+          </ul>
+          <button data-bind="click: function(){ properties.properties.push({'name': '', 'value': ''}); }">
+            <i class="fa fa-plus"></i>
+          </button>       
+          <br/>          
           parameters <input type="text" data-bind="value: properties.parameters" /></br>
           archives <input type="text" data-bind="value: properties.archives" /></br>
           sla <input type="text" data-bind="value: properties.sla" /></br>

+ 1 - 0
apps/oozie/src/oozie/views/editor2.py

@@ -178,6 +178,7 @@ def add_node(request):
       'archives': [],
       'prepares': [],
       'job_xml': '',
+      'properties': [],
   })
 
   response['status'] = 0