summaryrefslogtreecommitdiff
path: root/taskapp/views/task.py
diff options
context:
space:
mode:
authornishanth2010-03-02 16:20:28 +0530
committernishanth2010-03-02 16:20:28 +0530
commit3a43223126b7c9665522c314d526579da5dcaee2 (patch)
treea240f964958a238dadcf297ee201f86081b5dbc3 /taskapp/views/task.py
parent84ce5a608dbac2797d86de88c8331b173ade26c0 (diff)
downloadpytask-3a43223126b7c9665522c314d526579da5dcaee2.tar.gz
pytask-3a43223126b7c9665522c314d526579da5dcaee2.tar.bz2
pytask-3a43223126b7c9665522c314d526579da5dcaee2.zip
fixed a bug in edit_task view.
Diffstat (limited to 'taskapp/views/task.py')
-rw-r--r--taskapp/views/task.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/taskapp/views/task.py b/taskapp/views/task.py
index 0b0984b..aadaa4b 100644
--- a/taskapp/views/task.py
+++ b/taskapp/views/task.py
@@ -152,7 +152,7 @@ def create_task(request):
else:
return show_msg(user, 'You are not authorised to create a task.')
else:
- return show_msg(user, 'You are not authorised to create a task.')
+ return show_msg(user, 'You are not authorised to create a task.', "/", "home page")
def add_mentor(request, tid):
""" check if the current user has the rights to edit the task and add him.
@@ -521,7 +521,8 @@ def edit_task(request, tid):
and then give the user fields accordingly.
"""
- task = Task.objects.get(id=tid)
+ task = getTask(tid)
+
task_url = "/task/view/tid=%s"%tid
user = get_user(request.user) if request.user.is_authenticated() else request.user