mirror of
https://github.com/kevinveenbirkenbach/infinito.git
synced 2025-09-13 13:57:10 +02:00
Refactored code and implemented parts of AccessManagement
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
<?php
|
||||
|
||||
namespace Infinito\Form\Entity;
|
||||
|
||||
use Infinito\Form\AbstractType;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*/
|
||||
abstract class AbstractEntityFormType extends AbstractType implements EntityFormTypeInterface
|
||||
{
|
||||
}
|
@@ -0,0 +1,12 @@
|
||||
<?php
|
||||
|
||||
namespace Infinito\Form\Entity;
|
||||
|
||||
use Infinito\Form\TypeInterface;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*/
|
||||
interface EntityFormTypeInterface extends TypeInterface
|
||||
{
|
||||
}
|
@@ -1,17 +1,17 @@
|
||||
<?php
|
||||
|
||||
namespace Infinito\Form\Source\Primitive\Text;
|
||||
namespace Infinito\Form\Entity\Source\Primitive\Text;
|
||||
|
||||
use Symfony\Component\Form\FormBuilderInterface;
|
||||
use Symfony\Component\OptionsResolver\OptionsResolver;
|
||||
use Infinito\Form\Source\SourceType;
|
||||
use Symfony\Component\Form\Extension\Core\Type\TextType;
|
||||
use Infinito\Entity\Source\Primitive\Text\TextSource;
|
||||
use Infinito\Form\Entity\Source\SourceFormType;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*/
|
||||
class TextSourceCreateType extends SourceType
|
||||
class TextSourceCreateType extends SourceFormType
|
||||
{
|
||||
/**
|
||||
* {@inheritdoc}
|
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Infinito\Form\Source\Primitive\Text;
|
||||
namespace Infinito\Form\Entity\Source\Primitive\Text;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Infinito\Form\Source;
|
||||
namespace Infinito\Form\Entity\Source;
|
||||
|
||||
use Symfony\Component\Form\FormBuilderInterface;
|
||||
use Symfony\Component\OptionsResolver\OptionsResolver;
|
||||
@@ -11,7 +11,7 @@ use Infinito\Attribut\ClassAttributInterface;
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*/
|
||||
final class PureSourceCreateType extends SourceType
|
||||
final class PureSourceCreateType extends SourceFormType
|
||||
{
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
@@ -22,7 +22,7 @@ final class PureSourceCreateType extends SourceType
|
||||
{
|
||||
$builder
|
||||
->add(SlugAttributInterface::SLUG_ATTRIBUT_NAME)
|
||||
->add(ClassAttributInterface::CLASS_ATTRIBUT_NAME, SourceType::class, [
|
||||
->add(ClassAttributInterface::CLASS_ATTRIBUT_NAME, SourceFormType::class, [
|
||||
'mapped' => false,
|
||||
]);
|
||||
}
|
@@ -0,0 +1,12 @@
|
||||
<?php
|
||||
|
||||
namespace Infinito\Form\Entity\Source;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*
|
||||
* @todo Rename!
|
||||
*/
|
||||
interface PureSourceFormTypeInterface
|
||||
{
|
||||
}
|
@@ -0,0 +1,12 @@
|
||||
<?php
|
||||
|
||||
namespace Infinito\Form\Entity\Source;
|
||||
|
||||
use Infinito\Form\Entity\AbstractEntityFormType;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*/
|
||||
class SourceFormType extends AbstractEntityFormType
|
||||
{
|
||||
}
|
@@ -1,14 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace Infinito\Form\Source;
|
||||
|
||||
use Infinito\Form\TypeInterface;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*
|
||||
* @todo Rename!
|
||||
*/
|
||||
interface PureSourceTypeInterface extends TypeInterface
|
||||
{
|
||||
}
|
@@ -1,18 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace Infinito\Form\Source;
|
||||
|
||||
use Infinito\Form\AbstractType;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*/
|
||||
class SourceType extends AbstractType
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
const CLASS_PARAMETER_NAME = 'class';
|
||||
}
|
@@ -8,9 +8,14 @@ use Symfony\Component\OptionsResolver\OptionsResolver;
|
||||
|
||||
class UserSourceType extends AbstractType
|
||||
{
|
||||
/**
|
||||
* @todo implement
|
||||
* {@inheritdoc}
|
||||
*
|
||||
* @see \Symfony\Component\Form\AbstractType::buildForm()
|
||||
*/
|
||||
public function buildForm(FormBuilderInterface $builder, array $options)
|
||||
{
|
||||
$builder->add('namesource', NameSourceType::class);
|
||||
}
|
||||
|
||||
public function configureOptions(OptionsResolver $resolver)
|
||||
|
Reference in New Issue
Block a user