added update of task.weight to onclick of buttons