sets up sortable tables and edit forms