Release 2.0.6 (#3900)
* cleanup invoice templates * cleanup invoice translations * fix invoice datetime for now * support invoice archive order by number and status * bump version * allow meta-field sub-classing * removed unused translation task.delete * prevent null in str_replace
This commit is contained in:
@@ -61,13 +61,16 @@ final class InvoiceRendererType extends AbstractType
|
||||
|
||||
$type = array_pop($parts);
|
||||
|
||||
if (!\is_string($type)) {
|
||||
return 'programmatic';
|
||||
}
|
||||
|
||||
return match (strtolower($type)) {
|
||||
'json', 'txt', 'xml' => 'programmatic',
|
||||
'pdf' => 'PDF',
|
||||
'docx', 'doc' => 'Word',
|
||||
'xls', 'xlsx' => 'Excel',
|
||||
'ods' => 'LibreOffice',
|
||||
default => ucfirst($type),
|
||||
default => strtoupper($type),
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user