2024-07-22 23:41:24 +02:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace SilverStripe\FrameworkTest\Elemental\Extension;
|
|
|
|
|
|
|
|
use DNADesign\Elemental\Extensions\ElementalAreasExtension;
|
|
|
|
use DNADesign\Elemental\Models\ElementalArea;
|
|
|
|
|
2024-07-29 01:25:13 +02:00
|
|
|
if (!class_exists(ElementalAreasExtension::class)) {
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
2024-07-22 23:41:24 +02:00
|
|
|
/**
|
|
|
|
* This is used to test multiple elemental areas on a page
|
|
|
|
*/
|
|
|
|
class MultiElementalAreasExtension extends ElementalAreasExtension
|
|
|
|
{
|
|
|
|
private static $has_one = [
|
|
|
|
'ElementalArea1' => ElementalArea::class,
|
|
|
|
'ElementalArea2' => ElementalArea::class
|
|
|
|
];
|
|
|
|
|
|
|
|
private static $owns = [
|
|
|
|
'ElementalArea1',
|
|
|
|
'ElementalArea2'
|
|
|
|
];
|
|
|
|
}
|