silverstripe-framework/tests
Guy Sartorelli 50a0018363
FIX many_many through should allow subclasses (#11230)
```php
class HomePage extends Page
{
    private static $many_many = [
        'HeroImages' => [
            'through' => PageImageLink::class,
            'from' => 'Page',
            'to' => 'Image',
        ]
    ];

}
```

```php
class PageImageLink extends DataObject
{
    private static $has_one = [
        'Page' => SiteTree::class,
        'Image' => Image::class,
    ];
}

This fails because the linking object's relation class doesn't exactly match the owner. Sharing the linking objects across various entries in the ancestry should be a supported use case.

Co-authored-by: Aaron Carlino <unclecheese@leftandmain.com>
2024-05-13 14:15:37 +12:00
..
behat MNT Add new behat function to allow deleting gridfield rows 2023-12-18 12:41:45 +13:00
bootstrap MNT Remove references to PDO 2023-03-16 10:59:34 +13:00
php FIX many_many through should allow subclasses (#11230) 2024-05-13 14:15:37 +12:00
bootstrap.php API Refactor bootstrap, request handling 2017-06-22 22:50:45 +12:00
dump_constants.php ENHANCEMENT Log user constants during CI for debugging improvements 2017-08-23 14:23:33 +12:00
phpcs_runner.php ENH PHP 8.1 compatibility 2022-04-14 13:12:59 +12:00