Rename module from cyp_withdrawalbutton to simple_withdrawalbutton

- Main file: cyp_withdrawalbutton.php -> simple_withdrawalbutton.php
- Admin controller: AdminCypWithdrawalController.php -> AdminSimpleWithdrawalController.php
- Class: Cyp_Withdrawalbutton -> Simple_withdrawalbutton
- DB table: cyp_withdrawal_request -> simple_withdrawal_request
- Config keys: CYP_WITHDRAWAL_* -> SIMPLE_WITHDRAWAL_*
- Admin tab: AdminCypWithdrawal -> AdminSimpleWithdrawal
- All template mod attributes updated
This commit is contained in:
Arne Weiss committed 2026-06-01 07:34:26 +02:00
1 parent 346ee7b616
commit 317d92b9d0
11 files changed
+89 -89

No files matched your search

+4 -4
View File
@@ -18,9 +18,9 @@ This is a classical PrestaShop legacy module with no npm, Composer, Makefile, or
| File | Role | | File | Role |
|------|------| |------|------|
| `cyp_withdrawalbutton.php` | Main module class: install/uninstall, config form, hook handlers, utility methods | | `simple_withdrawalbutton.php` | Main module class: install/uninstall, config form, hook handlers, utility methods |
| `controllers/front/withdraw.php` | Public front controller for the withdrawal form (no auth required) | | `controllers/front/withdraw.php` | Public front controller for the withdrawal form (no auth required) |
| `controllers/admin/AdminCypWithdrawalController.php` | Backoffice list/detail view with status management | | `controllers/admin/AdminSimpleWithdrawalController.php` | Backoffice list/detail view with status management |
### Request Flow ### Request Flow
@@ -32,7 +32,7 @@ This is a classical PrestaShop legacy module with no npm, Composer, Makefile, or
### Database ### Database
Single table `ps_cyp_withdrawal_request`. Schema is defined inline in `cyp_withdrawalbutton.php::install()` — no separate SQL files. Records are intentionally **not deleted on uninstall** (legal compliance). Single table `ps_cyp_withdrawal_request`. Schema is defined inline in `simple_withdrawalbutton.php::install()` — no separate SQL files. Records are intentionally **not deleted on uninstall** (legal compliance).
Key fields: `order_reference`, `withdrawal_scope` (ENUM: full|partial), `status` (ENUM: new|processing|closed), `customer_ip_hash` / `user_agent_hash` (SHA256, privacy). Key fields: `order_reference`, `withdrawal_scope` (ENUM: full|partial), `status` (ENUM: new|processing|closed), `customer_ip_hash` / `user_agent_hash` (SHA256, privacy).
@@ -54,6 +54,6 @@ The items field in `form.tpl` is conditionally shown via vanilla JS only when `w
- Use `pSQL()` for all DB string interpolation; `(int)` cast for integers - Use `pSQL()` for all DB string interpolation; `(int)` cast for integers
- Hook registration/deregistration in `install()`/`uninstall()` - Hook registration/deregistration in `install()`/`uninstall()`
- Admin tab registered as `AdminCypWithdrawal` — the controller class name must match - Admin tab registered as `AdminSimpleWithdrawal` — the controller class name must match
- Module config stored via `Configuration::get/updateValue()` - Module config stored via `Configuration::get/updateValue()`
- Email sending uses `Mail::Send()` with template files in `mails/{lang}/` - Email sending uses `Mail::Send()` with template files in `mails/{lang}/`
@@ -4,12 +4,12 @@ if (!defined('_PS_VERSION_')) {
exit; exit;
} }
class AdminCypWithdrawalController extends ModuleAdminController class AdminSimpleWithdrawalController extends ModuleAdminController
{ {
public function __construct() public function __construct()
{ {
$this->bootstrap = true; $this->bootstrap = true;
$this->table = Cyp_Withdrawalbutton::TABLE_REQUEST; $this->table = Simple_withdrawalbutton::TABLE_REQUEST;
$this->identifier = 'id_withdrawal_request'; $this->identifier = 'id_withdrawal_request';
$this->lang = false; $this->lang = false;
$this->explicitSelect = true; $this->explicitSelect = true;
@@ -103,7 +103,7 @@ class AdminCypWithdrawalController extends ModuleAdminController
} }
$ok = Db::getInstance()->update( $ok = Db::getInstance()->update(
Cyp_Withdrawalbutton::TABLE_REQUEST, Simple_withdrawalbutton::TABLE_REQUEST,
['status' => $status], ['status' => $status],
'`id_withdrawal_request` = ' . (int) $id '`id_withdrawal_request` = ' . (int) $id
); );
@@ -119,7 +119,7 @@ class AdminCypWithdrawalController extends ModuleAdminController
{ {
$id = (int) Tools::getValue($this->identifier); $id = (int) Tools::getValue($this->identifier);
$row = Db::getInstance()->getRow( $row = Db::getInstance()->getRow(
'SELECT * FROM `' . _DB_PREFIX_ . pSQL(Cyp_Withdrawalbutton::TABLE_REQUEST) . '` 'SELECT * FROM `' . _DB_PREFIX_ . pSQL(Simple_withdrawalbutton::TABLE_REQUEST) . '`
WHERE `id_withdrawal_request` = ' . (int) $id WHERE `id_withdrawal_request` = ' . (int) $id
); );
+3 -3
View File
@@ -4,7 +4,7 @@ if (!defined('_PS_VERSION_')) {
exit; exit;
} }
class Cyp_WithdrawalbuttonWithdrawModuleFrontController extends ModuleFrontController class Simple_withdrawalbuttonWithdrawModuleFrontController extends ModuleFrontController
{ {
public $ssl = true; public $ssl = true;
public $auth = false; public $auth = false;
@@ -32,8 +32,8 @@ class Cyp_WithdrawalbuttonWithdrawModuleFrontController extends ModuleFrontContr
'csrf_token' => $this->module->getFrontToken(), 'csrf_token' => $this->module->getFrontToken(),
'action_url' => $this->context->link->getModuleLink($this->module->name, 'withdraw', [], true), 'action_url' => $this->context->link->getModuleLink($this->module->name, 'withdraw', [], true),
'success_data' => $this->successData, 'success_data' => $this->successData,
'privacy_url' => (string) Configuration::get(Cyp_Withdrawalbutton::CONF_PRIVACY_URL), 'privacy_url' => (string) Configuration::get(Simple_withdrawalbutton::CONF_PRIVACY_URL),
'revocation_url' => (string) Configuration::get(Cyp_Withdrawalbutton::CONF_REVOCATION_URL), 'revocation_url' => (string) Configuration::get(Simple_withdrawalbutton::CONF_REVOCATION_URL),
]); ]);
if ($this->currentView === 'confirm') { if ($this->currentView === 'confirm') {
@@ -14,18 +14,18 @@ if (!defined('_PS_VERSION_')) {
exit; exit;
} }
class Cyp_Withdrawalbutton extends Module class Simple_withdrawalbutton extends Module
{ {
public const TABLE_REQUEST = 'cyp_withdrawal_request'; public const TABLE_REQUEST = 'simple_withdrawal_request';
public const CONF_SHOP_EMAIL = 'CYP_WITHDRAWAL_SHOP_EMAIL'; public const CONF_SHOP_EMAIL = 'SIMPLE_WITHDRAWAL_SHOP_EMAIL';
public const CONF_RATE_LIMIT = 'CYP_WITHDRAWAL_RATE_LIMIT'; public const CONF_RATE_LIMIT = 'SIMPLE_WITHDRAWAL_RATE_LIMIT';
public const CONF_PRIVACY_URL = 'CYP_WITHDRAWAL_PRIVACY_URL'; public const CONF_PRIVACY_URL = 'SIMPLE_WITHDRAWAL_PRIVACY_URL';
public const CONF_REVOCATION_URL = 'CYP_WITHDRAWAL_REVOCATION_URL'; public const CONF_REVOCATION_URL = 'SIMPLE_WITHDRAWAL_REVOCATION_URL';
public const CONF_RETENTION_MONTHS = 'CYP_WITHDRAWAL_RETENTION_MONTHS'; public const CONF_RETENTION_MONTHS = 'SIMPLE_WITHDRAWAL_RETENTION_MONTHS';
public function __construct() public function __construct()
{ {
$this->name = 'cyp_withdrawalbutton'; $this->name = 'simple_withdrawalbutton';
$this->tab = 'administration'; $this->tab = 'administration';
$this->version = '0.1.0'; $this->version = '0.1.0';
$this->author = 'Cyprès / Akiko Sake'; $this->author = 'Cyprès / Akiko Sake';
@@ -100,7 +100,7 @@ class Cyp_Withdrawalbutton extends Module
private function installTab() private function installTab()
{ {
$className = 'AdminCypWithdrawal'; $className = 'AdminSimpleWithdrawal';
if ((int) Tab::getIdFromClassName($className) > 0) { if ((int) Tab::getIdFromClassName($className) > 0) {
return true; return true;
} }
@@ -120,7 +120,7 @@ class Cyp_Withdrawalbutton extends Module
private function uninstallTab() private function uninstallTab()
{ {
$idTab = (int) Tab::getIdFromClassName('AdminCypWithdrawal'); $idTab = (int) Tab::getIdFromClassName('AdminSimpleWithdrawal');
if ($idTab <= 0) { if ($idTab <= 0) {
return true; return true;
} }
@@ -182,7 +182,7 @@ class Cyp_Withdrawalbutton extends Module
} }
} }
$adminLink = $this->context->link->getAdminLink('AdminCypWithdrawal'); $adminLink = $this->context->link->getAdminLink('AdminSimpleWithdrawal');
$withdrawalLink = $this->getWithdrawalLink(); $withdrawalLink = $this->getWithdrawalLink();
$this->context->smarty->assign([ $this->context->smarty->assign([
@@ -488,7 +488,7 @@ class Cyp_Withdrawalbutton extends Module
} }
$scopeLabel = $this->getScopeLabel($data['withdrawal_scope'], $isoCode); $scopeLabel = $this->getScopeLabel($data['withdrawal_scope'], $isoCode);
$adminLink = $this->context->link->getAdminLink('AdminCypWithdrawal'); $adminLink = $this->context->link->getAdminLink('AdminSimpleWithdrawal');
$templateVars = [ $templateVars = [
'{id_withdrawal_request}' => (string) $idWithdrawalRequest, '{id_withdrawal_request}' => (string) $idWithdrawalRequest,
+5 -5
View File
@@ -1,14 +1,14 @@
<div class="panel"> <div class="panel">
<h3><i class="icon-info-circle"></i> {l s='Installation notes' mod='cyp_withdrawalbutton'}</h3> <h3><i class="icon-info-circle"></i> {l s='Installation notes' mod='simple_withdrawalbutton'}</h3>
<p> <p>
{l s='Frontend withdrawal page:' mod='cyp_withdrawalbutton'} {l s='Frontend withdrawal page:' mod='simple_withdrawalbutton'}
<a href="{$withdrawal_link|escape:'html':'UTF-8'}" target="_blank" rel="noopener noreferrer">{$withdrawal_link|escape:'html':'UTF-8'}</a> <a href="{$withdrawal_link|escape:'html':'UTF-8'}" target="_blank" rel="noopener noreferrer">{$withdrawal_link|escape:'html':'UTF-8'}</a>
</p> </p>
<p> <p>
{l s='Back office requests:' mod='cyp_withdrawalbutton'} {l s='Back office requests:' mod='simple_withdrawalbutton'}
<a href="{$admin_link|escape:'html':'UTF-8'}">{l s='Open withdrawal requests' mod='cyp_withdrawalbutton'}</a> <a href="{$admin_link|escape:'html':'UTF-8'}">{l s='Open withdrawal requests' mod='simple_withdrawalbutton'}</a>
</p> </p>
<p class="help-block"> <p class="help-block">
{l s='The module keeps existing withdrawal records when it is uninstalled. Delete the database table manually only after checking your retention obligations.' mod='cyp_withdrawalbutton'} {l s='The module keeps existing withdrawal records when it is uninstalled. Delete the database table manually only after checking your retention obligations.' mod='simple_withdrawalbutton'}
</p> </p>
</div> </div>
+18 -18
View File
@@ -1,7 +1,7 @@
<div class="panel"> <div class="panel">
<div class="panel-heading"> <div class="panel-heading">
<i class="icon-undo"></i> <i class="icon-undo"></i>
{l s='Withdrawal request' mod='cyp_withdrawalbutton'} #{$request.id_withdrawal_request|intval} {l s='Withdrawal request' mod='simple_withdrawalbutton'} #{$request.id_withdrawal_request|intval}
</div> </div>
<div class="row"> <div class="row">
@@ -9,46 +9,46 @@
<table class="table"> <table class="table">
<tbody> <tbody>
<tr> <tr>
<th>{l s='Received' mod='cyp_withdrawalbutton'}</th> <th>{l s='Received' mod='simple_withdrawalbutton'}</th>
<td>{$request.created_at|escape:'html':'UTF-8'}</td> <td>{$request.created_at|escape:'html':'UTF-8'}</td>
</tr> </tr>
<tr> <tr>
<th>{l s='Confirmation sent' mod='cyp_withdrawalbutton'}</th> <th>{l s='Confirmation sent' mod='simple_withdrawalbutton'}</th>
<td>{if $request.confirmation_sent_at}{$request.confirmation_sent_at|escape:'html':'UTF-8'}{else}-{/if}</td> <td>{if $request.confirmation_sent_at}{$request.confirmation_sent_at|escape:'html':'UTF-8'}{else}-{/if}</td>
</tr> </tr>
<tr> <tr>
<th>{l s='Order reference' mod='cyp_withdrawalbutton'}</th> <th>{l s='Order reference' mod='simple_withdrawalbutton'}</th>
<td> <td>
{$request.order_reference|escape:'html':'UTF-8'} {$request.order_reference|escape:'html':'UTF-8'}
{if $order_link != ''} {if $order_link != ''}
<br><a href="{$order_link|escape:'html':'UTF-8'}">{l s='Open order' mod='cyp_withdrawalbutton'}</a> <br><a href="{$order_link|escape:'html':'UTF-8'}">{l s='Open order' mod='simple_withdrawalbutton'}</a>
{/if} {/if}
</td> </td>
</tr> </tr>
<tr> <tr>
<th>{l s='Name' mod='cyp_withdrawalbutton'}</th> <th>{l s='Name' mod='simple_withdrawalbutton'}</th>
<td>{$request.customer_name|escape:'html':'UTF-8'}</td> <td>{$request.customer_name|escape:'html':'UTF-8'}</td>
</tr> </tr>
<tr> <tr>
<th>{l s='Email' mod='cyp_withdrawalbutton'}</th> <th>{l s='Email' mod='simple_withdrawalbutton'}</th>
<td><a href="mailto:{$request.customer_email|escape:'html':'UTF-8'}">{$request.customer_email|escape:'html':'UTF-8'}</a></td> <td><a href="mailto:{$request.customer_email|escape:'html':'UTF-8'}">{$request.customer_email|escape:'html':'UTF-8'}</a></td>
</tr> </tr>
<tr> <tr>
<th>{l s='Scope' mod='cyp_withdrawalbutton'}</th> <th>{l s='Scope' mod='simple_withdrawalbutton'}</th>
<td> <td>
{if $request.withdrawal_scope == 'partial'} {if $request.withdrawal_scope == 'partial'}
{l s='Partial withdrawal' mod='cyp_withdrawalbutton'} {l s='Partial withdrawal' mod='simple_withdrawalbutton'}
{else} {else}
{l s='Full order' mod='cyp_withdrawalbutton'} {l s='Full order' mod='simple_withdrawalbutton'}
{/if} {/if}
</td> </td>
</tr> </tr>
<tr> <tr>
<th>{l s='Affected items / quantities' mod='cyp_withdrawalbutton'}</th> <th>{l s='Affected items / quantities' mod='simple_withdrawalbutton'}</th>
<td>{if $request.withdrawal_items_text}{$request.withdrawal_items_text|escape:'html':'UTF-8'|nl2br nofilter}{else}-{/if}</td> <td>{if $request.withdrawal_items_text}{$request.withdrawal_items_text|escape:'html':'UTF-8'|nl2br nofilter}{else}-{/if}</td>
</tr> </tr>
<tr> <tr>
<th>{l s='Message' mod='cyp_withdrawalbutton'}</th> <th>{l s='Message' mod='simple_withdrawalbutton'}</th>
<td>{if $request.message}{$request.message|escape:'html':'UTF-8'|nl2br nofilter}{else}-{/if}</td> <td>{if $request.message}{$request.message|escape:'html':'UTF-8'|nl2br nofilter}{else}-{/if}</td>
</tr> </tr>
</tbody> </tbody>
@@ -59,15 +59,15 @@
<form method="post" action="{$current_index|escape:'html':'UTF-8'}&amp;token={$token|escape:'html':'UTF-8'}"> <form method="post" action="{$current_index|escape:'html':'UTF-8'}&amp;token={$token|escape:'html':'UTF-8'}">
<input type="hidden" name="{$identifier|escape:'html':'UTF-8'}" value="{$request.id_withdrawal_request|intval}"> <input type="hidden" name="{$identifier|escape:'html':'UTF-8'}" value="{$request.id_withdrawal_request|intval}">
<div class="form-group"> <div class="form-group">
<label for="cyp_withdrawal_status">{l s='Status' mod='cyp_withdrawalbutton'}</label> <label for="cyp_withdrawal_status">{l s='Status' mod='simple_withdrawalbutton'}</label>
<select name="status" id="cyp_withdrawal_status" class="form-control"> <select name="status" id="cyp_withdrawal_status" class="form-control">
<option value="new" {if $request.status == 'new'}selected{/if}>{l s='New' mod='cyp_withdrawalbutton'}</option> <option value="new" {if $request.status == 'new'}selected{/if}>{l s='New' mod='simple_withdrawalbutton'}</option>
<option value="processing" {if $request.status == 'processing'}selected{/if}>{l s='Processing' mod='cyp_withdrawalbutton'}</option> <option value="processing" {if $request.status == 'processing'}selected{/if}>{l s='Processing' mod='simple_withdrawalbutton'}</option>
<option value="closed" {if $request.status == 'closed'}selected{/if}>{l s='Closed' mod='cyp_withdrawalbutton'}</option> <option value="closed" {if $request.status == 'closed'}selected{/if}>{l s='Closed' mod='simple_withdrawalbutton'}</option>
</select> </select>
</div> </div>
<button type="submit" name="submitCypWithdrawalStatus" value="1" class="btn btn-primary"> <button type="submit" name="submitCypWithdrawalStatus" value="1" class="btn btn-primary">
{l s='Update status' mod='cyp_withdrawalbutton'} {l s='Update status' mod='simple_withdrawalbutton'}
</button> </button>
</form> </form>
</div> </div>
@@ -75,7 +75,7 @@
<div class="panel-footer"> <div class="panel-footer">
<a href="{$back_link|escape:'html':'UTF-8'}" class="btn btn-default"> <a href="{$back_link|escape:'html':'UTF-8'}" class="btn btn-default">
<i class="process-icon-back"></i> {l s='Back to list' mod='cyp_withdrawalbutton'} <i class="process-icon-back"></i> {l s='Back to list' mod='simple_withdrawalbutton'}
</a> </a>
</div> </div>
</div> </div>
+12 -12
View File
@@ -1,6 +1,6 @@
<section class="cyp-withdrawal-page"> <section class="cyp-withdrawal-page">
<header class="page-header"> <header class="page-header">
<h1>{l s='Widerruf bestätigen' mod='cyp_withdrawalbutton'}</h1> <h1>{l s='Widerruf bestätigen' mod='simple_withdrawalbutton'}</h1>
</header> </header>
<div class="card card-block"> <div class="card card-block">
@@ -14,34 +14,34 @@
</div> </div>
{/if} {/if}
<p>{l s='Bitte prüfen Sie Ihre Angaben. Wenn die Angaben korrekt sind, können Sie Ihren Widerruf jetzt absenden.' mod='cyp_withdrawalbutton'}</p> <p>{l s='Bitte prüfen Sie Ihre Angaben. Wenn die Angaben korrekt sind, können Sie Ihren Widerruf jetzt absenden.' mod='simple_withdrawalbutton'}</p>
<dl class="row"> <dl class="row">
<dt class="col-sm-4">{l s='Name' mod='cyp_withdrawalbutton'}</dt> <dt class="col-sm-4">{l s='Name' mod='simple_withdrawalbutton'}</dt>
<dd class="col-sm-8">{$form_data.customer_name|escape:'html':'UTF-8'}</dd> <dd class="col-sm-8">{$form_data.customer_name|escape:'html':'UTF-8'}</dd>
<dt class="col-sm-4">{l s='E-Mail-Adresse' mod='cyp_withdrawalbutton'}</dt> <dt class="col-sm-4">{l s='E-Mail-Adresse' mod='simple_withdrawalbutton'}</dt>
<dd class="col-sm-8">{$form_data.customer_email|escape:'html':'UTF-8'}</dd> <dd class="col-sm-8">{$form_data.customer_email|escape:'html':'UTF-8'}</dd>
<dt class="col-sm-4">{l s='Bestellnummer / Bestellreferenz' mod='cyp_withdrawalbutton'}</dt> <dt class="col-sm-4">{l s='Bestellnummer / Bestellreferenz' mod='simple_withdrawalbutton'}</dt>
<dd class="col-sm-8">{$form_data.order_reference|escape:'html':'UTF-8'}</dd> <dd class="col-sm-8">{$form_data.order_reference|escape:'html':'UTF-8'}</dd>
<dt class="col-sm-4">{l s='Widerruf betrifft' mod='cyp_withdrawalbutton'}</dt> <dt class="col-sm-4">{l s='Widerruf betrifft' mod='simple_withdrawalbutton'}</dt>
<dd class="col-sm-8"> <dd class="col-sm-8">
{if $form_data.withdrawal_scope == 'partial'} {if $form_data.withdrawal_scope == 'partial'}
{l s='einen Teil der Bestellung' mod='cyp_withdrawalbutton'} {l s='einen Teil der Bestellung' mod='simple_withdrawalbutton'}
{else} {else}
{l s='die gesamte Bestellung' mod='cyp_withdrawalbutton'} {l s='die gesamte Bestellung' mod='simple_withdrawalbutton'}
{/if} {/if}
</dd> </dd>
{if $form_data.withdrawal_scope == 'partial'} {if $form_data.withdrawal_scope == 'partial'}
<dt class="col-sm-4">{l s='Betroffene Artikel / Mengen' mod='cyp_withdrawalbutton'}</dt> <dt class="col-sm-4">{l s='Betroffene Artikel / Mengen' mod='simple_withdrawalbutton'}</dt>
<dd class="col-sm-8">{$form_data.withdrawal_items_text|escape:'html':'UTF-8'|nl2br nofilter}</dd> <dd class="col-sm-8">{$form_data.withdrawal_items_text|escape:'html':'UTF-8'|nl2br nofilter}</dd>
{/if} {/if}
{if $form_data.message != ''} {if $form_data.message != ''}
<dt class="col-sm-4">{l s='Nachricht / Bemerkung' mod='cyp_withdrawalbutton'}</dt> <dt class="col-sm-4">{l s='Nachricht / Bemerkung' mod='simple_withdrawalbutton'}</dt>
<dd class="col-sm-8">{$form_data.message|escape:'html':'UTF-8'|nl2br nofilter}</dd> <dd class="col-sm-8">{$form_data.message|escape:'html':'UTF-8'|nl2br nofilter}</dd>
{/if} {/if}
</dl> </dl>
@@ -60,10 +60,10 @@
</div> </div>
<button type="submit" name="submit_withdrawal_confirm" value="1" class="btn btn-primary"> <button type="submit" name="submit_withdrawal_confirm" value="1" class="btn btn-primary">
{l s='Widerruf bestätigen' mod='cyp_withdrawalbutton'} {l s='Widerruf bestätigen' mod='simple_withdrawalbutton'}
</button> </button>
<button type="submit" name="submit_withdrawal_back" value="1" class="btn btn-secondary" formaction="{$action_url|escape:'html':'UTF-8'}"> <button type="submit" name="submit_withdrawal_back" value="1" class="btn btn-secondary" formaction="{$action_url|escape:'html':'UTF-8'}">
{l s='Angaben ändern' mod='cyp_withdrawalbutton'} {l s='Angaben ändern' mod='simple_withdrawalbutton'}
</button> </button>
</form> </form>
</div> </div>
+17 -17
View File
@@ -1,17 +1,17 @@
<section class="cyp-withdrawal-page"> <section class="cyp-withdrawal-page">
<header class="page-header"> <header class="page-header">
<h1>{l s='Vertrag widerrufen' mod='cyp_withdrawalbutton'}</h1> <h1>{l s='Vertrag widerrufen' mod='simple_withdrawalbutton'}</h1>
</header> </header>
<div class="card card-block"> <div class="card card-block">
<p> <p>
{l s='Sie können hier den Vertrag zu einer Bestellung vollständig oder teilweise widerrufen. Bitte geben Sie die Bestellnummer und bei einem Teilwiderruf die betroffenen Artikel und Mengen an.' mod='cyp_withdrawalbutton'} {l s='Sie können hier den Vertrag zu einer Bestellung vollständig oder teilweise widerrufen. Bitte geben Sie die Bestellnummer und bei einem Teilwiderruf die betroffenen Artikel und Mengen an.' mod='simple_withdrawalbutton'}
</p> </p>
{if isset($revocation_url) && $revocation_url != ''} {if isset($revocation_url) && $revocation_url != ''}
<p> <p>
<a href="{$revocation_url|escape:'html':'UTF-8'}" target="_blank" rel="noopener"> <a href="{$revocation_url|escape:'html':'UTF-8'}" target="_blank" rel="noopener">
{l s='Unsere Widerrufsbelehrung (14-Tage-Frist)' mod='cyp_withdrawalbutton'} {l s='Unsere Widerrufsbelehrung (14-Tage-Frist)' mod='simple_withdrawalbutton'}
</a> </a>
</p> </p>
{/if} {/if}
@@ -35,74 +35,74 @@
<div class="form-group"> <div class="form-group">
<label for="cyp_withdrawal_customer_name" class="form-control-label"> <label for="cyp_withdrawal_customer_name" class="form-control-label">
{l s='Name' mod='cyp_withdrawalbutton'} <span aria-hidden="true">*</span> {l s='Name' mod='simple_withdrawalbutton'} <span aria-hidden="true">*</span>
</label> </label>
<input class="form-control" type="text" id="cyp_withdrawal_customer_name" name="customer_name" maxlength="255" required value="{$form_data.customer_name|default:''|escape:'html':'UTF-8'}"> <input class="form-control" type="text" id="cyp_withdrawal_customer_name" name="customer_name" maxlength="255" required value="{$form_data.customer_name|default:''|escape:'html':'UTF-8'}">
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="cyp_withdrawal_customer_email" class="form-control-label"> <label for="cyp_withdrawal_customer_email" class="form-control-label">
{l s='E-Mail-Adresse für die Eingangsbestätigung' mod='cyp_withdrawalbutton'} <span aria-hidden="true">*</span> {l s='E-Mail-Adresse für die Eingangsbestätigung' mod='simple_withdrawalbutton'} <span aria-hidden="true">*</span>
</label> </label>
<input class="form-control" type="email" id="cyp_withdrawal_customer_email" name="customer_email" maxlength="255" required value="{$form_data.customer_email|default:''|escape:'html':'UTF-8'}"> <input class="form-control" type="email" id="cyp_withdrawal_customer_email" name="customer_email" maxlength="255" required value="{$form_data.customer_email|default:''|escape:'html':'UTF-8'}">
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="cyp_withdrawal_order_reference" class="form-control-label"> <label for="cyp_withdrawal_order_reference" class="form-control-label">
{l s='Bestellnummer / Bestellreferenz' mod='cyp_withdrawalbutton'} <span aria-hidden="true">*</span> {l s='Bestellnummer / Bestellreferenz' mod='simple_withdrawalbutton'} <span aria-hidden="true">*</span>
</label> </label>
<input class="form-control" type="text" id="cyp_withdrawal_order_reference" name="order_reference" maxlength="64" required value="{$form_data.order_reference|default:''|escape:'html':'UTF-8'}"> <input class="form-control" type="text" id="cyp_withdrawal_order_reference" name="order_reference" maxlength="64" required value="{$form_data.order_reference|default:''|escape:'html':'UTF-8'}">
</div> </div>
<fieldset class="form-group"> <fieldset class="form-group">
<legend class="form-control-label"> <legend class="form-control-label">
{l s='Widerruf betrifft' mod='cyp_withdrawalbutton'} <span aria-hidden="true">*</span> {l s='Widerruf betrifft' mod='simple_withdrawalbutton'} <span aria-hidden="true">*</span>
</legend> </legend>
<label class="custom-radio" for="cyp_withdrawal_scope_full"> <label class="custom-radio" for="cyp_withdrawal_scope_full">
<input type="radio" id="cyp_withdrawal_scope_full" name="withdrawal_scope" value="full" {if !isset($form_data.withdrawal_scope) || $form_data.withdrawal_scope != 'partial'}checked{/if}> <input type="radio" id="cyp_withdrawal_scope_full" name="withdrawal_scope" value="full" {if !isset($form_data.withdrawal_scope) || $form_data.withdrawal_scope != 'partial'}checked{/if}>
<span></span> <span></span>
{l s='die gesamte Bestellung' mod='cyp_withdrawalbutton'} {l s='die gesamte Bestellung' mod='simple_withdrawalbutton'}
</label> </label>
<br> <br>
<label class="custom-radio" for="cyp_withdrawal_scope_partial"> <label class="custom-radio" for="cyp_withdrawal_scope_partial">
<input type="radio" id="cyp_withdrawal_scope_partial" name="withdrawal_scope" value="partial" {if isset($form_data.withdrawal_scope) && $form_data.withdrawal_scope == 'partial'}checked{/if}> <input type="radio" id="cyp_withdrawal_scope_partial" name="withdrawal_scope" value="partial" {if isset($form_data.withdrawal_scope) && $form_data.withdrawal_scope == 'partial'}checked{/if}>
<span></span> <span></span>
{l s='einen Teil der Bestellung' mod='cyp_withdrawalbutton'} {l s='einen Teil der Bestellung' mod='simple_withdrawalbutton'}
</label> </label>
</fieldset> </fieldset>
<div class="form-group" id="cyp-withdrawal-items-group"> <div class="form-group" id="cyp-withdrawal-items-group">
<label for="cyp_withdrawal_items_text" class="form-control-label"> <label for="cyp_withdrawal_items_text" class="form-control-label">
{l s='Welche Artikel / Mengen möchten Sie widerrufen?' mod='cyp_withdrawalbutton'} {l s='Welche Artikel / Mengen möchten Sie widerrufen?' mod='simple_withdrawalbutton'}
</label> </label>
<textarea class="form-control" id="cyp_withdrawal_items_text" name="withdrawal_items_text" rows="4" maxlength="5000" placeholder="{l s='Beispiel: 1x Tomizu 720 ml, 2x Magokoro 300 ml' mod='cyp_withdrawalbutton'}">{$form_data.withdrawal_items_text|default:''|escape:'html':'UTF-8'}</textarea> <textarea class="form-control" id="cyp_withdrawal_items_text" name="withdrawal_items_text" rows="4" maxlength="5000" placeholder="{l s='Beispiel: 1x Tomizu 720 ml, 2x Magokoro 300 ml' mod='simple_withdrawalbutton'}">{$form_data.withdrawal_items_text|default:''|escape:'html':'UTF-8'}</textarea>
<small class="form-text text-muted"> <small class="form-text text-muted">
{l s='Nur bei einem Teilwiderruf erforderlich.' mod='cyp_withdrawalbutton'} {l s='Nur bei einem Teilwiderruf erforderlich.' mod='simple_withdrawalbutton'}
</small> </small>
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="cyp_withdrawal_message" class="form-control-label"> <label for="cyp_withdrawal_message" class="form-control-label">
{l s='Nachricht / Bemerkung optional' mod='cyp_withdrawalbutton'} {l s='Nachricht / Bemerkung optional' mod='simple_withdrawalbutton'}
</label> </label>
<textarea class="form-control" id="cyp_withdrawal_message" name="message" rows="4" maxlength="5000">{$form_data.message|default:''|escape:'html':'UTF-8'}</textarea> <textarea class="form-control" id="cyp_withdrawal_message" name="message" rows="4" maxlength="5000">{$form_data.message|default:''|escape:'html':'UTF-8'}</textarea>
</div> </div>
<p class="small text-muted"> <p class="small text-muted">
{l s='Pflichtfelder sind mit * gekennzeichnet. Ein Widerrufsgrund ist nicht erforderlich.' mod='cyp_withdrawalbutton'} {l s='Pflichtfelder sind mit * gekennzeichnet. Ein Widerrufsgrund ist nicht erforderlich.' mod='simple_withdrawalbutton'}
</p> </p>
<p class="small text-muted"> <p class="small text-muted">
{l s='Ihre Angaben (Name, E-Mail-Adresse) werden zur Bearbeitung Ihrer Widerrufserklärung verarbeitet. Rechtsgrundlage: Art. 6 Abs. 1 lit. b und c DSGVO.' mod='cyp_withdrawalbutton'} {l s='Ihre Angaben (Name, E-Mail-Adresse) werden zur Bearbeitung Ihrer Widerrufserklärung verarbeitet. Rechtsgrundlage: Art. 6 Abs. 1 lit. b und c DSGVO.' mod='simple_withdrawalbutton'}
{if isset($privacy_url) && $privacy_url != ''} {if isset($privacy_url) && $privacy_url != ''}
<a href="{$privacy_url|escape:'html':'UTF-8'}" target="_blank" rel="noopener"> <a href="{$privacy_url|escape:'html':'UTF-8'}" target="_blank" rel="noopener">
{l s='Datenschutzerklärung' mod='cyp_withdrawalbutton'} {l s='Datenschutzerklärung' mod='simple_withdrawalbutton'}
</a> </a>
{/if} {/if}
</p> </p>
<button type="submit" name="submit_withdrawal_prepare" value="1" class="btn btn-primary"> <button type="submit" name="submit_withdrawal_prepare" value="1" class="btn btn-primary">
{l s='Angaben prüfen' mod='cyp_withdrawalbutton'} {l s='Angaben prüfen' mod='simple_withdrawalbutton'}
</button> </button>
</form> </form>
</div> </div>
+12 -12
View File
@@ -1,59 +1,59 @@
<section class="cyp-withdrawal-page"> <section class="cyp-withdrawal-page">
<header class="page-header"> <header class="page-header">
<h1>{l s='Widerruf übermittelt' mod='cyp_withdrawalbutton'}</h1> <h1>{l s='Widerruf übermittelt' mod='simple_withdrawalbutton'}</h1>
</header> </header>
<div class="card card-block"> <div class="card card-block">
{if isset($success_data.mail_ok) && $success_data.mail_ok} {if isset($success_data.mail_ok) && $success_data.mail_ok}
<div class="alert alert-success"> <div class="alert alert-success">
{l s='Ihr Widerruf wurde übermittelt. Eine Eingangsbestätigung wurde an die angegebene E-Mail-Adresse gesendet.' mod='cyp_withdrawalbutton'} {l s='Ihr Widerruf wurde übermittelt. Eine Eingangsbestätigung wurde an die angegebene E-Mail-Adresse gesendet.' mod='simple_withdrawalbutton'}
</div> </div>
{else} {else}
<div class="alert alert-warning"> <div class="alert alert-warning">
{l s='Ihr Widerruf wurde gespeichert, aber die automatische Eingangsbestätigung konnte möglicherweise nicht versendet werden. Bitte kontaktieren Sie uns zusätzlich per E-Mail, falls Sie keine Bestätigung erhalten.' mod='cyp_withdrawalbutton'} {l s='Ihr Widerruf wurde gespeichert, aber die automatische Eingangsbestätigung konnte möglicherweise nicht versendet werden. Bitte kontaktieren Sie uns zusätzlich per E-Mail, falls Sie keine Bestätigung erhalten.' mod='simple_withdrawalbutton'}
</div> </div>
{/if} {/if}
<dl class="row"> <dl class="row">
{if isset($success_data.created_at)} {if isset($success_data.created_at)}
<dt class="col-sm-4">{l s='Eingang:' mod='cyp_withdrawalbutton'}</dt> <dt class="col-sm-4">{l s='Eingang:' mod='simple_withdrawalbutton'}</dt>
<dd class="col-sm-8">{$success_data.created_at|escape:'html':'UTF-8'}</dd> <dd class="col-sm-8">{$success_data.created_at|escape:'html':'UTF-8'}</dd>
{/if} {/if}
{if isset($success_data.customer_email)} {if isset($success_data.customer_email)}
<dt class="col-sm-4">{l s='E-Mail-Adresse:' mod='cyp_withdrawalbutton'}</dt> <dt class="col-sm-4">{l s='E-Mail-Adresse:' mod='simple_withdrawalbutton'}</dt>
<dd class="col-sm-8">{$success_data.customer_email|escape:'html':'UTF-8'}</dd> <dd class="col-sm-8">{$success_data.customer_email|escape:'html':'UTF-8'}</dd>
{/if} {/if}
{if isset($success_data.order_reference) && $success_data.order_reference != ''} {if isset($success_data.order_reference) && $success_data.order_reference != ''}
<dt class="col-sm-4">{l s='Bestellnummer / Bestellreferenz' mod='cyp_withdrawalbutton'}</dt> <dt class="col-sm-4">{l s='Bestellnummer / Bestellreferenz' mod='simple_withdrawalbutton'}</dt>
<dd class="col-sm-8">{$success_data.order_reference|escape:'html':'UTF-8'}</dd> <dd class="col-sm-8">{$success_data.order_reference|escape:'html':'UTF-8'}</dd>
{/if} {/if}
{if isset($success_data.withdrawal_scope)} {if isset($success_data.withdrawal_scope)}
<dt class="col-sm-4">{l s='Widerruf betrifft' mod='cyp_withdrawalbutton'}</dt> <dt class="col-sm-4">{l s='Widerruf betrifft' mod='simple_withdrawalbutton'}</dt>
<dd class="col-sm-8"> <dd class="col-sm-8">
{if $success_data.withdrawal_scope == 'partial'} {if $success_data.withdrawal_scope == 'partial'}
{l s='einen Teil der Bestellung' mod='cyp_withdrawalbutton'} {l s='einen Teil der Bestellung' mod='simple_withdrawalbutton'}
{else} {else}
{l s='die gesamte Bestellung' mod='cyp_withdrawalbutton'} {l s='die gesamte Bestellung' mod='simple_withdrawalbutton'}
{/if} {/if}
</dd> </dd>
{/if} {/if}
{if isset($success_data.withdrawal_items_text) && $success_data.withdrawal_items_text != ''} {if isset($success_data.withdrawal_items_text) && $success_data.withdrawal_items_text != ''}
<dt class="col-sm-4">{l s='Betroffene Artikel / Mengen' mod='cyp_withdrawalbutton'}</dt> <dt class="col-sm-4">{l s='Betroffene Artikel / Mengen' mod='simple_withdrawalbutton'}</dt>
<dd class="col-sm-8">{$success_data.withdrawal_items_text|escape:'html':'UTF-8'|nl2br nofilter}</dd> <dd class="col-sm-8">{$success_data.withdrawal_items_text|escape:'html':'UTF-8'|nl2br nofilter}</dd>
{/if} {/if}
{if isset($success_data.message) && $success_data.message != ''} {if isset($success_data.message) && $success_data.message != ''}
<dt class="col-sm-4">{l s='Nachricht / Bemerkung' mod='cyp_withdrawalbutton'}</dt> <dt class="col-sm-4">{l s='Nachricht / Bemerkung' mod='simple_withdrawalbutton'}</dt>
<dd class="col-sm-8">{$success_data.message|escape:'html':'UTF-8'|nl2br nofilter}</dd> <dd class="col-sm-8">{$success_data.message|escape:'html':'UTF-8'|nl2br nofilter}</dd>
{/if} {/if}
</dl> </dl>
<p class="small text-muted"> <p class="small text-muted">
{l s='Diese Bestätigung betrifft nur den Eingang Ihrer Widerrufserklärung. Die weitere Bearbeitung und Prüfung erfolgt separat.' mod='cyp_withdrawalbutton'} {l s='Diese Bestätigung betrifft nur den Eingang Ihrer Widerrufserklärung. Die weitere Bearbeitung und Prüfung erfolgt separat.' mod='simple_withdrawalbutton'}
</p> </p>
</div> </div>
</section> </section>
+1 -1
View File
@@ -1,6 +1,6 @@
<a class="col-lg-4 col-md-6 col-sm-6 col-xs-12" id="withdrawal-link" href="{$withdrawal_link|escape:'html':'UTF-8'}" rel="nofollow"> <a class="col-lg-4 col-md-6 col-sm-6 col-xs-12" id="withdrawal-link" href="{$withdrawal_link|escape:'html':'UTF-8'}" rel="nofollow">
<span class="link-item"> <span class="link-item">
<i class="material-icons">undo</i> <i class="material-icons">undo</i>
{l s='Vertrag widerrufen' mod='cyp_withdrawalbutton'} {l s='Vertrag widerrufen' mod='simple_withdrawalbutton'}
</span> </span>
</a> </a>
+1 -1
View File
@@ -1,5 +1,5 @@
<div class="cyp-withdrawal-footer" style="margin-top: 1rem;"> <div class="cyp-withdrawal-footer" style="margin-top: 1rem;">
<a href="{$withdrawal_link|escape:'html':'UTF-8'}" class="cyp-withdrawal-link" rel="nofollow"> <a href="{$withdrawal_link|escape:'html':'UTF-8'}" class="cyp-withdrawal-link" rel="nofollow">
{l s='Vertrag widerrufen' mod='cyp_withdrawalbutton'} {l s='Vertrag widerrufen' mod='simple_withdrawalbutton'}
</a> </a>
</div> </div>