Merge branch '2755-python-sdk-permissions'
[arvados.git] / apps / workbench / app / controllers / pipeline_instances_controller.rb
index 4853b0aaf1c6bcff43ae6f8663308f45ce4b3ef5..761dc914145904ca92a01ab28fceb8a9e2acd674 100644 (file)
@@ -50,17 +50,6 @@ class PipelineInstancesController < ApplicationController
     return provenance, pips
   end
 
-  def create
-    @object = PipelineInstance.new params[:pipeline_instance]
-    @object.save!
-    if !@object.components.andand.any? and @object.pipeline_template_uuid
-      template = PipelineTemplate.find(@object.pipeline_template_uuid)
-      @object.components = template.components.deep_dup
-      @object.save!
-    end
-    super
-  end
-
   def show
     @pipelines = [@object]
 
@@ -153,7 +142,11 @@ class PipelineInstancesController < ApplicationController
   end
 
   def show_pane_list
-    %w(Components Graph Attributes Metadata JSON API)
+    panes = %w(Components Graph Attributes Metadata JSON API)
+    if @object and @object.state.in? ['New', 'Ready']
+      panes = %w(Inputs) + panes
+    end
+    panes
   end
 
   def compare_pane_list 
@@ -161,7 +154,7 @@ class PipelineInstancesController < ApplicationController
   end 
 
   def index
-    @objects ||= model_class.limit(20).all
+    @limit = 20
     super
   end