Fux utf8 trouble on direct printing message

This commit is contained in:
Laurent Destailleur 2017-11-27 14:34:29 +01:00
parent 69725fe62f
commit f9e99e93c3
3 changed files with 3 additions and 2 deletions

View File

@ -64,7 +64,7 @@ if ($action == 'print_file' and $user->rights->printing->read)
{
//print '<pre>'.print_r($printer->errors, true).'</pre>';
setEventMessages($printer->error, $printer->errors);
setEventMessages($langs->trans("FileWasSentToPrinter", basename(GETPOST('file'))).' '.$langs->transnoentitiesnoconv("ViaModule").' '.$printer->name, null);
setEventMessages($langs->transnoentitiesnoconv("FileWasSentToPrinter", basename(GETPOST('file', 'alpha'))).' '.$langs->transnoentitiesnoconv("ViaModule").' '.$printer->name, null);
}
}
catch(Exception $e)

View File

@ -318,7 +318,7 @@ class printing_printgcp extends PrintingDriver
else dol_print_error($this->db);
$ret = $this->sendPrintToPrinter($printer_id, $file, $fileprint, $mimetype);
$this->errors = 'PRINTGCP: '.mb_convert_encoding($ret['errormessage'], "UTF-8");
$this->errors = 'PRINTGCP: '.$ret['errormessage'];
if ($ret['status']!=1) $error++;
return $error;
}

View File

@ -9,6 +9,7 @@ PrintingDriverDesc=Configuration variables for printing driver.
ListDrivers=List of drivers
PrintTestDesc=List of Printers.
FileWasSentToPrinter=File %s was sent to printer
ViaModule=via the module
NoActivePrintingModuleFound=No active driver to print document. Check setup of module %s.
PleaseSelectaDriverfromList=Please select a driver from list.
PleaseConfigureDriverfromList=Please configure the selected driver from list.