I am currently doing the board for a battleship game on ruby on rails. I am stuck on how to change the color of the table cell (depending which of the values in the array @actions is inside. I tryed using case statement and if'statement in the html.erb but I cant work out the right syntax. And another thing I am wondering: should I do a helper method for this and use it in the html, instead of coding in there?
Here is the repo http://ift.tt/2s2hKxs
Aucun commentaire:
Enregistrer un commentaire