PageRenderTime 15ms CodeModel.GetById 12ms RepoModel.GetById 1ms app.codeStats 0ms

/templates/community_rating.mako

https://bitbucket.org/cistrome/cistrome-harvard/
Mako | 33 lines | 32 code | 1 blank | 0 comment | 0 complexity | 88bcc60a7dfa20b0e0a677c6399a7bb6 MD5 | raw file
  1. <%
  2. label = "ratings"
  3. if num_ratings == 1:
  4. label = "rating"
  5. %>
  6. <div>
  7. <input name="star1-${item_id}" type="radio" class="community_rating_star star" disabled="disabled" value="1"
  8. %if ave_item_rating > 0 and ave_item_rating <= 1.5:
  9. checked="checked"
  10. %endif
  11. />
  12. <input name="star1-${item_id}" type="radio" class="community_rating_star star" disabled="disabled" value="2"
  13. %if ave_item_rating > 1.5 and ave_item_rating <= 2.5:
  14. checked="checked"
  15. %endif
  16. />
  17. <input name="star1-${item_id}" type="radio" class="community_rating_star star" disabled="disabled" value="3"
  18. %if ave_item_rating > 2.5 and ave_item_rating <= 3.5:
  19. checked="checked"
  20. %endif
  21. />
  22. <input name="star1-${item_id}" type="radio" class="community_rating_star star" disabled="disabled" value="4"
  23. %if ave_item_rating > 3.5 and ave_item_rating <= 4.5:
  24. checked="checked"
  25. %endif
  26. />
  27. <input name="star1-${item_id}" type="radio" class="community_rating_star star" disabled="disabled" value="5"
  28. %if ave_item_rating > 4.5:
  29. checked="checked"
  30. %endif
  31. />
  32. </div>