<%= render partial: "rest_framework/head" %>

<%= (@header_text if defined? @header_text) || @title %>

<% if @route_groups.values[0].any? { |r| r[:matches_path] && r[:verb] == "DELETE" } %> <% end %> <% if @route_groups.values[0].any? { |r| r[:matches_path] && r[:verb] == "OPTIONS" } %> <% end %>
<% if @description.present? %>

<%= @description %>

<% end %>

            
              
                <%= request.request_method %>
                <% if request.method != request.request_method %>
                  (via <%= request.method %>)
                <% end %>
               <%= request.path %>
            
              HTTP <%= response.status %> <%= response.message %>
Content-Type: <%= response.content_type %>
<% if @json_payload.present? || @xml_payload.present? %>
<% if @json_payload.present? %>
<%=
                  JSON.pretty_generate(
                    JSON.parse(@json_payload)
                  ) unless @json_payload == ''
                %>
<% end %>
<% if @xml_payload.present? %>
<%=
                  CGI.unescapeHTML(@xml_payload)
                %>
<% end %>
<% end %> <% if @route_groups.present? %> <% @is_model_controller = controller.class.included_modules.include?(RESTFramework::ModelControllerMixin) %>
<%= render partial: "rest_framework/routes" %>
<% unless @_rrf_form_routes.empty? %>
<%= render partial: "rest_framework/raw_form" %>
<% if @is_model_controller %>
<%= render partial: "rest_framework/html_form" %>
<% end %> <% end %>
<% end %>