Added document view functionality