You've already forked wc-licensed-product
Add complete plugin infrastructure for selling software with license keys: - New "Licensed Product" WooCommerce product type - License key generation (XXXX-XXXX-XXXX-XXXX format) on order completion - Domain-based license validation system - REST API endpoints (validate, status, activate, deactivate) - Customer My Account "Licenses" page - Admin license management under WooCommerce > Licenses - Checkout domain field for licensed products - Custom database tables for licenses and product versions - Twig template engine integration - Full i18n support with German (de_CH) translation Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
47 lines
1.9 KiB
Twig
47 lines
1.9 KiB
Twig
{% if not has_licenses %}
|
|
<p>{{ __('You have no licenses yet.') }}</p>
|
|
{% else %}
|
|
<table class="woocommerce-licenses-table shop_table shop_table_responsive">
|
|
<thead>
|
|
<tr>
|
|
<th>{{ __('License Key') }}</th>
|
|
<th>{{ __('Product') }}</th>
|
|
<th>{{ __('Domain') }}</th>
|
|
<th>{{ __('Status') }}</th>
|
|
<th>{{ __('Expires') }}</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for item in licenses %}
|
|
<tr>
|
|
<td data-title="{{ __('License Key') }}">
|
|
<code>{{ item.license.licenseKey }}</code>
|
|
</td>
|
|
<td data-title="{{ __('Product') }}">
|
|
{% if item.product_url %}
|
|
<a href="{{ esc_url(item.product_url) }}">{{ esc_html(item.product_name) }}</a>
|
|
{% else %}
|
|
{{ esc_html(item.product_name) }}
|
|
{% endif %}
|
|
</td>
|
|
<td data-title="{{ __('Domain') }}">
|
|
{{ esc_html(item.license.domain) }}
|
|
</td>
|
|
<td data-title="{{ __('Status') }}">
|
|
<span class="license-status license-status-{{ item.license.status }}">
|
|
{{ item.license.status|capitalize }}
|
|
</span>
|
|
</td>
|
|
<td data-title="{{ __('Expires') }}">
|
|
{% if item.license.expiresAt %}
|
|
{{ item.license.expiresAt|date('Y-m-d') }}
|
|
{% else %}
|
|
{{ __('Never') }}
|
|
{% endif %}
|
|
</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
{% endif %}
|