Skip to content

Commit

Permalink
Merge pull request mozilla#142 from rossbruniges/stage
Browse files Browse the repository at this point in the history
Fix broken logic and a quick test hack
  • Loading branch information
rossbruniges committed Apr 5, 2013
2 parents ea5b3a1 + 810deb1 commit f6fd4bc
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 2 deletions.
4 changes: 4 additions & 0 deletions apps/challenges/models.py
Expand Up @@ -143,6 +143,10 @@ def get_absolute_url(self):
slug = 'ideas' if self.is_ideation else 'apps'
return ('entries_all', [slug])

@cached_property
def hacked_PST_enddate(self):
return self.end_date - relativedelta(hours=8)

@cached_property
def days_remaining(self):
now = datetime.utcnow()
Expand Down
9 changes: 7 additions & 2 deletions apps/ignite/templates/ignite/about.html
Expand Up @@ -25,10 +25,15 @@ <h2 class="announce trigger">What is the Mozilla Ignite Challenge?</h2>
<div class="highlight">
{% if request.development.is_open %}
<h3 class="point box-title">Now through {{ request.development.current_round.end_date.strftime('%B %-d') }}: submit your app proposals or further develop your existing application.</h3>
<p>Time to start hacking: we're offering $485,000 in prizes & support for teams over three rounds.</p>
{% else %}
<h3 class="point box-title">{{ request.development.next_round.start_date.strftime('%B %-d') }} through {{ request.development.next_round.end_date.strftime('%B %-d') }}: submit your app proposals or further develop your existing application.</h3>
{% if development.next_round %}
<h3 class="point box-title">{{ request.development.next_round.start_date.strftime('%B %-d') }} through {{ request.development.next_round.end_date.strftime('%B %-d') }}: submit your app proposals or further develop your existing application.</h3>
<p>Time to start hacking: we're offering $485,000 in prizes & support for teams over three rounds.</p>
{% else %}
<p class="point box-title">We're currently judging the last round, we'll soon be announcing the final winners.</p>
{% endif %}
{% endif %}
<p>Time to start hacking: we're offering $485,000 in prizes & support for teams over three rounds.</p>
{% if request.ideation.is_open %}
<a class="cta" href="{{ url('create_entry', phase='ideas') }}">Submit your idea now</a>
{% endif %}
Expand Down
1 change: 1 addition & 0 deletions apps/ignite/templates/ignite/splash.html
Expand Up @@ -28,6 +28,7 @@ <h2 class="busta">
{% if development.is_open %}
<a href="{{ url('create_entry', phase='apps') }}" class="cta">Apply now</a><br />
Apply by {{ request.development.current_round.end_date.strftime('%B %-d') }} to compete in this round
Apply by {{ request.development.current_round.hacked_PST_enddate.strftime('%B %-d') }} to compete in this round
{% else %}
{% if development.has_started %}
We're currently judging the last round, we'll soon be announcing the final winners.
Expand Down

0 comments on commit f6fd4bc

Please sign in to comment.