Fixing loading of previous application. Also adding autosave functionality, which is a bit hackish currently. Autosave doesn't currently work as we have a bug in the application_autosave method in the application entity.