{% extends "commerce/_layouts/settings" %} {% block content %}

{{ "Product Types"|t('commerce') }}

{% if productTypes|length %} {% for productType in productTypes %} {% endfor %}
{{ "Name"|t('commerce') }} {{ "Handle"|t('commerce') }} {{ "Has Variants?"|t('commerce') }} {{ "Available Shipping Categories"|t('commerce') }} {{ "Available Tax Categories"|t('commerce') }}
{{ productType.name }} {{ productType.handle }} {% if productType.hasVariants %} {% endif %} {% for cat in productType.getShippingCategories() %} {% if loop.first %}
    {% endif %} {% if currentUser.can('commerce-manageShipping') %}
  • {{ cat.name }}
  • {% else %}
  • {{ cat.name }}
  • {% endif %} {% if loop.last %}
{% endif %} {% endfor %}
{% for cat in productType.getTaxCategories() %} {% if loop.first %}
    {% endif %} {% if currentUser.can('commerce-manageTax') %}
  • {{ cat.name }}
  • {% else %}
  • {{ cat.name }}
  • {% endif %} {% if loop.last %}
{% endif %} {% endfor %}
{% endif %}
{{ 'New product type'|t('commerce') }}
{% endblock %} {% js %} var adminTable = new Craft.AdminTable({ tableSelector: '#producttypes', noObjectsSelector: '#noproducttypes', newObjectBtnSelector: '#newproductTypecontainer', deleteAction: 'commerce/product-types/delete-product-type', confirmDeleteMessage: '{{ "Are you sure you want to delete “{name}” and all its products? Please make sure you have a backup of your database before performing this destructive action."|t('commerce') }}' }); {% endjs %}