add edit post method in view