<commit_before>- if @record.try(:name)
  #accordion.panel-group
    = miq_accordion_panel(truncate(@record.name, :length => truncate_length), true, "icon") do
      = render :partial => "layouts/quadicon", :locals => {:mode => :icon, :item => @record, :size => 72, :typ => :listnav}

    = miq_accordion_panel(_("Properties"), false, "ems_prop") do
      %ul.nav.nav-pills.nav-stacked
        %li
          = link_to(_('Summary'),
            {:action => 'show', :id => @record, :display => 'main'},
            :title => _("Show Summary"))

    = miq_accordion_panel(_("Relationships"), false, "ems_rel") do
      %ul.nav.nav-pills.nav-stacked
        - if role_allows(:feature => "ems_cloud_show") && @record.ext_management_system
          %li
            = link_to("#{ui_lookup(:table => "ext_management_systems")}: #{@record.ext_management_system.name}",
              ems_cloud_path(@record.ext_management_system.id),
              :title => _("Show this Flavor's parent %s") % ui_lookup(:table => "ems_cloud"))

        - if role_allows(:feature => "vm_show_list")
          - if @record.number_of(:vms) == 0
            %li.disabled
              = link_to(_("Instances (%s)") % @record.number_of(:vms), "#")
          - else
            %li
              = link_to(_("Instances (%s)") % @record.number_of(:vms),
                {:action => 'show', :id => @record, :display => 'instances'},
                :title => _("Show all Instances"))<commit_msg>Refactor listnav of Flavors (transferred from ManageIQ/manageiq@4<PASSWORD>22bb<PASSWORD>)<commit_after>- if @record.try(:name)
  #accordion.panel-group
    = miq_accordion_panel(truncate(@record.name, :length => truncate_length), true, "icon") do
      = render :partial => "layouts/quadicon", :locals => {:mode => :icon, :item => @record, :size => 72, :typ => :listnav}

    = miq_accordion_panel(_("Properties"), false, "ems_prop") do
      %ul.nav.nav-pills.nav-stacked
        %li
          = link_to(_('Summary'),
            {:action => 'show', :id => @record, :display => 'main'},
            :title => _("Show Summary"))

    = miq_accordion_panel(_("Relationships"), false, "ems_rel") do
      %ul.nav.nav-pills.nav-stacked
        - if role_allows(:feature => "ems_cloud_show") && @record.ext_management_system
          %li
            = link_to("#{ui_lookup(:table => "ext_management_systems")}: #{@record.ext_management_system.name}",
              ems_cloud_path(@record.ext_management_system.id),
              :title => _("Show this Flavor's parent %s") % ui_lookup(:table => "ems_cloud"))

        - if role_allows(:feature => "vm_show_list")
          = li_link_if_nonzero(:count     => @record.number_of(:vms),
                               :text      => _("Instances"),
                               :record_id => @record.id,
                               :display   => 'instances',
                               :title     => _("Show all Instances"))
{'fraction_non_alphanumeric': 0.17364657814096016, 'fraction_numerical': 0.002723867892407218, 'mean_word_length': 2.5440289505428226, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 46, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '663357', 'n_tokens_mistral': 959, 'n_tokens_neox': 916, 'n_words': 165}