Centralized the saving/deletion of views.