From bc595e1c7e2594925826aca700d832701cd4df33 Mon Sep 17 00:00:00 2001 From: Siegfried Siegert Date: Tue, 8 Oct 2024 16:49:59 +0200 Subject: [PATCH] Printing: set "productText" to dynTicketData.dynDat5 --- src/ATBAPP/ATBDeviceControllerPlugin.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/ATBAPP/ATBDeviceControllerPlugin.cpp b/src/ATBAPP/ATBDeviceControllerPlugin.cpp index fefd685..178d7f3 100644 --- a/src/ATBAPP/ATBDeviceControllerPlugin.cpp +++ b/src/ATBAPP/ATBDeviceControllerPlugin.cpp @@ -792,6 +792,7 @@ void ATBDeviceControllerPlugin::requestPrintTicket(const QHashfromUnicode(currentDateString); memcpy((char*)dynTicketData->currentDate, ba_currentDate.data(), std::min(ba_currentDate.size(),8)); + // Product-Text + QByteArray ba_productText = codec->fromUnicode(printingData["productText"].toString()); + memcpy((char*)dynTicketData->dynDat5, ba_productText.data(), std::min(ba_productText.size(),8)); + // Ticket-Number QByteArray ba_ticketNumber = codec->fromUnicode(printingData["ticketNumber"].toString()); memcpy((char*)dynTicketData->dynDat7, ba_ticketNumber.data(), std::min(ba_ticketNumber.size(),8)); - // DEBUG /* uint8_t* buf = dynTicketData->licensePlate;