WIP: Implement document handling
This commit is contained in:
@@ -6,11 +6,13 @@ use App\Entity\Assignment;
|
||||
use App\Entity\Destination;
|
||||
use App\Entity\Fee;
|
||||
use App\Entity\JobProfile;
|
||||
use App\Entity\Upload;
|
||||
use App\Entity\User;
|
||||
use Doctrine\ORM\EntityRepository;
|
||||
use Symfony\Bridge\Doctrine\Form\Type\EntityType;
|
||||
use Symfony\Component\Form\AbstractType;
|
||||
use Symfony\Component\Form\Extension\Core\Type\CheckboxType;
|
||||
use Symfony\Component\Form\Extension\Core\Type\CollectionType;
|
||||
use Symfony\Component\Form\Extension\Core\Type\IntegerType;
|
||||
use Symfony\Component\Form\Extension\Core\Type\TextareaType;
|
||||
use Symfony\Component\Form\FormBuilderInterface;
|
||||
@@ -87,6 +89,19 @@ class AssignmentType extends AbstractType
|
||||
;
|
||||
},
|
||||
])
|
||||
->add('documents', CollectionType::class, [
|
||||
'label' => 'Dokumente',
|
||||
'entry_type' => AutocompleteEntityType::class,
|
||||
'entry_options' => [
|
||||
'class' => Upload::class,
|
||||
'endpoint_route' => 'app_admin_autocomplete_document',
|
||||
'label_property' => 'originalFilename',
|
||||
'placeholder' => 'Dokument...',
|
||||
],
|
||||
'allow_add' => true,
|
||||
'allow_delete' => true,
|
||||
'by_reference' => false,
|
||||
])
|
||||
->add('remarks', TextareaType::class, [
|
||||
'label' => 'Anmerkungen',
|
||||
'required' => false,
|
||||
|
||||
Reference in New Issue
Block a user