I use the last version of commerce and drupal 8.7.
On all views with product fields, I can't edit product fields (except the title) because of an ajax error :
admin/structure/views/ajax/handler/produit_une/block_1/field/field_prod_img↵StatusText: parsererror↵ResponseText : ↵Notice: Undefined index: entity_type in /public_html/modules/contrib/commerce/modules/price/commerce_price.module on line 51
I tried to remove all module exepted commerce module. I removed all the orders, products, prices, there's nothing in all the commerce tables but the error is still there, no error message on the website....
Comments
Comment #2
bojanz commentedLet's give this issue a descriptive title.
The problem is coming from commerce_price_form_views_ui_config_item_form_alter().
$handler->options['entity_type'] is unset, so we should at least wrap it in an empty check. Looking into this.
EDIT: I have found that for a few cases (such as the product title field), $handler->options['entity_type'] is unset, but $handler->definition['entity_type'] is set. No clue why. So, let's switch to the other version, but still wrap it in an empty check.
Comment #3
bojanz commentedAlso switching from "entity field" to "field_name" so that I don't have to guess if there's an underscore or not.
Can you try this patch?
Comment #5
bojanz commentedStarted running into this bug myself, on a state_machine state field, so proceeding with a commit.