* Update knex to version 2.0.0
Fixes#10842
* Remove unused optional dependencies
* Update sqlite3 to version 5.0.6
* Fix returning primary key when inserting items into database
* first attempt at nested sorting
* pull out addJoin so it can be reused
* Move get-relation-info to file, add tests
* Extract get-column-path, add tests
* Little cleanup
* Prevent the regex from blowing up with malicious input
* Allow sorting on m2o fields in the tabular layout
Co-authored-by: rijkvanzanten <rijkvanzanten@me.com>
* add basic util function for later use
* sketch up useRelationMultiple implementation
* update relation util and start reworking relational interfaces
* support filter in m2o
* start working on useRelationMultiple
* continue working on relational foundation
* finish basic use-relation-multiple composable
* get o2m pretty close to being finished
* finish up list-o2m
* replace old interfaces
* copy existing interface
* rewrite vue file
* highlight deleted items
* use Search instead of Get
* support selection on m2m
* finish up m2m
* replace old files
* update files interface
* fix permission checks
* fix styling
* add sketches to explain relations
* rewrite m2a interface
* add usage hint to use-relation-multiple
* update file interface to use new composable
* update file-image interface
* fix image not being shown
* revert names
* fix selection of existing items
* fix loading selected items
* in between commit
* update translations interface
* try using composable recursive
* try linear approach on value modeling
* finish rewriting list-o2m-tree-view interface
* revert api changes
* fix sorting for list-o2m-tree-view
* fix selected items in created array
* Add direct download option to files interface
* Fix linter warnings
* Weird that it's being difficult, but ok
* Cast existingItemCount to number at all times
* fix page gets set below 1
* align pagination to the right
* highlight deselecting row
* show min 1 skeleton loader
* only filter selected when item exists
* fix working on new items
* Fix linter warning
* fix deselecting selected items
* show different icon depending if icon is local
* add changes from #12611
* Add _some vs _none support to o2m
* finish filtering out selected items
* Use get instead of search request
* fix save and stay
Co-authored-by: Rijk van Zanten <rijkvanzanten@me.com>
* fix adding items to m2o
* Fix linter warning
* Handle no-type better
* Clean up axios usage
Co-authored-by: rijkvanzanten <rijkvanzanten@me.com>
Co-authored-by: Azri Kahar <42867097+azrikahar@users.noreply.github.com>
* Adds x-directus-cache response header with HIT value
* Added ENV var for cache header and MISS, UNCACHEABLE
* Rename CACHE_HEADER_KEY -> CACHE_STATUS_HEADER
Tad opinionated, but I feel like it describes the functionality slightly better
* Return miss consistently
Uncacheable doesn't quite describe what's happening. The user actively requests the cache to be skipped, which should result in an expected miss. The value isn't un-cacheable, the cache is skipped on purpose
Co-authored-by: rijkvanzanten <rijkvanzanten@me.com>
* add `Last-Modified` header to `/assets/*` responses
only affects assets with a valid `modified_on` DB field
* update docs about `Last-Modified`
Co-authored-by: rijkvanzanten <rijkvanzanten@me.com>
* Split filter key to get m2a nested collection name
* Add the collection field to the required permissions
* Adding required permissions to relational table
* Tidy up code
* Remove UTC conversion from date, time and datetime fields
* Fix mysql / maria timestamps when not in UTC timezone
* Add sequential tests with node timezone change
* Increase connection attempt check
* Add error catching in tests flow setup
* Check for server connectivity
* Fix promises
* Fix timestamp inconsistencies
* Revert to previously used parseISO
* Ensure database and directus connection
* Add another timezone to test positive and negative GMT
* Set local server hostname to localhost
* Add tests for SQLite
* Use notNullable primary key
* Revert connection testing sleep duration
* Fix nested transactions on SQLite
* Increase MSSQL request timeout
* Add type override flag for SQLite
* Remove commented code
* Add type override flags for Oracle
* Updated test file path
* Increase test servers launch timeout
* Increase test servers launch timeout
* Update format of tests
* Fix typo
* Increase test timeout for CockroachDB
* Add type overrides when creating fields through collections service
* Remove time field type conversion for Oracle
* Update collections list in test
* Remove check for time field in Oracle
* Add missing continue...
* Remove database override
* Add note for SQLite
* Rename flags and extract shared util
* Abstract remaining DB specific checks
* Revert flags renaming except renaming of test files
* Use date helper to add field flag
* Move field date typecasting upstream
* Use timestamp helper for date-created and date-updated
* Fix tests
* Remove unused vars
* Add tests for date-created
* Increase connection attempt count
* Fix test for mariadb
* Increase allowable difference to account for delays
* Add tests for date-updated
* Fix tests again for mariadb
* Add date helpers post merge
Co-authored-by: rijkvanzanten <rijkvanzanten@me.com>
* Add permissions check for relational field only if child has filter
* Allow id field for actions such as update and delete
* Use primary key instead of id
* Add test