1
0
Fork 0
mirror of synced 2024-06-29 19:50:26 +12:00

buckets collection

This commit is contained in:
Damodar Lohani 2021-06-14 16:33:28 +05:45
parent a340c4d670
commit aeddd0d070
2 changed files with 82 additions and 0 deletions

View file

@ -1436,6 +1436,87 @@ $collections = [
],
],
],
Database::SYSTEM_COLLECTION_BUCKETS => [
'$collection' => Database::SYSTEM_COLLECTION_COLLECTIONS,
'$id' => Database::SYSTEM_COLLECTION_BUCKETS,
'$permissions' => ['read' => ['*']],
'name' => 'File',
'structure' => true,
'rules' => [
[
'$collection' => Database::SYSTEM_COLLECTION_RULES,
'label' => 'Date Created',
'key' => 'dateCreated',
'type' => Database::SYSTEM_VAR_TYPE_NUMERIC,
'default' => 0,
'required' => false,
'array' => false,
],
[
'$collection' => Database::SYSTEM_COLLECTION_RULES,
'label' => 'Enabled',
'key' => 'enabled',
'type' => Database::SYSTEM_VAR_TYPE_BOOLEAN,
'default' => true,
'required' => false,
'array' => false,
],
[
'$collection' => Database::SYSTEM_COLLECTION_RULES,
'label' => 'Name',
'key' => 'name',
'type' => Database::SYSTEM_VAR_TYPE_TEXT,
'default' => '',
'required' => true,
'array' => false,
],
[
'$collection' => Database::SYSTEM_COLLECTION_RULES,
'label' => 'Adapter',
'key' => 'adapter',
'type' => Database::SYSTEM_VAR_TYPE_TEXT,
'default' => '',
'required' => true,
'array' => false,
],
[
'$collection' => Database::SYSTEM_COLLECTION_RULES,
'label' => 'Maximum File Size',
'key' => 'maximumFileSize',
'type' => Database::SYSTEM_VAR_TYPE_NUMERIC,
'default' => 0,
'required' => true,
'array' => false,
],
[
'$collection' => Database::SYSTEM_COLLECTION_RULES,
'label' => 'Allowed File Extensions',
'key' => 'allowedFileExtensions',
'type' => Database::SYSTEM_VAR_TYPE_TEXT,
'default' => '',
'required' => true,
'array' => false,
],
[
'$collection' => Database::SYSTEM_COLLECTION_RULES,
'label' => 'Encryption',
'key' => 'encrypted',
'type' => Database::SYSTEM_VAR_TYPE_BOOLEAN,
'default' => true,
'required' => true,
'array' => false,
],
[
'$collection' => Database::SYSTEM_COLLECTION_RULES,
'label' => 'Virus Scan',
'key' => 'antivirus',
'type' => Database::SYSTEM_VAR_TYPE_BOOLEAN,
'default' => true,
'required' => true,
'array' => false,
],
],
],
Database::SYSTEM_COLLECTION_FUNCTIONS => [
'$collection' => Database::SYSTEM_COLLECTION_COLLECTIONS,
'$id' => Database::SYSTEM_COLLECTION_FUNCTIONS,

View file

@ -36,6 +36,7 @@ class Database
// Storage
const SYSTEM_COLLECTION_FILES = 'files';
const SYSTEM_COLLECTION_BUCKETS = 'buckets';
// Functions
const SYSTEM_COLLECTION_FUNCTIONS = 'functions';