edit and view modes fully functional