Initial Commit
This commit is contained in:
@@ -0,0 +1,46 @@
|
||||
<?php
|
||||
|
||||
namespace GermanAirlinesVa\Graphql\Classes;
|
||||
|
||||
use Lang;
|
||||
use Cms\Classes\Page;
|
||||
|
||||
|
||||
class Graph extends Page
|
||||
{
|
||||
|
||||
/**
|
||||
* @var string The container name associated with the model.
|
||||
*/
|
||||
protected $dirName = 'graphs';
|
||||
|
||||
/**
|
||||
* @var array The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = [
|
||||
'title',
|
||||
'description',
|
||||
'markup',
|
||||
'settings',
|
||||
'code'
|
||||
];
|
||||
|
||||
/**
|
||||
* @var array The rules to be applied to the data.
|
||||
*/
|
||||
public $rules = [
|
||||
'title' => 'required'
|
||||
];
|
||||
|
||||
public function getCodeClassParent() : string {
|
||||
return GraphCode::class;
|
||||
}
|
||||
|
||||
public function runComponents()
|
||||
{
|
||||
foreach ($this->components as $component) {
|
||||
$component->onRun();
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user