Fixed some bugs related to the edit function and view more function