In index.html.erb we produce a link that triggers an ajax action when clicked by means of :remote => true. In this example the entity or model is Day and the action is total.
Notice that we render day.id as id for the html element we want to manipulate. This is how we could identify and work with that specific element (any element in the identified row).
In myaction.js.erb we can use JQuery to manipulate the dom and html elements with the powerful help of Rails bindings.