Skip to content

Commit

Permalink
Add UI support for Pod to PV relationship
Browse files Browse the repository at this point in the history
refactored small mistakes

refactored small mistakes
  • Loading branch information
nimrodshn committed Mar 14, 2017
1 parent 4ac7d0b commit 3b9974a
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
7 changes: 6 additions & 1 deletion app/helpers/persistent_volume_helper/textual_summary.rb
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def textual_group_claim_properties
end

def textual_group_relationships
TextualGroup.new(_("Relationships"), %i(parent))
TextualGroup.new(_("Relationships"), %i(parent pods_using_persistent_volume))
end

def textual_group_smart_management
Expand All @@ -40,6 +40,11 @@ def textual_group_capacity
#
# Items
#
def textual_pods_using_persistent_volume
link = url_for_only_path(:id => @record.id, :action => "show", :display => "container_groups")
textual_link(@record.container_groups, :as => ContainerGroup, :link => link)
end

def textual_resource_version
@record.resource_version
end
Expand Down
2 changes: 1 addition & 1 deletion app/views/persistent_volume/show.html.haml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
- if @display == 'containers'
- if %w(containers, container_groups).include?(@display)
= render :partial => "layouts/gtl", :locals => {:action_url => "show/#{@record.id}"}
- elsif @showtype == 'main'
= render :partial => "layouts/textual_groups_generic"

0 comments on commit 3b9974a

Please sign in to comment.