u
This commit is contained in:
@@ -44,7 +44,7 @@ import {
|
||||
|
||||
const cfg = manifestConfig('order');
|
||||
|
||||
const PAYMENT_TYPES = [
|
||||
export const PAYMENT_TYPES = [
|
||||
{ value: 'transfer', label: 'Banküberweisung', icon: AccountBalanceIcon },
|
||||
{ value: 'cash', label: 'Barzahlung', icon: PointOfSaleIcon },
|
||||
{ value: 'card', label: 'EC- / Kreditkarte', icon: CreditCardIcon },
|
||||
@@ -54,15 +54,15 @@ const PAYMENT_TYPES = [
|
||||
{ value: 'other', label: 'Sonstige', icon: PaymentsIcon },
|
||||
];
|
||||
|
||||
function typeLabel(val) {
|
||||
export function typeLabel(val) {
|
||||
const match = PAYMENT_TYPES.find((t) => t.value === val);
|
||||
return match?.label || val || 'Zahlung';
|
||||
}
|
||||
|
||||
function typeIcon(val) {
|
||||
export function typeIcon(val, sx = { fontSize: 18 }) {
|
||||
const match = PAYMENT_TYPES.find((t) => t.value === val);
|
||||
const IconComp = match?.icon || PaymentsIcon;
|
||||
return <IconComp sx={{ fontSize: 18 }} />;
|
||||
return <IconComp sx={sx} />;
|
||||
}
|
||||
|
||||
const rowSx = {
|
||||
|
||||
Reference in New Issue
Block a user