Conversation
| $storage_definition = BaseFieldDefinition::create('boolean') | ||
| ->setLabel(t('Status')) | ||
| ->setDescription(t('Whether the SKU is available or not.')) | ||
| ->setDefaultValue(TRUE); | ||
|
|
||
| \Drupal::entityDefinitionUpdateManager() | ||
| ->installFieldStorageDefinition('status', 'acm_sku', 'acm_sku', $storage_definition); |
There was a problem hiding this comment.
Do these functions throw exceptions? If yes, please catch and log as before. If no, do they write to the log?
There was a problem hiding this comment.
I don't think so, this is using the same pattern that Node uses in core, see the following:
https://git.drupalcode.org/project/drupal/-/blob/8.8.x/core/modules/node/node.install#L169
| $config->setData($existing_fields)->save(); | ||
|
|
||
| if ($apply_updates) { | ||
| $this->entityDefinitionUpdateManager->applyUpdates(); |
There was a problem hiding this comment.
I don't understand why this code is removed.
There was a problem hiding this comment.
Automatic entity updates no longer exist in Drupal 8.7+, it is handled in the entity manager for save, therefore the existing code changing the entity should suffice.
| */ | ||
| public function createProductOptionWrapper($langcode, $option_id, $option_value, $attribute_id, $attribute_code, $weight) { | ||
| return $this->createProductOption(); | ||
| return $this->createProductOption($langcode, $option_id, $option_value, $attribute_id, $attribute_code, $weight); |
There was a problem hiding this comment.
This is a bug fix, yes?
There was a problem hiding this comment.
Yes, that was taken from the merge done from the earlier PR. If you want this moved out we can do it, but its pretty minor so I just kept it in.
|
This should be reopned. |
…s don't work with it.
# Conflicts: # modules/acm_sku/src/Entity/SKU.php
# Conflicts: # modules/acm_cart/composer.json # modules/acm_cart/src/CartStorage.php
# Conflicts: # modules/acm/composer.json # modules/acm_promotion/composer.json
|
The latest fix puts us in a good position to release for Drupal 9. There are some outstanding deprecations around REQUEST_TIME -- which I'll see if we need to resolve, but as of May 15 2020 -- Drupal core itself has pushed some of these deprecations to 9.1. One of the problems is the service will not work with our unit tests, which will require some more refactoring. There is also an issue with facets, but since it doesn't have a release, we cannot test our plugin. I don't think thats a major issue at the moment. |
No description provided.