Author: humbedooh
Date: Wed Mar 25 01:57:44 2015
New Revision: 1669044

URL: http://svn.apache.org/r1669044
Log:
a temp fix since I broke the JSON structure a few hours ago

Modified:
    steve/trunk/pysteve/www/htdocs/js/steve_rest.js

Modified: steve/trunk/pysteve/www/htdocs/js/steve_rest.js
URL: 
http://svn.apache.org/viewvc/steve/trunk/pysteve/www/htdocs/js/steve_rest.js?rev=1669044&r1=1669043&r2=1669044&view=diff
==============================================================================
--- steve/trunk/pysteve/www/htdocs/js/steve_rest.js (original)
+++ steve/trunk/pysteve/www/htdocs/js/steve_rest.js Wed Mar 25 01:57:44 2015
@@ -724,7 +724,7 @@ function renderElectionFrontpage(respons
                inner.innerHTML = issue.id + ": " + issue.title;
                outer.appendChild(no)
                outer.appendChild(inner)
-               outer.setAttribute("onclick", "location.href='ballot_" + 
issue.category + ".html?" + el[0] + "/" + issue.id + "/" + (el[1] ? el[1] : "") 
+ "';")
+               outer.setAttribute("onclick", "location.href='ballot_" + 
(issue.category ? issue.category : issue.type.match(/([a-z]+)/)[0]) + ".html?" 
+ el[0] + "/" + issue.id + "/" + (el[1] ? el[1] : "") + "';")
                outer.style.animation = "fadein " + (0.5 +  (s/6)) + "s"
                issueList.appendChild(outer)
        }


Reply via email to