You are here

public function ProductVariationFieldRendererInterface::replaceRenderedFields in Commerce Core 8.2

Replaces the rendered variation fields via AJAX.

Called by the add to cart form when the selected variation changes.

Parameters

\Drupal\Core\Ajax\AjaxResponse $response: The AJAX response.

\Drupal\commerce_product\Entity\ProductVariationInterface $variation: The product variation.

string $view_mode: The display mode.

1 method overrides ProductVariationFieldRendererInterface::replaceRenderedFields()
ProductVariationFieldRenderer::replaceRenderedFields in modules/product/src/ProductVariationFieldRenderer.php
Replaces the rendered variation fields via AJAX.

File

modules/product/src/ProductVariationFieldRendererInterface.php, line 73

Class

ProductVariationFieldRendererInterface
Renders variation fields.

Namespace

Drupal\commerce_product

Code

public function replaceRenderedFields(AjaxResponse $response, ProductVariationInterface $variation, $view_mode = 'default');