diff options
Diffstat (limited to 'tbc_error_page/templates')
-rw-r--r-- | tbc_error_page/templates/broken.html | 28 | ||||
-rw-r--r-- | tbc_error_page/templates/deliberate.html | 17 | ||||
-rw-r--r-- | tbc_error_page/templates/error.html | 42 |
3 files changed, 87 insertions, 0 deletions
diff --git a/tbc_error_page/templates/broken.html b/tbc_error_page/templates/broken.html new file mode 100644 index 0000000..841069c --- /dev/null +++ b/tbc_error_page/templates/broken.html @@ -0,0 +1,28 @@ +{% extends "base.html" %} +{% block title %} TBC Broken Links {% endblock %} +{% block content %} + {% if not broken %} + <center><h4> There are no new comments </h4></center> + {% else %} + <h3><u><center>TBC Broken Links Page </center></u></h3> + <h5> Hi <b><u> {{user}} </b><u> </h5> + <a href = "{% url 'tbc_error_page.views.error' %}"> TBC Error Status Page </a> +<p></p> + <table border = 1> + <tr> + <th> Sr no. </th> + <th> Broken Urls </th> + <th> <b> HTTP status error code </th> + </tr> + {% for broken_data in broken %} + <tr> + <td> {{ forloop.counter }} </td> + <td> <a href = {{ broken_data.broken_url }} target = "blank"> {{ broken_data.broken_url }} </a> </td> + <td><b> {{ broken_data.error_status }} </b> error </td> + </tr> + {% endfor %} + + </table> +{% endif %} + +{% endblock %} diff --git a/tbc_error_page/templates/deliberate.html b/tbc_error_page/templates/deliberate.html new file mode 100644 index 0000000..89a8974 --- /dev/null +++ b/tbc_error_page/templates/deliberate.html @@ -0,0 +1,17 @@ +{% extends "base.html" %} +{% block title %} Success {% endblock %} +{% block content %} +<p> You have added following urls as deliberate </p> +<table border = 1> +<th>Urls</th> + +{% for deliberate_links in deliberate %} + +<tr><td> {{ deliberate_links }} </tr></td> + + +{% endfor %} +</table> +<p></p> +<p><a href = "{% url 'tbc_error_page.views.error' %}"> <<< Go back to Error Page </a></p> +{% endblock %} diff --git a/tbc_error_page/templates/error.html b/tbc_error_page/templates/error.html new file mode 100644 index 0000000..237c7f3 --- /dev/null +++ b/tbc_error_page/templates/error.html @@ -0,0 +1,42 @@ +{% extends "base.html" %} +{% block title %} TBC Error Page {% endblock %} + + + </head> + +{% block content %} + <body> + <h3><u><center>TBC Error Page </center></u></h3> + <h5> Hi <b><u>{{ user }} </b></u></h5> + <p><a href = "{% url 'tbc_error_page.views.broken' %}"> TBC Broken Links page </a></p> + {% if not context %} + <center><h4> There are no new errors </h4></center> + {% else %} + <table border = 2> + <tr> + <th> Chapters With errors</th> + <th> Number of errors</th> + <th> Delibrate Errors</th> + </tr> + + <form name = "Send Email" action = "{% url 'tbc_error_page.views.error' %}" method = "POST"> {% csrf_token %} + {% for errors in context %} + <div class = "error""> + + <tr> + + {% if errors.is_deliberate == 0 %} + <td><a href = {{ errors.chapter_url }} target = "blank"> {{ errors.chapter_name }} </a></td> + <td> {{ errors.number_of_errors }} </td> + <td> <input type = "checkbox" name = "deliberate" value = "{{ errors.chapter_url }}"> + {% endif %} + </tr> + </div> + + {% endfor %} + </table> + <br/> + <input class = "btn" type = "submit" value = "Submit"> </input> + </form> +{% endif %} +{% endblock %} |