FastMovieAI AI短剧创作平台 二开基线
- 源码: xhadmincn/FastMovieAI (Apache 2.0) - 二开: Docker部署, Swoole改Select, route.php修复, 补update/VERSION - vendor/示例资源已gitignore
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
<?php
|
||||
|
||||
namespace app\expose\build\builder\databoardBuilder\component;
|
||||
|
||||
use app\expose\build\builder\databoardBuilder\interface\DataboardBuilderInterface;
|
||||
use app\expose\build\builder\databoardBuilder\Basic;
|
||||
use app\expose\utils\Str;
|
||||
class Placeholder extends Basic implements DataboardBuilderInterface
|
||||
{
|
||||
protected $data = [];
|
||||
public function __construct()
|
||||
{
|
||||
$this->data['name'] = 'div';
|
||||
$this->data['props'] = [];
|
||||
}
|
||||
public function __call($name, $arguments)
|
||||
{
|
||||
$name = lcfirst(str_replace('set', '', $name));
|
||||
$name = Str::snake($name, '_');
|
||||
$this->data['props'][$name] = $arguments[0];
|
||||
return $this;
|
||||
}
|
||||
public function setData(mixed $data): Placeholder
|
||||
{
|
||||
$this->data['props']['data'] = $data;
|
||||
return $this;
|
||||
}
|
||||
public function setApi(string $api): Placeholder
|
||||
{
|
||||
$this->data['props']['api'] = $api;
|
||||
return $this;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user