class MCF_Ledger_Engine { public function get_daily_ledger() { global $wpdb; $table = $wpdb->prefix . 'mcf_ledger'; $rows = $wpdb->get_results(" SELECT order_id, order_date, currency, net_sale, profit, exchange_rate FROM {$table} ORDER BY order_date ASC "); $result = []; foreach ($rows as $row) { if (empty($row->order_date)) { continue; } $date = date('Y-m-d', strtotime($row->order_date)); if (!isset($result[$date])) { $result[$date] = [ 'consolidated' => ['sales'=>0.0,'profit'=>0.0], 'TRY' => ['sales'=>0.0,'profit'=>0.0], 'EUR' => ['sales'=>0.0,'profit'=>0.0], 'orders' => [] ]; } $currency = strtoupper(trim($row->currency)); $net_sale = (float) $row->net_sale; $profit = (float) $row->profit; $exchange_rate = (float) $row->exchange_rate; if ($exchange_rate <= 0) { $exchange_rate = 1; } // Currency raw aggregation if (isset($result[$date][$currency])) { $result[$date][$currency]['sales'] += $net_sale; $result[$date][$currency]['profit'] += $profit; } // TL Consolidation if ($currency === 'EUR') { $sale_tl = $net_sale * $exchange_rate; $profit_tl = $profit * $exchange_rate; } else { $sale_tl = $net_sale; $profit_tl = $profit; } $result[$date]['consolidated']['sales'] += $sale_tl; $result[$date]['consolidated']['profit'] += $profit_tl; $result[$date]['orders'][] = [ 'id' => (int) $row->order_id, 'currency' => $currency, 'profit_tl' => round($profit_tl,2) ]; } return $result; } } Merlan Wooden Serving Tray -

Merlan Wooden Serving Tray

61

Merlannes Wooden Serving Tray is designed for serving beverages such as coffee and tea. The tray provides a stable and practical surface suitable for everyday indoor use.

1 in stock

SKU: MERLAN_EN Categories: , , ,

Description

Merlannes Wooden Serving Tray is designed for serving beverages such as coffee and tea. The tray provides a stable and practical surface suitable for everyday indoor use.

Made from pine wood, the tray features metal handles that support easy carrying. The upper surface is finished with ceramic tile artwork inspired by Iznik and Kütahya tile traditions, adding refined visual detail. The product is handmade and intended for serving purposes.

Product Features:
• Pine wood tray body
• Ceramic surface with Iznik–Kütahya inspired tile art
• Metal carrying handles
• Suitable for serving coffee, tea, and similar beverages
• Handmade
• Designed for indoor use

Product Dimensions:
Width (W): –
Height (H): –
Depth (D): –

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.