history
This commit is contained in:
parent
c05fe944c0
commit
d8838dbefb
|
@ -6,4 +6,5 @@ urlpatterns = patterns('',
|
|||
(r'^show/(\d+)/$', 'buyable.views.showItem'),
|
||||
(r'^buy/(\d+)/(|with/deposit|only/deposit)/?$', 'buyable.views.buyItem'),
|
||||
(r'^bought/(\d+)/?$', 'buyable.views.boughtItem'),
|
||||
(r'^history/?$', 'buyable.views.history'),
|
||||
)
|
||||
|
|
|
@ -61,3 +61,8 @@ def boughtItem(request, orderid):
|
|||
item1 = None
|
||||
error = u"Diese Items gehören dir nicht"
|
||||
return render_to_response("buyables/itemBought.html", {'order': item, 'error': error}, RequestContext(request))
|
||||
|
||||
@login_required
|
||||
def history(request):
|
||||
hist = Order.objects.filter(user=request.user.id).order_by("-dateTime")
|
||||
return render_to_response("buyables/history.html", {'history': hist}, RequestContext(request))
|
||||
|
|
Loading…
Reference in New Issue