Skip to content

Update to Core 8.8.x-dev and switch to using Core 8.8.x-dev jsonapi module. #772

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 8 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion admin_ui_support/admin_ui_support.info.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@ dependencies:
- drupal:rest
- jsonapi:jsonapi
- jsonapi_tables:jsonapi_tables
- jsonapi_support:jsonapi_support
# - jsonapi_support:jsonapi_support
- openapi:openapi
Original file line number Diff line number Diff line change
Expand Up @@ -26,22 +26,22 @@ class ResourceTypeRepository extends JsonApiResourceTypeRepository {
* {@inheritdoc}
*/
public function all() {
if (!$this->all) {
$this->all = parent::all();
$all = [];
//if (!$this->all) {
$resource_types = parent::all();
$entity_types = $this->entityTypeManager->getDefinitions();
foreach ($entity_types as $entity_type_id => $entity_type) {
$resource_type = new CrossBundlesResourceType(
$entity_type_id,
$entity_type_id,
$entity_type->getClass(),
static::shouldBeInternalResourceType($entity_type)
$entity_type->isInternal()
);
$relatable_resource_types = $this->calculateRelatableResourceTypes($resource_type);
$relatable_resource_types = $this->calculateRelatableResourceTypes($resource_type,$resource_types);
$resource_type->setRelatableResourceTypes($relatable_resource_types);
$this->all[] = $resource_type;
$all[] = $resource_type;
}
}
return $this->all;
//}
return $all;
}

}
2 changes: 1 addition & 1 deletion demo/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ if [ ! -f docroot/sites/default/settings.php ]; then
composer config repositories.repo-name path "/var/www/admin_ui_support"
COMPOSER_MEMORY_LIMIT=-1 composer require justafish/drupal-admin-ui-support:dev-master
drush site:install demo_umami -y --db-url=mysql://drupal:drupal@mysql:3306/drupal --sites-subdir=default
drush en -y jsonapi admin_ui_support admin_ui_widget_example
drush en -y jsonapi admin_ui_support admin_ui_widget_example admin_toolbar
drush config:set -y system.logging error_level verbose
rm -rf docroot/vfancy
ln -s /var/www/admin-ui/build/ docroot/vfancy
Expand Down
69 changes: 32 additions & 37 deletions demo/templates/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,28 +3,32 @@
"description": "Project template for testing Drupal's React Admin user interface",
"type": "project",
"license": "GPL-2.0-or-later",
"repositories": [
{
"repositories": {
"0": {
"type": "composer",
"url": "https://packages.drupal.org/8"
},
"repo-name": {
"type": "path",
"url": "/var/www/admin_ui_support"
}
],
},
"require": {
"composer/installers": "^1.2",
"composer/installers": "^1.6",
"cweagans/composer-patches": "^1.6",
"drupal-composer/drupal-scaffold": "^2.2",
"drupal/core": "~8.7",
"drupal-composer/drupal-scaffold": "^2.6",
"drupal/core": "8.8.x-dev",
"oomphinc/composer-installers-extender": "^1.1",
"php": ">=7.0.8",
"webflo/drupal-finder": "^1.0.0",
"webmozart/path-util": "^2.3",
"justafish/drupal-admin-ui": "dev-master",
"justafish/drupal-admin-ui-support": "dev-master",
"zaporylie/composer-drupal-optimizations": "^1.0"
"zaporylie/composer-drupal-optimizations": "^1.0",
"drupal/admin_toolbar": "^1.26",
"drupal/openapi": "dev-1.x"
},
"require-dev": {
"webflo/drupal-core-require-dev": "~8.7",
"drush/drush": "^9.2"
"webflo/drupal-core-require-dev": "8.8.x-dev",
"drush/drush": "^9.7"
},
"minimum-stability": "dev",
"prefer-stable": true,
Expand All @@ -37,22 +41,9 @@
"process-timeout": 0
},
"scripts": {
"setup": [
"cd docroot && php core/scripts/drupal install demo_umami --no-interaction",
"cd docroot && ../vendor/bin/drush en -y jsonapi admin_ui_support"
],
"start": [
"cd docroot && php core/scripts/drupal server"
],
"devify": [
"git clone https://github.com/jsdrupal/drupal-admin-ui",
"cp drupal-admin-ui/packages/admin-ui/.env drupal-admin-ui/packages/admin-ui/.env.local",
"cd drupal-admin-ui && yarn install",
"rm -rf docroot/vfancy",
"ln -s ../drupal-admin-ui/build docroot/vfancy",
"rm -rf docroot/modules/contrib/drupal-admin-ui-support",
"ln -s ../../../drupal-admin-ui/admin_ui_support docroot/modules/contrib/drupal-admin-ui-support"
],
"test": [
"phpunit -c docroot/core --log-junit reports/phpunit.xml docroot/modules/contrib/drupal-admin-ui-support"
],
Expand All @@ -72,24 +63,28 @@
]
},
"extra": {
"installer-types": ["library"],
"installer-types": [
"library"
],
"installer-paths": {
"docroot/vfancy": ["justafish/drupal-admin-ui"],
"docroot/core": ["type:drupal-core"],
"docroot/core": [
"type:drupal-core"
],
"docroot/libraries/{$name}": [
"type:drupal-library",
"type:bower-asset"
],
"docroot/modules/contrib/{$name}": ["type:drupal-module"],
"docroot/profiles/contrib/{$name}": ["type:drupal-profile"],
"docroot/themes/contrib/{$name}": ["type:drupal-theme"]
"docroot/modules/contrib/{$name}": [
"type:drupal-module"
],
"docroot/profiles/contrib/{$name}": [
"type:drupal-profile"
],
"docroot/themes/contrib/{$name}": [
"type:drupal-theme"
]
},
"enable-patching": true,
"patches": {
"drupal/core": {
"Race condition causing 500 on cache table creation": "https://www.drupal.org/files/issues/2019-04-10/3043907-5.patch",
"Remove Umami dependency to Workflows because the admin UI doesn't currently support it": "patches/remove-umami-workflows-dependency.patch"
}
}
"enable-patching": false,
"patches": []
}
}
Loading