finish index and view