Version: current

     1 <?php
     2 // Добавляем свзяанную вариацию, только если вариации есть и включены (property_exists('Catalog', 'use_variations') && Catalog::$use_variations в _config.php)
     3 class OrderItemVariationDecorator extends DataObjectDecorator {
     4     function extraStatics() {
     5         return array(
     6             'has_one' => array(
     7                 'Variation' => 'ProductVariation',
     8             )
     9         );
    10     }
    11
    12 }

[Raise a SilverStripe Framework issue/bug](https://github.com/silverstripe/silverstripe-framework/issues/new)
- [Raise a SilverStripe CMS issue/bug](https://github.com/silverstripe/silverstripe-cms/issues/new)
- Please use the Silverstripe Forums to ask development related questions. -