diff --git a/.idea/codeception.xml b/.idea/codeception.xml
index 42a91a8..b101d83 100644
--- a/.idea/codeception.xml
+++ b/.idea/codeception.xml
@@ -33,6 +33,9 @@
+
+
+
diff --git a/.idea/futtern.iml b/.idea/futtern.iml
index 8702762..16f64df 100644
--- a/.idea/futtern.iml
+++ b/.idea/futtern.iml
@@ -4,6 +4,8 @@
+
+
diff --git a/.idea/phpspec.xml b/.idea/phpspec.xml
index 8b8e568..551d4e1 100644
--- a/.idea/phpspec.xml
+++ b/.idea/phpspec.xml
@@ -32,6 +32,9 @@
+
+
+
\ No newline at end of file
diff --git a/src/Controller/FoodOrderController.php b/src/Controller/FoodOrderController.php
index ad1b2f8..0fc4296 100644
--- a/src/Controller/FoodOrderController.php
+++ b/src/Controller/FoodOrderController.php
@@ -88,7 +88,6 @@ class FoodOrderController extends AbstractController
);
}
-
return $this->render('food_order/orderitem.html.twig', [
'form' => $form,
'extras' => $extraRepository->getUniqueNames(),
diff --git a/src/Form/MenuItemExtraType.php b/src/Form/MenuItemExtraType.php
new file mode 100644
index 0000000..ce6bd9e
--- /dev/null
+++ b/src/Form/MenuItemExtraType.php
@@ -0,0 +1,33 @@
+add('name');
+ $builder->add('customextra', TextType::class, [
+ 'label' => 'Add a new extra option',
+ 'mapped' => false,
+ 'required' => false,
+ 'attr' => ['list' => 'item-extra-list'],
+ ]);
+ }
+
+ public function configureOptions(OptionsResolver $resolver): void
+ {
+ $resolver->setDefaults([
+ 'data_class' => ItemExtra::class,
+ ]);
+ }
+}
diff --git a/src/Form/OrderItemType.php b/src/Form/OrderItemType.php
index cb7ff04..13afa97 100644
--- a/src/Form/OrderItemType.php
+++ b/src/Form/OrderItemType.php
@@ -32,11 +32,6 @@ class OrderItemType extends AbstractType
'expanded' => true,
],
);
- $builder->add('customextra', TextType::class, [
- 'label' => 'Not yet know extras, seperated by comma',
- 'mapped' => false,
- 'attr' => ['datalist' => 'item-extra-list'],
- ]);
}
#[Override]
diff --git a/templates/base.html.twig b/templates/base.html.twig
index b989963..3d9e9c6 100644
--- a/templates/base.html.twig
+++ b/templates/base.html.twig
@@ -5,11 +5,6 @@
{% block title %}Welcome!{% endblock %}
- {% block stylesheets %}
- {% endblock %}
-
- {% block javascripts %}
- {% endblock %}