This part of the 4.x documentation is for eZ Publish 4.0, only reference section is common for all eZ Publish 4.x versions as well as eZ Publish 5.x "LegacyStack", please select the version you are using for the most up to date documentation!
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.
Product Category Attribute
- 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 it. To do this, edit the product and select the desired category from the drop-down list "Category", as shown in the following screenshot.
Product Category List
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)
Ricardo Correia (17/04/2013 4:38 pm)