{% extends "commerce/_layouts/settings" %} {% set selectedItem = 'subscriptions/plans' %} {% block content %}

{{ "Subscription plans"|t('commerce') }}

{% if plans|length %} {% for plan in plans %} {% endfor %}
{{ "Name"|t('commerce') }} {{ "Handle"|t('commerce') }} {{ "Gateway"|t('commerce') }} {{ "Active subscriptions"|t('commerce') }} {{ "Enabled?"|t('commerce') }} {{ 'Information linked?'|t('commerce') }}
{{ plan.name }} {{ plan.handle }} {{ plan.gateway.name }} {{ plan.subscriptionCount }} {{ plan.enabled ? 'Yes'|t('commerce') : 'No'|t('commerce') }} {{ plan.planInformationId ? 'Yes'|t('commerce') : 'No'|t('commerce') }}
{% endif %}
{{ 'New subscription plan'|t('commerce') }}
{% endblock %} {% js %} var adminTable = new Craft.AdminTable({ tableSelector: '#plans', noObjectsSelector: '#no-plans', newObjectBtnSelector: '#newPlanButtonContainer', deleteAction: 'commerce/plans/archive-plan', confirmDeleteMessage: '{{ "Are you sure you want to archive the “{name}” subscription plan? It WILL NOT cancel the existing subscriptions."|t('commerce') }}', sortable: true, reorderAction: 'commerce/plans/reorder', reorderSuccessMessage: Craft.t('commerce', 'Plans reordered.') , reorderFailMessage: Craft.t('commerce', 'Couldn’t reorder plans.') }); {% endjs %}