소스 검색

HUE-3797 [oozie] Move the workflow creation logic out of the view

Romain Rigaux 9 년 전
부모
커밋
23afa3e95f
2개의 변경된 파일5개의 추가작업 그리고 10개의 파일을 삭제
  1. 3 3
      apps/oozie/src/oozie/models2.py
  2. 2 7
      apps/oozie/src/oozie/views/editor2.py

+ 3 - 3
apps/oozie/src/oozie/models2.py

@@ -2795,7 +2795,7 @@ class History(object):
 
 class WorkflowBuilder():
   """
-  Focus on building nodes, not the UI layout.
+  Focus on building nodes, not the UI layout (should be graph automatically).
   """
   def create_hive_document_workflow(self, name, parameters, user):
     api = get_oozie(user)
@@ -3127,8 +3127,8 @@ class WorkflowBuilder():
       u'size': 12,
       }]}
     )
-  
-    workflow_doc = Document2.objects.create(name=name, type='oozie-workflow2', owner=user, data=data)
+
+    workflow_doc = Document2.objects.create(name=name, type='oozie-workflow2', owner=user, data=data, managed=True)
     Document.objects.link(workflow_doc, owner=workflow_doc.owner, name=workflow_doc.name, description=workflow_doc.description, extra='workflow2')
 
     return workflow_doc

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 2 - 7
apps/oozie/src/oozie/views/editor2.py


이 변경점에서 너무 많은 파일들이 변경되어 몇몇 파일들은 표시되지 않았습니다.