major update
This commit is contained in:
Binary file not shown.
@@ -53,7 +53,7 @@ def citizen_dashboard(request):
|
||||
'categories': categories,
|
||||
'issue_form': IssueForm(),
|
||||
}
|
||||
return render(request, 'core/citizen_dashboard.html', context)
|
||||
return render(request, 'dashboard/citizen_dashboard.html', context)
|
||||
|
||||
@login_required
|
||||
def report_issue(request):
|
||||
@@ -101,7 +101,7 @@ def view_all_issues(request):
|
||||
if category_id:
|
||||
issues = issues.filter(category_id=category_id)
|
||||
|
||||
return render(request, 'core/view_all_issues.html', {
|
||||
return render(request, 'issues/view_all_issues.html', {
|
||||
'issues': issues,
|
||||
'categories': categories,
|
||||
'selected_status': status,
|
||||
@@ -183,7 +183,7 @@ def add_comment(request, pk, parent_id=None):
|
||||
def issue_detail(request, pk):
|
||||
issue = get_object_or_404(Issue, pk=pk)
|
||||
comments = issue.comments.filter(parent__isnull=True) # top-level comments
|
||||
return render(request, "core/issue_detail.html", {"issue": issue, "comments": comments})
|
||||
return render(request, "issues/issue_detail.html", {"issue": issue, "comments": comments})
|
||||
|
||||
def add_comment(request, pk, parent_id=None):
|
||||
if request.method == "POST" and request.user.is_authenticated:
|
||||
@@ -202,7 +202,7 @@ def superadmin_check(user):
|
||||
@login_required
|
||||
@user_passes_test(superadmin_check)
|
||||
def superadmin_dashboard(request):
|
||||
return render(request, "core/superadmin_dashboard.html")
|
||||
return render(request, "dashboard/superadmin_dashboard.html")
|
||||
|
||||
|
||||
@login_required
|
||||
@@ -217,7 +217,7 @@ def manage_departments(request):
|
||||
Department.objects.create(name=name, description=description)
|
||||
return redirect("manage_departments")
|
||||
|
||||
return render(request, "core/manage_departments.html", {
|
||||
return render(request, "department/manage_departments.html", {
|
||||
"departments": departments
|
||||
})
|
||||
|
||||
@@ -242,7 +242,7 @@ def department_detail(request, pk):
|
||||
department.users.add(user)
|
||||
return redirect("department_detail", pk=department.id)
|
||||
|
||||
return render(request, "core/department_detail.html", {
|
||||
return render(request, "department/department_detail.html", {
|
||||
"department": department,
|
||||
"users": users,
|
||||
})
|
||||
Reference in New Issue
Block a user