Enforce disk storage quota

The goal is to prevent users from uploading new documents & models when they run out of disk storage.

  • declare setting QUOTA_DISK_STORAGE, default to None, and should be configured as a positive integer in MegaBytes
  • implement has_free_storage on the User model to check that the user has some free storage left on its account.
  • display on the user quotas page a danger notification when there are no disk storage left
  • prevent user from uploading Documents when quota is reached
  • prevent user from uploading models when quota is reached

When the setting is set to None, no quota is enforced