Go to app/Http/Controllers/DeliveryController.php
On line 739, 826 and 833 you have
$restaurant_earning->amount += $order->total - ($order->delivery_charge + $order->tip_amount);
Replaced by
$restaurant_earning->amount += $order->total - ($order->delivery_charge + $order->tip_amount) - $order->restaurant_charge;
On line 739 you have
$restaurant_earning->amount = $order->total - ($order->delivery_charge + $order->tip_amount);
Replaced by
$restaurant_earning->amount = $order->total - ($order->delivery_charge + $order->tip_amount) - $order->restaurant_charge;
Save
Go to app/Http/Controllers/RestaurantOwnerController.php
On line 91 and 1267 you have
$totalEarning += $completedOrder->total - ($completedOrder->delivery_charge + $completedOrder->tip_amount);
Replaced by
$totalEarning += $completedOrder->total - ($completedOrder->delivery_charge + $completedOrder->tip_amount) - $completedOrder->restaurant_charge;
Save
Try this it's not tested but it's should work <3