mirror of
https://github.com/typemill/typemill.git
synced 2025-08-06 14:16:46 +02:00
version 1.2.9
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
namespace Typemill;
|
||||
|
||||
use \Symfony\Component\EventDispatcher\EventSubscriberInterface;
|
||||
use Typemill\Models\Fields;
|
||||
|
||||
abstract class Plugin implements EventSubscriberInterface
|
||||
{
|
||||
@@ -84,4 +85,20 @@ abstract class Plugin implements EventSubscriberInterface
|
||||
{
|
||||
$this->container->assets->addInlineCSS($CSS);
|
||||
}
|
||||
|
||||
protected function generateForm($pluginName)
|
||||
{
|
||||
$fieldsModel = new Fields();
|
||||
|
||||
$pluginDefinitions = \Typemill\Settings::getObjectSettings('plugins', $pluginName);
|
||||
|
||||
if(isset($pluginDefinitions['frontend']['fields']))
|
||||
{
|
||||
# get all the fields and prefill them with the dafault-data, the user-data or old input data
|
||||
$fields = $fieldsModel->getFields($userSettings = false, 'plugins', $pluginName, $pluginDefinitions, 'frontend');
|
||||
|
||||
# use the field-objects to generate the html-fields
|
||||
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user