added update functionality, in spec, controller and views