Skip to content
This repository has been archived by the owner on Sep 29, 2024. It is now read-only.

Commit

Permalink
Fixed issue with field_deleted_data_xxxxx and updated weights
Browse files Browse the repository at this point in the history
  • Loading branch information
yeniatencio committed Aug 19, 2024
1 parent a282e77 commit 6788fc9
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -83,45 +83,48 @@ settings:
links:
weight: -86
enabled: false
card_carousel:
enabled: true
weight: -84
card_keydates:
enabled: true
weight: -83
call_to_action:
enabled: true
weight: -82
card_event:
weight: -81
enabled: true
card_carousel:
weight: -80
enabled: true
embedded_webform:
enabled: true
weight: -79
form_embed_openforms:
enabled: true
weight: -81
weight: -78
media_gallery:
enabled: true
weight: -80
weight: -77
complex_image:
enabled: true
weight: -79
weight: -76
timelines:
enabled: true
weight: -78
weight: -75
data_table:
enabled: true
weight: -75
weight: -74
compact_card:
weight: -66
enabled: false
compact_card_collection:
weight: -65
enabled: true
accordion_content:
weight: -74
weight: -73
enabled: false
keydates:
weight: -73
weight: -72
enabled: false
embedded_webform:
enabled: true
weight: -81
contact_us:
weight: -70
enabled: false
Expand Down
9 changes: 9 additions & 0 deletions tide_landing_page.install
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ use Drupal\field\Entity\FieldConfig;
use Drupal\field\Entity\FieldStorageConfig;
use Drupal\paragraphs\Entity\Paragraph;
use Drupal\tide_landing_page\TideLandingPageOperation;
use Drush\Drush;

/**
* Implements hook_install().
Expand Down Expand Up @@ -97,6 +98,12 @@ function tide_landing_page_update_10102() {
* Remove style option field from call to action component.
*/
function tide_landing_page_update_10103() {
// To avoid error `table for the field couldn't be renamed to the field_deleted_data_xxxxx{long-hash-string}
// because the table already exists`
// @link https://www.drupal.org/project/drupal/issues/2836539
$alias_manager = Drush::service('site.alias.manager');
Drush::drush($alias_manager->getSelf(), 'cron')->run();

module_load_include('inc', 'tide_core', 'includes/helpers');
$config_location = [\Drupal::service('extension.list.module')->getPath('tide_landing_page') . '/config/install'];
// Delete field configuration manually.
Expand Down Expand Up @@ -145,6 +152,8 @@ function tide_landing_page_update_10104() {
'navigation_card',
'card_keydates',
'call_to_action',
'card_event',
'card_carousel',
'embedded_webform',
'form_embed_openforms',
'media_gallery',
Expand Down

0 comments on commit 6788fc9

Please sign in to comment.