Merge pull request #1641 from javins/login-title

Refactor login template to extend base.
This commit is contained in:
Tom Christie 2014-08-18 20:28:34 +01:00
commit c092b4df78
3 changed files with 6 additions and 12 deletions

View File

@ -69,6 +69,7 @@ For more specific CSS tweaks than simply overriding the default bootstrap theme
All of the blocks available in the browsable API base template that can be used in your `api.html`. All of the blocks available in the browsable API base template that can be used in your `api.html`.
* `body` - The entire html `<body>`.
* `bodyclass` - Class attribute for the `<body>` tag, empty by default. * `bodyclass` - Class attribute for the `<body>` tag, empty by default.
* `bootstrap_theme` - CSS for the Bootstrap theme. * `bootstrap_theme` - CSS for the Bootstrap theme.
* `bootstrap_navbar_variant` - CSS class for the navbar. * `bootstrap_navbar_variant` - CSS class for the navbar.

View File

@ -24,6 +24,7 @@
{% endblock %} {% endblock %}
</head> </head>
{% block body %}
<body class="{% block bodyclass %}{% endblock %} container"> <body class="{% block bodyclass %}{% endblock %} container">
<div class="wrapper"> <div class="wrapper">
@ -230,4 +231,5 @@
<script src="{% static "rest_framework/js/default.js" %}"></script> <script src="{% static "rest_framework/js/default.js" %}"></script>
{% endblock %} {% endblock %}
</body> </body>
{% endblock %}
</html> </html>

View File

@ -1,17 +1,8 @@
{% extends "rest_framework/base.html" %}
{% load url from future %} {% load url from future %}
{% load rest_framework %} {% load rest_framework %}
<html>
<head>
{% block style %}
{% block bootstrap_theme %}
<link rel="stylesheet" type="text/css" href="{% static "rest_framework/css/bootstrap.min.css" %}"/>
<link rel="stylesheet" type="text/css" href="{% static "rest_framework/css/bootstrap-tweaks.css" %}"/>
{% endblock %}
<link rel="stylesheet" type="text/css" href="{% static "rest_framework/css/default.css" %}"/>
{% endblock %}
</head>
{% block body %}
<body class="container"> <body class="container">
<div class="container-fluid" style="margin-top: 30px"> <div class="container-fluid" style="margin-top: 30px">
@ -50,4 +41,4 @@
</div><!-- /.row-fluid --> </div><!-- /.row-fluid -->
</div><!-- /.container-fluid --> </div><!-- /.container-fluid -->
</body> </body>
</html> {% endblock %}