silverstripe-framework/tests/php/ORM/ManyManyListTest/Product.php

25 lines
536 B
PHP
Raw Normal View History

2016-10-14 03:30:05 +02:00
<?php
namespace SilverStripe\ORM\Tests\ManyManyListTest;
use SilverStripe\Dev\TestOnly;
use SilverStripe\ORM\DataObject;
class Product extends DataObject implements TestOnly
{
private static $table_name = 'ManyManyListTest_Product';
2016-10-14 03:30:05 +02:00
private static $db = array(
'Title' => 'Varchar'
);
2016-10-14 03:30:05 +02:00
private static $many_many = array(
'RelatedProducts' => Product::class
);
2016-10-14 03:30:05 +02:00
private static $belongs_many_many = array(
'RelatedTo' => Product::class,
'Categories' => Category::class
);
2016-10-14 03:30:05 +02:00
}