Sha256: 448a589fdd903bb31e2d86544e46795444f6ea6e749a05b27404474f4a018908
Contents?: true
Size: 1.81 KB
Versions: 12
Compression:
Stored size: 1.81 KB
Contents
<% @is_model_controller = controller.class.included_modules.include?(RESTFramework::ModelControllerMixin) %> <div class="row"> <div> <ul class="nav nav-tabs"> <li class="nav-item"> <a class="nav-link active" href="#tab-routes" data-bs-toggle="tab" role="tab"> Routes </a> </li> <% @_rrf_form_routes_raw = @route_groups.values[0].select { |r| r[:matches_params] && ( r[:verb].in?(["POST", "PUT", "PATCH"]) || (r[:verb] == "DELETE" && r[:action] == "destroy_all") ) } %> <% @_rrf_form_routes_html = @route_groups.values[0].select { |r| r[:matches_params] && r[:verb].in?(["POST", "PUT", "PATCH"]) } %> <% if @_rrf_form_routes_raw.present? %> <li class="nav-item"> <a class="nav-link" href="#tabRawForm" data-bs-toggle="tab" role="tab"> Raw Form </a> </li> <% end %> <% if @_rrf_form_routes_html.present? && @is_model_controller %> <li class="nav-item"> <a class="nav-link" href="#tabHtmlForm" data-bs-toggle="tab" role="tab"> HTML Form </a> </li> <% end %> </ul> </div> <div class="tab-content"> <div class="tab-pane fade show active" id="tab-routes" role="tabpanel"> <%= render partial: "rest_framework/routes_and_forms/routes" %> </div> <% if @_rrf_form_routes_raw.present? %> <div class="tab-pane fade" id="tabRawForm" role="tabpanel"> <%= render partial: "rest_framework/routes_and_forms/raw_form" %> </div> <% end %> <% if @_rrf_form_routes_html.present? && @is_model_controller %> <div class="tab-pane fade" id="tabHtmlForm" role="tabpanel"> <%= render partial: "rest_framework/routes_and_forms/html_form" %> </div> <% end %> </div> </div>
Version data entries
12 entries across 12 versions & 1 rubygems