Sha256: c0c468cdfda61fec2c68a6b1354156b87f42bae89445d5fc65232f9a19d83b5b

Contents?: true

Size: 1006 Bytes

Versions: 31

Compression:

Stored size: 1006 Bytes

Contents

<%= webpacked_plugins_js_for :foreman_ansible %>
<%= webpacked_plugins_css_for :foreman_ansible %>

<div class='tab-pane' id='ansible_roles'>
  <% roles = f.object.is_a?(Hostgroup) ? roles_attrs(f.object.inherited_and_own_ansible_roles) : roles_attrs(f.object.all_ansible_roles) %>
  <% class_name = f.object.is_a?(Hostgroup) ? 'Hostgroup' : 'Host' %>
  <%= content_tag(:div, '',
                  :id => 'ansible_roles_switcher',
                  'data-roles' => {
                    :initialAssignedRoles => roles,
                    :inheritedRoleIds => f.object.inherited_ansible_roles.map(&:id),
                    :availableRolesUrl => ui_ansible_roles_path,
                    :resourceId => f.object.id,
                    :resourceName => class_name,
                    :canView => User.current.can?(:view_ansible_roles)
                  }.to_json
  ) %>
  <% unless request.xhr? %>
    <script type="text/javascript">
      tfm.initAnsibleRoleSwitcher();
    </script>
  <% end %>
</div>

Version data entries

31 entries across 31 versions & 1 rubygems

Version Path
foreman_ansible-6.1.1 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-6.0.2 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-6.1.0 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-6.0.1 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-5.1.3 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-6.0.0 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-5.1.2 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-5.1.1 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-5.1.0 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-4.0.3.5 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-4.0.3.4 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-4.0.3.3 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-4.0.3.2 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-5.0.1 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-4.0.5 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-4.0.3.1 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-4.0.4 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-5.0.0 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-4.0.3 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb
foreman_ansible-4.0.2 app/views/foreman_ansible/ansible_roles/_select_tab_content.html.erb