Fix timezone import for Django < 1.4

This commit is contained in:
Ross Poulton 2013-01-23 12:21:54 +11:00
parent 556cf5d302
commit 127d57e386

View File

@ -17,9 +17,14 @@ from django.contrib.auth.models import User
from django.http import HttpResponse
from django.shortcuts import render_to_response
from django.template import loader, Context
from django.utils import simplejson, timezone
from django.utils import simplejson
from django.views.decorators.csrf import csrf_exempt
try:
from django.utils import timezone
except ImportError:
from datetime import datetime as timezone
from helpdesk.forms import TicketForm
from helpdesk.lib import send_templated_mail, safe_template_context
from helpdesk.models import Ticket, Queue, FollowUp