Fix form layouts by not overriding things that shouldn't be
authorMagnus Hagander <magnus@hagander.net>
Sun, 18 Aug 2013 17:11:06 +0000 (19:11 +0200)
committerMagnus Hagander <magnus@hagander.net>
Sun, 18 Aug 2013 17:11:06 +0000 (19:11 +0200)
pgcommitfest/commitfest/templates/base_form.html
pgcommitfest/commitfest/views.py

index f51bf760d6a026296e6c65271c3c0590ff2c9533..d4de4bb19f394694f2d6cc6ddfe8a779975c3434 100644 (file)
 div.control-group div.controls ul {
    list-style-type: none;
 }
-div.control-group div.controls ul li {
+form.patchcommentform div.control-group div.controls ul li {
    display: inline;
 }
 div.control-group div.controls ul li label {
    display: inline;
 }
 </style>
-<form class="form-horizontal" method="POST" action=".">{%csrf_token%}
+<form class="form-horizontal {{extraformclass}}" method="POST" action=".">{%csrf_token%}
 {%if form.errors%}
  <div class="alert">Please correct the errors below, and re-submit the form.</div>
 {%endif%}
index 82ff8f167c3f4af3f893fde1381cc77f2e4c76f0..6fc23a1c803683f3292a9c2d3b5b385bee69a421 100644 (file)
@@ -232,6 +232,7 @@ def comment(request, cfid, patchid, what):
                'cf': cf,
                'form': form,
                'patch': patch,
+               'extraformclass': 'patchcommentform',
                'breadcrumbs': [{'title': cf.name, 'href': '/%s/' % cf.pk},
                                                {'title': 'View patch', 'href': '/%s/%s/' % (cf.pk, patch.pk)}],
                'title': "Add %s" % what,