Previous Docs Version

The documentation you are viewing is for a previous version of Tea Commerce. Click here to jump to the current stable version.

VAT Group

GetVatGroup

Gets a vat group from a specfic store.

Arguments

Name Type Description
storeId long Id of the store.
vatGroupId long The vat group id.

Return values

Type Description
VatGroup A vat group object.

Example

@using TeaCommerce.Umbraco.Web
@using TeaCommerce.Api.Models
@{
  VatGroup vatGroup = TC.GetVatGroup(1, 2);
}

GetVatGroups

Gets all vat groups for a specific store.

Arguments

Name Type Description
storeId long Id of the store.

Return values

Type Description
IEnumerable<VatGroup> A collection of vat group objects.

Example

@using TeaCommerce.Umbraco.Web
@using TeaCommerce.Api.Models
@{
  IEnumerable<VatGroup> vatGroup = TC.GetVatGroups(1);
}

GetCurrentVatGroup

Gets the current vat group of the customer's session. If the customer has a current order the vat group of that order is returned.

Arguments

Name Type Description
storeId long Id of the store.

Return values

Type Description
VatGroup The current vat group.

Example

@using TeaCommerce.Umbraco.Web
@using TeaCommerce.Api.Models
@{
  VatGroup vatGroup = TC.GetCurrentVatGroup(1);
}

SetCurrentVatGroup

Changes the current vat group of the customer's session. The vat group is also changed for the customer's current order if present.

Arguments

Name Type Description
storeId long Id of the store.
vatGroupId long Id of the vat group to change to.

Return values

Type Description
VatGroup The new current vat group object.

Example

@using TeaCommerce.Umbraco.Web
@using TeaCommerce.Api.Models
@{
  VatGroup vatGroup = TC.GetVatGroup(1, 2);
}
Last Updated: 12/27/2018, 4:46:55 PM