summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMilosz Wasilewski <milosz.wasilewski@linaro.org>2013-09-25 10:21:36 +0100
committerMilosz Wasilewski <milosz.wasilewski@linaro.org>2013-09-25 11:10:41 +0100
commit2dcc848ed3f36b98257bf1b2ed5a40b3a85e412b (patch)
tree896f158def3484e26750e2ed1276dbef10267424
parent7285cc7df102617cfcdc9b47a63ef3b477f1a080 (diff)
downloadroadmap-2dcc848ed3f36b98257bf1b2ed5a40b3a85e412b.tar.gz
PEP8 fixes
Change-Id: I2be7db0d53aa13a3f9a8d01eb094871e379fc592
-rw-r--r--roadmap/views.py20
1 files changed, 11 insertions, 9 deletions
diff --git a/roadmap/views.py b/roadmap/views.py
index 3f3c4e1..7966023 100644
--- a/roadmap/views.py
+++ b/roadmap/views.py
@@ -57,7 +57,8 @@ def index(request):
releases = RoadmapRelease.objects.all().order_by("-date")
form = RoadmapForm()
major_milestones = Milestone.objects.filter(is_major=True).order_by("date")
- from_milestone = major_milestones.filter(date__lte=datetime.now()).order_by("-date")[0]
+ from_milestone = major_milestones.filter(
+ date__lte=datetime.now()).order_by("-date")[0]
to_milestone = major_milestones.filter(date__gt=datetime.now())[0]
# leave this section for now although should not be used from UI
@@ -114,14 +115,14 @@ def index(request):
burndown_line = []
if days_between_milestones > 0:
- a = float(-(float(total_max)/float(days_between_milestones)))
+ a = float(-(float(total_max) / float(days_between_milestones)))
for point in range(0, days_between_milestones):
- value = a*point + total_max
+ value = a * point + total_max
burndown_line.append(value)
tick_interval = 10
if days_between_milestones > 20:
- tick_interval = days_between_milestones/10
+ tick_interval = days_between_milestones / 10
display_burndown_series = []
for serie_name in settings.JIRA_STATUSES:
@@ -152,12 +153,13 @@ def status(request, roadmap_id):
releases = RoadmapRelease.objects.all().order_by("-date")
form = RoadmapForm()
major_milestones = Milestone.objects.filter(is_major=True).order_by("date")
- from_milestone = major_milestones.filter(date__lte=datetime.now()).order_by("-date")[0]
+ from_milestone = major_milestones.filter(
+ date__lte=datetime.now()).order_by("-date")[0]
to_milestone = major_milestones.filter(date__gt=datetime.now())[0]
component = Component.objects.get(pk=roadmap_id)
statuses = Status.objects.filter(
project=component.project).order_by("display_order")
-
+
# leave this section for now although should not be used from UI
if (request.GET and 'from' in request.GET.keys()
and 'end' in request.GET.keys()):
@@ -213,9 +215,9 @@ def status(request, roadmap_id):
burndown_line = []
if days_between_milestones > 0:
- a = float(-(float(total_max)/float(days_between_milestones)))
+ a = float(-(float(total_max) / float(days_between_milestones)))
for point in range(0, days_between_milestones):
- value = a*point + total_max
+ value = a * point + total_max
burndown_line.append(value)
display_burndown_series = []
@@ -226,7 +228,7 @@ def status(request, roadmap_id):
tick_interval = 10
if days_between_milestones > 20:
- tick_interval = days_between_milestones/10
+ tick_interval = days_between_milestones / 10
roadmap_cards = Card.objects.filter(
components__in=[component],