Skip to content

Commit

Permalink
Clean up python logic, fix default year
Browse files Browse the repository at this point in the history
  • Loading branch information
lbeaufort committed Feb 19, 2020
1 parent c6a5b90 commit 1f1fc42
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions fec/data/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -682,30 +682,24 @@ def spending(request):


def pres_finance_map(request):
# office = request.GET.get("office", "P")

election_year = int(
request.GET.get("election_year", constants.DEFAULT_ELECTION_YEAR)
request.GET.get("election_year", constants.DEFAULT_PRESIDENTIAL_YEAR)
)

# max_election_year = utils.current_cycle() + 4
# election_years = utils.get_cycles(max_election_year)

return render(
request,
"pres-finance-map.jinja",
{
"parent": "data",
"title": "Presidential Campaign Finance Map",
# "election_years": election_years,
"election_year": election_year,
# "office": "P",
"social_image_identifier": "data",
"page_specific_css": "/static/css/widgets/pres-finance-map.css",

},
)

def feedback(request):
if request.method == "POST":

Expand Down

0 comments on commit 1f1fc42

Please sign in to comment.