Skip to content
This repository has been archived by the owner on Jan 6, 2023. It is now read-only.

Commit

Permalink
v2.0.3
Browse files Browse the repository at this point in the history
  • Loading branch information
rijkvanzanten committed Oct 26, 2018
1 parent 8fc7dc2 commit 58747f2
Show file tree
Hide file tree
Showing 48 changed files with 634 additions and 312 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,13 @@ Directus is an open-source suite of software for managing content in projects of
* [Installing the Directus Suite](https://docs.directus.io/install.html)
* [Extending Directus](https://docs.directus.io/extensions/)
* Directus App
* [App Docs](https://docs.directus.io/app/admin-guide/)
* [App Docs](https://docs.directus.io/app/admin/)
* [User Guide](https://docs.directus.io/app/user-guide.html)
* [Install the App](https://docs.directus.io/app/admin-guide/install.html)
* [Install the App](https://docs.directus.io/app/admin/install.html)
* Directus API
* [API Docs](https://docs.directus.io/api/admin-guide/)
* [API Docs](https://docs.directus.io/api/admin/)
* [API Reference](https://docs.directus.io/api/reference.html)
* [Install the API](https://docs.directus.io/api/admin-guide/install.html)
* [Install the API](https://docs.directus.io/api/admin/install.html)
* Tutorials
* [Tutorials](https://medium.com/directus)
* [Videos](https://www.youtube.com/playlist?list=PLD--x9rY3ZL31stRPkA4FdGC4idIM-8-d)
Expand Down Expand Up @@ -90,8 +90,8 @@ Feature requests are managed as GitHub issues within the appropriate Directus re

We love pull-requests! To work on Directus you'll need to install it locally from source by following the instructions below. Submit all pull-requests to the `development` branch of our `api` and `app` repositories.

* [Setup API Development Environment](https://docs.directus.io/api/contributor-guide/install-dev.html)
* [Setup App Development Environment](https://docs.directus.io/app/contributor-guide/install-dev.html)
* [Setup API Development Environment](https://docs.directus.io/api/contributor/install-dev.html)
* [Setup App Development Environment](https://docs.directus.io/app/contributor/install-dev.html)

### Online Demos

Expand Down
4 changes: 3 additions & 1 deletion config/api_sample.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,9 @@
'username' => 'root',
'password' => 'root',
'engine' => 'InnoDB',
'charset' => 'utf8mb4'
'charset' => 'utf8mb4',
// When using unix socket to connect to the database the host attribute should be removed
// 'socket' => '/var/lib/mysql/mysql.sock',
],

'cache' => [
Expand Down
1 change: 0 additions & 1 deletion config/migrations.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,5 @@

'environments' => [
'default_migration_table' => 'directus_migrations',
'default_database' => 'development'
]
];
14 changes: 14 additions & 0 deletions config/migrations.upgrades.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<?php

return [
'paths' => [
'migrations' => '%%PHINX_CONFIG_DIR%%/../migrations/upgrades/schemas',
'seeds' => '%%PHINX_CONFIG_DIR%%/../migrations/upgrades/seeds'
],

'version_order' => 'creation',

'environments' => [
'default_migration_table' => 'directus_migrations',
]
];
159 changes: 159 additions & 0 deletions migrations/upgrades/schemas/20181022175715_upgrade_070003.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,159 @@
<?php

use Phinx\Migration\AbstractMigration;

class Upgrade070003 extends AbstractMigration
{
public function up()
{
// ----------------------------------------------------------------------------
// Fix directus_users.timezone placeholder text
// ----------------------------------------------------------------------------
$options = json_encode([
'choices' => [
'America/Puerto_Rico' => 'Puerto Rico (Atlantic)',
'America/New_York' => 'New York (Eastern)',
'America/Chicago' => 'Chicago (Central)',
'America/Denver' => 'Denver (Mountain)',
'America/Phoenix' => 'Phoenix (MST)',
'America/Los_Angeles' => 'Los Angeles (Pacific)',
'America/Anchorage' => 'Anchorage (Alaska)',
'Pacific/Honolulu' => 'Honolulu (Hawaii)'
],
'placeholder' => 'Choose a timezone...'
]);

$this->execute(\Directus\phinx_update(
$this->getAdapter(),
'directus_fields',
['options' => $options],
['collection' => 'directus_users', 'field' => 'timezone']
));

// ----------------------------------------------------------------------------
// Update directus_users.roles interface from "many-to-many" to "user-roles"
// Set directus_users.roles hidden_detail and hidden_browse attribute to "false"
// Update directus_users.roles width to 2
// Update directus_users.roes sort to 8
// ----------------------------------------------------------------------------
$this->execute(\Directus\phinx_update(
$this->getAdapter(),
'directus_fields',
[
'interface' => 'user-roles',
'hidden_detail' => 0,
'hidden_browse' => 0,
'width' => 2,
'sort' => 8,
],
[
'collection' => 'directus_users',
'field' => 'roles'
]
));

// ----------------------------------------------------------------------------
// Update directus_users.locale_options hidden_detail attribute to "true"
// ----------------------------------------------------------------------------
$this->execute(\Directus\phinx_update(
$this->getAdapter(),
'directus_fields',
[
'hidden_detail' => 1,
],
[
'collection' => 'directus_users',
'field' => 'locale_options'
]
));

// ----------------------------------------------------------------------------
// Update directus_settings "logo" interface from "single_file" to "file"
// ----------------------------------------------------------------------------
$this->execute(\Directus\phinx_update(
$this->getAdapter(),
'directus_fields',
[
'interface' => 'file',
],
[
'collection' => 'directus_settings',
'field' => 'logo'
]
));

// ----------------------------------------------------------------------------
// Update directus_user_roles user_id field to user in directus_fields
// ----------------------------------------------------------------------------
$this->execute(\Directus\phinx_update(
$this->getAdapter(),
'directus_fields',
[
'field' => 'user',
],
[
'collection' => 'directus_user_roles',
'field' => 'user_id'
]
));

// ----------------------------------------------------------------------------
// Update directus_user_roles role_id field to role in directus_fields
// ----------------------------------------------------------------------------
$this->execute(\Directus\phinx_update(
$this->getAdapter(),
'directus_fields',
[
'field' => 'role',
],
[
'collection' => 'directus_user_roles',
'field' => 'role_id'
]
));

// ----------------------------------------------------------------------------
// Update directus_users.password width attribute to 2
// ----------------------------------------------------------------------------
$this->execute(\Directus\phinx_update(
$this->getAdapter(),
'directus_fields',
[
'width' => 2,
],
[
'collection' => 'directus_users',
'field' => 'password'
]
));

// ----------------------------------------------------------------------------
// Update directus_users fields sort value
// ----------------------------------------------------------------------------
$fields = [
'company' => 9,
'title' => 10,
'timezone' => 11,
'locale' => 12,
'locale_options' => 13,
'token' => 14,
'last_login' => 15,
'last_access_on' => 16,
'avatar' => 18,
];

foreach ($fields as $field => $sort) {
$this->execute(\Directus\phinx_update(
$this->getAdapter(),
'directus_fields',
[
'sort' => $sort,
],
[
'collection' => 'directus_users',
'field' => $field
]
));
}
}
}
Empty file.
6 changes: 3 additions & 3 deletions public/extensions/core/interfaces/code/input.js

Large diffs are not rendered by default.

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions public/extensions/core/interfaces/file-preview/input.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion public/extensions/core/interfaces/file-preview/input.js

Large diffs are not rendered by default.

8 changes: 5 additions & 3 deletions public/extensions/core/interfaces/file/display.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion public/extensions/core/interfaces/file/meta.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"$t:file","version":"1.0.1","types":["file"],"icon":"insert_drive_file","recommended":{"length":10},"options":{"viewType":{"name":"$t:view_type","comment":"$t:view_type_comment","default":"cards","interface":"text-input"},"viewOptions":{"name":"$t:view_options","comment":"$t:view_options_comment","interface":"code","options":{"language":"application/json"},"default":{"title":"title","subtitle":"type","content":"description","src":"data"}},"viewQuery":{"name":"$t:view_query","comment":"$t:view_query_comment","interface":"code","options":{"language":"application/json"},"default":{}},"filters":{"name":"$t:filters","comment":"$t:filters_comment","interface":"code","options":{"language":"application/json"},"default":[]}},"translation":{"en-US":{"file":"File","view_type":"View Type","view_type_comment":"Select in what way you want to view the files","view_options":"View Options","view_options_comment":"Set the view options to use for the files","view_query":"View Query","view_query_comment":"Set the view query to use for the files","filters":"Filters","filters_comment":"What filters to use"}}}
{"name":"$t:file","version":"1.1.0","types":["file"],"icon":"insert_drive_file","recommended":{"length":10},"options":{"viewType":{"name":"$t:view_type","comment":"$t:view_type_comment","default":"cards","interface":"text-input"},"viewOptions":{"name":"$t:view_options","comment":"$t:view_options_comment","interface":"code","options":{"language":"application/json"},"default":{"title":"title","subtitle":"type","content":"description","src":"data"}},"viewQuery":{"name":"$t:view_query","comment":"$t:view_query_comment","interface":"code","options":{"language":"application/json"},"default":{}},"filters":{"name":"$t:filters","comment":"$t:filters_comment","interface":"code","options":{"language":"application/json"},"default":[]}},"translation":{"en-US":{"file":"File","view_type":"View Type","view_type_comment":"Select in what way you want to view the files","view_options":"View Options","view_options_comment":"Set the view options to use for the files","view_query":"View Query","view_query_comment":"Set the view query to use for the files","filters":"Filters","filters_comment":"What filters to use"}}}
Loading

0 comments on commit 58747f2

Please sign in to comment.