diff options
| author | Tom Christie | 2013-08-23 14:38:31 +0100 | 
|---|---|---|
| committer | Tom Christie | 2013-08-23 14:38:31 +0100 | 
| commit | 0966a2680ba02e6a4586bd2777ed593fcc66a453 (patch) | |
| tree | a40ecb15e4fb44a140f1c04bd634bb2c820418fb /rest_framework/templates | |
| parent | f54fc3a76bdb872eb3b0ba562db08e3fd7c879af (diff) | |
| download | django-rest-framework-0966a2680ba02e6a4586bd2777ed593fcc66a453.tar.bz2 | |
First pass at HTMLFormRenderer
Diffstat (limited to 'rest_framework/templates')
| -rw-r--r-- | rest_framework/templates/rest_framework/base.html | 10 | 
1 files changed, 4 insertions, 6 deletions
diff --git a/rest_framework/templates/rest_framework/base.html b/rest_framework/templates/rest_framework/base.html index 51f9c291..6ae47563 100644 --- a/rest_framework/templates/rest_framework/base.html +++ b/rest_framework/templates/rest_framework/base.html @@ -136,9 +136,9 @@                          {% if post_form %}                          <div class="tab-pane" id="object-form">                              {% with form=post_form %} -                            <form action="{{ request.get_full_path }}" method="POST" {% if form.is_multipart %}enctype="multipart/form-data"{% endif %} class="form-horizontal"> +                            <form action="{{ request.get_full_path }}" method="POST" enctype="multipart/form-data" class="form-horizontal">                                  <fieldset> -                                    {% include "rest_framework/form.html" %} +                                    {{ post_form }}                                      <div class="form-actions">                                          <button class="btn btn-primary" title="Make a POST request on the {{ name }} resource">POST</button>                                      </div> @@ -174,16 +174,14 @@                      <div class="well tab-content">                          {% if put_form %}                          <div class="tab-pane" id="object-form"> -                            {% with form=put_form %} -                            <form action="{{ request.get_full_path }}" method="POST" {% if form.is_multipart %}enctype="multipart/form-data"{% endif %} class="form-horizontal"> +                            <form action="{{ request.get_full_path }}" method="POST" enctype="multipart/form-data" class="form-horizontal">                                  <fieldset> -                                    {% include "rest_framework/form.html" %} +                                    {{ put_form }}                                      <div class="form-actions">                                          <button class="btn btn-primary js-tooltip" name="{{ api_settings.FORM_METHOD_OVERRIDE }}" value="PUT" title="Make a PUT request on the {{ name }} resource">PUT</button>                                      </div>                                  </fieldset>                              </form> -                            {% endwith %}                          </div>                          {% endif %}                          <div {% if put_form %}class="tab-pane"{% endif %} id="generic-content-form">  | 
