Moved modal to template