diff --git a/lib/presentation/components/print/print_ui.dart b/lib/presentation/components/print/print_ui.dart index 249bfcc..af6b340 100644 --- a/lib/presentation/components/print/print_ui.dart +++ b/lib/presentation/components/print/print_ui.dart @@ -159,6 +159,7 @@ class PrintUi { bytes += builder.orderInfoSimple( orderNumber: order.orderNumber, cashierName: cashierName, + customerName: order.metadata['customer_name'] ?? '-', ); bytes += builder.separator(); @@ -202,7 +203,7 @@ class PrintUi { bytes += generator.reset(); // Header - bytes += builder.textCenter('Bar', bold: true); + bytes += builder.row2Columns('Bar', order.orderType.toUpperCase(), bold: true); bytes += builder.separator(); bytes += builder.textCenter( 'Table : ${order.tableNumber.isNotEmpty ? order.tableNumber : '-'}', @@ -213,7 +214,7 @@ class PrintUi { // Order info bytes += builder.orderInfoSimple( orderNumber: order.orderNumber, - orderType: order.orderType, + customerName: order.metadata['customer_name'] ?? '-', cashierName: cashierName, ); diff --git a/lib/presentation/components/print/receipt_component_builder.dart b/lib/presentation/components/print/receipt_component_builder.dart index 85cc893..4e402d2 100644 --- a/lib/presentation/components/print/receipt_component_builder.dart +++ b/lib/presentation/components/print/receipt_component_builder.dart @@ -111,6 +111,8 @@ class ReceiptComponentBuilder { align: PosAlign.left, bold: bold, fontType: _font, + height: _bodyHeight, + width: _bodyWidth, ), ), PosColumn( @@ -120,6 +122,8 @@ class ReceiptComponentBuilder { align: PosAlign.right, bold: bold, fontType: _font, + height: _bodyHeight, + width: _bodyWidth, ), ), ]);