Added a update method to the item editor directive