使用django-pendulum并尝试使用最新的Django 1.6。使用示例空白项目,它似乎打破了试图反转网址。我甚至逃过模板中的{url ..}语法,但没有运气。关于如何修复这个问题的任何想法w / 1.6?它工作在1.5!
编辑 - 这是错误:
NoReverseMatch at /pendulum/
Reverse for 'pendulum-clock-in' with arguments '()' and keyword arguments '{}' not found. 0 pattern(s) tried: []
Request Method: GET
Request URL: http://localhost:8000/pendulum/
Django Version: 1.6
Exception Type: NoReverseMatch
Exception Value:
Reverse for 'pendulum-clock-in' with arguments '()' and keyword arguments '{}' not found. 0 pattern(s) tried: []
和
Error during template rendering
In template C:\Python27\lib\site-packages\django_pendulum-0.1.6_pre4-py2.7.egg\pendulum\templates\pendulum\pendulum_base.html, error at line 8
Reverse for 'pendulum-clock-in' with arguments '()' and keyword arguments '{}' not found. 0 pattern(s) tried: []
1 {% extends 'base.html' %}
2
3 {% block content %}
4 {% block pendulum-controls %}
5 <div id="pendulum-controls">
6 <ul class="pendulum-controls">
7 {# <li><strong>{{ emp }}</strong></li>#}
8 <li><a href="{% url 'pendulum-clock-in' %}">Clock In</a></li>