I have custom realization - where i can add to product items, i can get for product items like this:
<?php if(!empty($cart_item['more_product'])) :
$first_array = array_slice($cart_item['more_product'],0,4);
$second_array = array_slice($cart_item['more_product'],4);
?>
<div class="products__includes">
<div class="products__includes__btn active">
Set includes
</div>
<div class="products__includes__wrap">
<div class="products__includes__inner">
<table>
<tbody>
<?php foreach($first_array as $piece): ?>
<tr>
<th><?php echo $piece['title'];?></th>
<th><?php echo $piece['count'];?></th>
</tr>
<?php endforeach;?>
</tbody>
</table>
<?php if(!empty($second_array)):?>
<table>
<tbody>
<?php foreach($second_array as $piece): ?>
<tr>
<th><?php echo $piece['title'];?></th>
<th><?php echo $piece['count'];?></th>
</tr>
<?php endforeach;?>
</tbody>
</table>
<?php endif; ?>
</div>
</div>
</div>
<?php endif; ?>
i need get this all in order, how i can do?