AllDayFantasy/adf — pull request #46 by reedwhitcraft (2012-12-20 22:25:37+00:00)
Title: changes to team edit page (sort, new table, etc) and friends games on front page

whattttup....

there is one part with repetitive (and ugly, I know I know) code (in views/teams/edit)... I iterate over @team.athletes 5 times, with an IF statement for each position, because I needed the divs to be outside of the loop, rather than be created dynamically.

That is, if a user's team did not have a SG (when he first creates his team, for example), the page would at least create an empty div with an id associated with that position (SG) so that when a user adds a SG, the div is there for the ajax magic to find and put in the athletes pic card. If there is no div, it wouldn't work... I'm sure it's an easy fix, but I thought I should at least do the pull request first, cause I said I would.