How can I save multiple Orders with one Form?

Hey everyone,

I want that to save the Customer (customer_id) multiple times but with different date and menu_item_id.
Example:

Customer: Max | Date: 11.06.2019 | menu_item_id: 1
Same Customer but | Date: 10.06.2019 | menu_item_id: 3
Still Same Customer | Date 09.06.2019 | menu_item_id: 5

This is what i want to do but i cant make it work.

My Orders add.ctp

<div class="customers index large-9 medium-8 columns content">
<?= $this->Form->create($order) ?>
<h3><?= __('Bestellung Tabelle') ?></h3>
<?php	
		echo $this->Form->control('customer_id', array('label' => __('Kunde', true)),['options' => $customers, 'empty' => false]);
		echo $this->Form->control('date', array('label' => __('Datum',true), 'empty' => true));   
        echo $this->Form->control('menu_item_id', array('label' => __('Menü',true), 'empty' => true)); 	
    ?>

        <?= $this->Form->button(__('Bestätigen')) ?>
<?= $this->Form->end() ?>

I tryed to just add another two of those:

 echo $this->Form->control('date', array('label' => __('Datum',true), 'empty' => true));   
 echo $this->Form->control('menu_item_id', array('label' => __('Menü',true), 'empty' => true)); 

so I have:

echo $this->Form->control('customer_id', array('label' => __('Kunde', true)),['options' => $customers, 'empty' => false]);
echo $this->Form->control('date', array('label' => __('Datum',true), 'empty' => true));   
echo $this->Form->control('menu_item_id', array('label' => __('Menü',true), 'empty' => true)); 	
echo $this->Form->control('date', array('label' => __('Datum',true), 'empty' => true));   
echo $this->Form->control('menu_item_id', array('label' => __('Menü',true), 'empty' => true)); 	

but they just overwrite the Inputs I entered before them.

So how can I save the same Customer with multiple Dates and Menus? Because I think i need to change something in my Controller but I am not sure what.

OrdersController.php (only the add function)

public function add()
{   
    $order = $this->Orders->newEntity();
    if ($this->request->is('post')) {
        $order = $this->Orders->patchEntity($order, $this->request->getData());
        if ($this->Orders->save($order)) {
            $this->Flash->success(__('The order has been saved.'));

            return $this->redirect(['action' => 'index']);
        }
        $this->Flash->error(__('The order could not be saved. Please, try again.'));
    }
    $customers = $this->Orders->Customers->find('list', ['limit' => 200]);
    $menuItems = $this->Orders->MenuItems->find('list', ['limit' => 200]);
    $this->set(compact('order', 'customers', 'menuItems'));
}

I read something about changing the newEntity() to newEntities() but I didnt understood how to do it with my code?

Im pretty new to coding in general only got some knowledge from cms systems, so I would be pretty happy if someone could help me to understood it better.

Might not be ideal but maybe use a menuItems[] field in the form and send that?
Then use something like a for loop to parse it.

So i found a Solution to my problem. But now i have the Problem that I need to choose the Customer Multiple Times.

This is now my add.ctp

<div class="orders form large-9 medium-8 columns content">
<?= $this->Form->create($order) ?>

    <legend><?= __('Neue Bestellung') ?></legend>
    <?php
    	echo $this->Form->control('0.customer_id', array('label' => __('Kunde',true)));
        echo $this->Form->control('0.date', array('label' => __('Datum',true)));
        echo $this->Form->control('0.menu_item_id', array('label' => __('Menü',true)));
        echo $this->Form->control('1.customer_id', array('label' => __('Kunde',true))); 
        echo $this->Form->control('1.date', array('label' => __('Datum',true)));
        echo $this->Form->control('1.menu_item_id', array('label' => __('Menü',true)));
    ?>

<?= $this->Form->button(__('Bestätigen')) ?>
<?= $this->Form->end() ?>

With this i can save multliple Orders. What do I need to change so that I only need to input my customer_id one time?

My OrdersController.php

public function add()
{
    
    $order = $this->Orders->newEntity();
    if ($this->request->is('post')) {
        $orders = $this->Orders->newEntities($this->request->getData());
        
        foreach ($orders as $order)
        {                
            $this->Orders->save($order);
        }
        $this->Flash->success(__('The order has been saved.'));
        
        return $this->redirect(['action' => 'index']);
        
        $this->Flash->error(__('The order could not be saved. Please, try again.'));
    }
    $customers = $this->Orders->Customers->find('list', ['limit' => 200]);
    $menuItems = $this->Orders->MenuItems->find('list', ['limit' => 200]);
    $this->set(compact('order', 'customers', 'menuItems'));
}

I really struggle to find a solution, that I only need to choose the customer one time, inside the form.