+ solve_question: (question) ->
+ solution = @get_value_list(question, 'solution')
+ $(".question-piece", question).each (i, qpiece) =>
+ piece_no = $(qpiece).attr 'data-no'
+ piece_name = $(qpiece).attr 'data-name'
+ if piece_name
+ should_be_checked = solution.indexOf(piece_name) >= 0
+ else
+ should_be_checked = solution.indexOf(piece_no) >= 0
+ console.log("check " + $("input[type=checkbox]", qpiece).attr("id") + " -> " + should_be_checked)
+ $("input[type=checkbox]", qpiece).prop 'checked', should_be_checked