for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace SilverStripe\RestfulServer\Tests\Stubs;
use SilverStripe\Dev\TestOnly;
use SilverStripe\ORM\DataObject;
class RestfulServerTestAuthorRating extends DataObject implements TestOnly
{
private static $api_access = array(
$api_access
'view' => array(
'Rating',
'WriteProtectedField',
'Author'
),
'edit' => array(
'Rating'
)
);
private static $table_name = 'RestfulServerTestAuthorRating';
$table_name
private static $db = array(
$db
'Rating' => 'Int',
'SecretField' => 'Text',
'WriteProtectedField' => 'Text',
private static $has_one = array(
$has_one
'Author' => RestfulServerTestAuthor::class,
'SecretRelation' => RestfulServerTestAuthor::class,
public function canView($member = null)
return true;
}
public function canEdit($member = null)
public function canCreate($member = null, $context = array())