Class PriceViewModel
- Namespace
- Dynamicweb.Ecommerce.ProductCatalog
- Assembly
- Dynamicweb.Ecommerce.dll
Represents a price with and without VAT for products, order lines etc.
public class PriceViewModel : FillableViewModelBase
- Inheritance
-
PriceViewModel
- Inherited Members
- Extension Methods
Properties
CurrencyCode
Gets or sets the currency code representing the value of the price and used for formatting prices.
public string CurrencyCode { get; set; }
Property Value
- string
The ISO currency symbol representing the currency code - a valid value from ISOCurrencySymbol.
Remarks
The formatting of the currency depends on the settings of the Currency being used for the price and will affect currency symbol, location of symbol and the decimal separator
Price
Gets or sets the display price - either the value of PriceWithVat or PriceWithoutVat.
public double Price { get; set; }
Property Value
- double
The price without any formatting, i.e. '123.34'.
Remarks
If ShowPricesWithVat is true, the Price property will return the value of PriceWithVat, otherwise the value of PriceWithoutVat
PriceFormatted
Gets or sets the display price formatted with currency code - either the value of PriceWithVatFormatted or PriceWithoutVatFormatted.
public string PriceFormatted { get; set; }
Property Value
- string
The display price using currency formatting, i.e. 'EUR 123,34', '123,34 kr.' or '$123.34'.
Remarks
If ShowPricesWithVat is true, the PriceFormatted property will return the value of PriceWithVatFormatted, otherwise the value of PriceWithoutVatFormatted.
The formatting of the currency depends on the settings of the Currency being used for the price and will affect currency symbol, location of symbol and the decimal separator
PriceFormattedNoSymbol
Gets or sets the display price formatted without currency code
public string PriceFormattedNoSymbol { get; set; }
Property Value
- string
The display price without currency symbol or code using currency formatting, i.e. '123,34' or '123.34'.
Remarks
If ShowPricesWithVat is true, the PriceFormattedNoSymbol property will return the value of PriceWithVat, otherwise the value of PriceWithoutVat.
The formatting of the currency depends on the settings of the Currency being used for the price and will affect location of symbol and the decimal separator
PriceWithVat
Gets or sets the price with VAT.
public double PriceWithVat { get; set; }
Property Value
- double
The price with VAT and without any formatting, i.e. '123.34'.
PriceWithVatFormatted
Gets or sets the price with VAT formatted with currency code.
public string PriceWithVatFormatted { get; set; }
Property Value
- string
The price with VAT using currency formatting, i.e. 'EUR 123,34', '123,34 kr.' or '$123.34'.
Remarks
The formatting of the currency depends on the settings of the Currency being used for the price and will affect currency symbol, location of symbol and the decimal separator
PriceWithoutVat
Gets or sets the price without VAT.
public double PriceWithoutVat { get; set; }
Property Value
- double
The price without VAT and without any formatting, i.e. '123.34'.
PriceWithoutVatFormatted
Gets or sets the price without VAT formatted with currency code.
public string PriceWithoutVatFormatted { get; set; }
Property Value
- string
The price without VAT using currency formatting, i.e. 'EUR 123,34', '123,34 kr.' or '$123.34'.
Remarks
The formatting of the currency depends on the settings of the Currency being used for the price and will affect currency symbol, location of symbol and the decimal separator
ReverseChargeForVat
Gets or sets a value indicating whether the VAT is reverse charged.
public bool ReverseChargeForVat { get; set; }
Property Value
ShowPricesWithVat
Gets or sets a value indicating whether the price should be shown with VAT.
public bool ShowPricesWithVat { get; set; }
Property Value
- bool
trueif prices should be shown with VAT; otherwise,false.
Remarks
If ShowPricesWithVat is true, the Price property will return the value of PriceWithVat, otherwise the value of PriceWithoutVat
VATPercent
Gets or sets the VAT percent.
public double VATPercent { get; set; }
Property Value
- double
The VAT percent without any formatting, i.e. '25'.
VATPercentFormatted
Gets or sets the VAT percent formatted with a percentage character.
public string VATPercentFormatted { get; set; }
Property Value
- string
The VAT percent formatted, i.e. '25%'.
Vat
Gets or sets the VAT amount.
public double Vat { get; set; }
Property Value
- double
The VAT without any formatting, i.e. '23.34'.
VatFormatted
Gets or sets the VAT amount formatted with currency code.
public string VatFormatted { get; set; }
Property Value
- string
The VAT using currency formatting, i.e. 'EUR 23,34' or '23,34 kr.' or '€23.34'.
Remarks
The formatting of the currency depends on the settings of the Currency being used for the price and will affect currency symbol, location of symbol and the decimal separator