The "Country dependent VAT" approach supposes that each of your products can be assigned a product category. The next subsections reveal how this can be achieved. The administration interface makes it possible to add, remove and rename product categories as described in the "Managing product categories" section.
Adding new attribute to a product class
It is necessary to add an attribute of the product category datatype to your product class otherwise it will be impossible to assign a category to a product. The following text reveals how this can be done.
- Access the "Setup" tab in the administration interface, click "Classes" on the left and select the "Content" class group. You should see the list of classes assigned to this group. Find your product class there and click the "Edit" button located in the same line of the list. You will be taken to the class edit interface.
- Select the "Product category" datatype from the drop-down list located in the bottom, click the "Add attribute" button and edit the newly added attribute as shown below. The following screenshot shows the fragment of the class edit interface with newly added attribute of the product category datatype.
Class attribute edit interface for the "Product category" datatype.
- Specify the identifier of the newly added attribute in the "ProductCategoryAttribute" setting located under the "[VATSettings]" section of an override for the "settings/shop.ini" configuration file.
Assigning a category to a product
If your product class contains an attribute of the product category datatype then you can assign a category to a product when editing this product. To do this, edit this product and select the desired category from the drop-down list called "Category" as shown in the following screenshot.
A fragment of the product edit interface.
Please note that product categories are always used together with the dynamic VAT type (as you can see in the screenshot above the last item called "Determined by VAT charging rules" is selected). There is no point to select a category for a product with fixed VAT rate.
Svitlana Shatokhina (11/05/2006 12:59 pm)
Svitlana Shatokhina (12/05/2006 2:53 pm)