Surcharge

Surcharge

Surcharge

A Surcharge represents an arbitrary extra item on an Order which is not a ProductVariant. It can be used to e.g. represent payment-related surcharges.

Signature

class Surcharge extends VendureEntity {
  constructor(input?: DeepPartial<Surcharge>)
  @Column()
    description: string;
  @Column()
    listPrice: number;
  @Column()
    listPriceIncludesTax: boolean;
  @Column()
    sku: string;
  @Column('simple-json')
    taxLines: TaxLine[];
  @ManyToOne(type => Order, order => order.surcharges, { onDelete: 'CASCADE' })
    order: Order;
  @ManyToOne(type => OrderModification, orderModification => orderModification.surcharges)
    orderModification: OrderModification;
  price: number
  priceWithTax: number
  taxRate: number
}

Extends

Members

constructor

method
type:
(input?: DeepPartial<Surcharge>) => Surcharge

description

property
type:
string

listPrice

property
type:
number

listPriceIncludesTax

property
type:
boolean

sku

property
type:
string

taxLines

property
type:
TaxLine[]

order

property
type:
Order

orderModification

property

price

property
type:
number

priceWithTax

property
type:
number

taxRate

property
type:
number