This commit is contained in:
2025-04-01 00:38:54 +02:00
parent d4d4c0c09d
commit 87da06293a
22351 changed files with 5168854 additions and 7538 deletions

View File

@@ -0,0 +1,279 @@
{extends file="helpers/form/form.tpl"}
{block name="script"}
$(document).ready(function() {
$('.iframe-upload').fancybox({
'width' : 900,
'height' : 600,
'type' : 'iframe',
'autoScale' : false,
'autoDimensions': false,
'fitToView' : false,
'autoSize' : false,
onUpdate : function() {
$('.fancybox-iframe').contents().find('a.link').data('field_id', $(this.element).data("input-name"));
$('.fancybox-iframe').contents().find('a.link').attr('data-field_id', $(this.element).data("input-name"));
},
afterShow: function() {
$('.fancybox-iframe').contents().find('a.link').data('field_id', $(this.element).data("input-name"));
$('.fancybox-iframe').contents().find('a.link').attr('data-field_id', $(this.element).data("input-name"));
},
helpers: {
overlay: {
locked: false
}
}
});
document.querySelectorAll('.x13gpsr_image_option_selector li').forEach(function (item) {
item.addEventListener('click', function () {
var target = document.querySelector(item.dataset.target);
var value = item.dataset.option;
if (target) {
target.value = value;
var event = new Event('change');
target.dispatchEvent(event);
}
document.querySelectorAll('.x13gpsr_image_option_selector.x13gpsr_image_option_selector_' + item.dataset.target.replace('#', '') + ' li').forEach(function (li) {
li.classList.remove('active');
});
item.classList.add('active');
handleFieldDependencies();
});
});
handleFieldDependencies();
let $fieldDependencies = getFieldDependencies();
for (let i = 0; i < $fieldDependencies.length; i++) {
$(document).off($fieldDependencies[i]).on('change', '[name="'+ $fieldDependencies[i] +'"]', function () {
handleFieldDependencies($fieldDependencies[i]);
}).bind(i);
}
function getFieldDependencies()
{
let fieldDependencies = [];
$('.depends-on').each(function (index, node) {
var $element = $(node);
var $classes = $element.prop('class').split(/\s+/);
for (var i = 0; i < $classes.length; i++) {
let current = $classes[i];
if (current.includes('depends-field')) {
let parts = current.replace('depends-field-', '').split(':');
fieldDependencies.push(parts[0]);
}
}
});
return fieldDependencies;
}
function inArray(needle, haystack) {
var length = haystack.length;
for(var i = 0; i < length; i++) {
if(haystack[i] == needle) return true;
}
return false;
}
function handleFieldDependencies(specificFieldName)
{
let specificField = specificFieldName || false;
$('.depends-on').each(function (index, node) {
var $element = $(node);
var $classes = $element.prop('class').split(/\s+/);
let $method = 'match';
let $fieldName = false,
$fieldValue = false,
$fieldType = false,
$currentValue;
if ($element.hasClass('depends-on-multiple')) {
$fieldValue = [];
$fieldName = [];
$fieldType = [];
}
for (var i = 0; i < $classes.length; i++) {
let current = $classes[i];
if (current.includes('depends-where')) {
if (current == 'depends-where-is-not') {
$method = 'not_match';
}
}
if (current.includes('depends-field')) {
let parts = current.replace('depends-field-', '').split(':');
let $nameOfTheField = parts[0];
let $valueOfTheField = parts[1].split('--');
if ($element.hasClass('depends-on-multiple')) {
$fieldName.push($nameOfTheField);
$fieldValue.push($valueOfTheField);
} else {
$fieldName = $nameOfTheField;
$fieldValue = $valueOfTheField;
}
if($('input[name="'+ $nameOfTheField +'"]').length > 0){
$typeOfTheField = $('input[name="'+ $nameOfTheField +'"]').attr('type');
}else if($('textarea[name="'+ $nameOfTheField +'"]').length == 1){
$typeOfTheField = 'textarea';
}else if($('select[name="'+ $nameOfTheField +'"]').length == 1){
$typeOfTheField = 'select';
}
if ($element.hasClass('depends-on-multiple')) {
$fieldType.push($typeOfTheField);
} else {
$fieldType = $typeOfTheField;
}
}
}
if ($element.hasClass('depends-on-multiple')) {
var showBasedOnMultiple = true;
for (var i = 0; i < $fieldName.length; i++) {
if ($fieldType[i] == 'checkbox' || $fieldType[i] == 'radio'){
$currentValue = $('[name="'+ $fieldName[i] +'"]:checked').val();
} else {
$currentValue = $('[name="'+ $fieldName[i] +'"]').val();
}
$searchedValues = $fieldValue[i];
if ($method == 'match') {
if (!inArray($currentValue, $searchedValues)) {
showBasedOnMultiple = false;
}
}
if ($method == 'not_match') {
if (inArray($currentValue, $searchedValues)) {
showBasedOnMultiple = false;
}
}
}
if (showBasedOnMultiple) {
$element.show();
} else {
$element.hide();
}
} else {
if (specificField && specificField != $fieldName) {
return;
}
if ($fieldType == 'checkbox' || $fieldType == 'radio'){
$currentValue = $('[name="'+ $fieldName +'"]:checked').val();
} else {
$currentValue = $('[name="'+ $fieldName +'"]').val();
}
if ($method == 'not_match' && $fieldName && $fieldValue) {
if ($fieldValue.includes($currentValue)) {
$element.hide();
} else {
$element.show();
}
}
if ($method == 'match' && $fieldName && $fieldValue) {
if ($fieldValue.includes($currentValue)) {
$element.show();
} else {
$element.hide();
}
}
}
});
}
});
{/block}
{* {block name="label"}
{if isset($input.errors) && !empty($input.errors)}
<div class="col-lg-12">
<div class="alert alert-danger">{$input.errors}</div>
</div>
{/if}
{$smarty.block.parent}
{/block} *}
{block name="input"}
{if $input.type == 'file_lang'}
<div class="row">
{foreach from=$languages item=language}
{if $languages|count > 1}
<div class="translatable-field lang-{$language.id_lang|escape:'UTF-8'}" {if $language.id_lang != $defaultFormLanguage}style="display:none"{/if}>
{/if}
<div class="col-lg-9">
{*$fields_value|d*}
{if isset($fields_value['image']) && $fields_value['image'][$language.id_lang] != ''}
<img src="{$image_baseurl|escape:'UTF-8'}{$language.iso_code|escape:'UTF-8'}/{$fields_value['image'][$language.id_lang]|escape:'UTF-8'}" class="img-thumbnail" /><br><br>
{/if}
<input id="{$input.name|escape:'UTF-8'}_{$language.id_lang|escape:'UTF-8'}" type="file" name="{$input.name|escape:'UTF-8'}_{$language.id_lang|escape:'UTF-8'}" class="hide" />
<div class="dummyfile input-group">
<span class="input-group-addon"><i class="icon-file"></i></span>
<input id="{$input.name|escape:'UTF-8'}_{$language.id_lang|escape:'UTF-8'}-name" type="text" class="disabled" name="filename" readonly />
<span class="input-group-btn">
<button id="{$input.name|escape:'UTF-8'}_{$language.id_lang|escape:'UTF-8'}-selectbutton" type="button" name="submitAddAttachments" class="btn btn-default">
<i class="icon-folder-open"></i> {l s='Choose a file' mod='x13gpsr'}
</button>
</span>
</div>
</div>
{if $languages|count > 1}
<div class="col-lg-2">
<button type="button" class="btn btn-default dropdown-toggle" tabindex="-1" data-toggle="dropdown">
{$language.iso_code|escape:'UTF-8'}
<span class="caret"></span>
</button>
<ul class="dropdown-menu">
{foreach from=$languages item=lang}
<li><a href="javascript:hideOtherLanguage({$lang.id_lang|escape:'UTF-8'});" tabindex="-1">{$lang.name}</a></li>
{/foreach}
</ul>
</div>
{/if}
{if $languages|count > 1}
</div>
{/if}
<script>
$(document).ready(function() {
$('#{$input.name|escape:'UTF-8'}_{$language.id_lang|escape:'UTF-8'}-selectbutton').click(function(e) {
$('#{$input.name|escape:'UTF-8'}_{$language.id_lang|escape:'UTF-8'}').trigger('click');
});
$('#{$input.name|escape:'UTF-8'}_{$language.id_lang|escape:'UTF-8'}').change(function(e) {
var val = $(this).val();
var file = val.split(/[\\/]/);
$('#{$input.name|escape:'UTF-8'}_{$language.id_lang|escape:'UTF-8'}-name').val(file[file.length - 1]);
});
});
</script>
{/foreach}
</div>
{elseif $input.type == 'image_option'}
<div class="x13gpsr_image_option_selector_wrapper">
<ul class="x13gpsr_image_option_selector x13gpsr_image_option_selector_{$input.name|escape:'html':'UTF-8'}">
{foreach $input.options as $option}
<li data-option="{$option.id}" data-target="#{$input.name}"
class="col-md-3{if $fields_value[$input.name] == $option.id} active{/if}">
<div class="x13gpsr_image_option_wrapper">
<img class="img-fluid img-responsive" src="{$option.img}" alt="{$option.label}" title="{$option.label}">
<p class="text-center text-muted">{$option.label}</p>
</div>
</li>
{/foreach}
</ul>
<select name="{$input.name}" id="{$input.name}">
{foreach $input.options as $option}
<option value="{$option.id}" {if $fields_value[$input.name] == $option.id}selected{/if}>{$option.label}</option>
{/foreach}
</select>
</div>
<hr>
{elseif $input.type == 'selectImage'}
<input name="{$input.name|escape:'html':'UTF-8'}" id="{$input.name|escape:'html':'UTF-8'}" value="{$fields_value[$input.name]|escape:'html':'UTF-8'}" type="text" />
<p>
<a href="filemanager/dialog.php?type=1&amp;field_id={$input.name|escape:'html':'UTF-8'}" class="btn btn-default iframe-upload" data-input-name="{$input.name|escape:'html':'UTF-8'}" type="button">{l s='Image selector' mod='x13gpsr'} <i class="icon-angle-right"></i></a>
</p>
{else}
{$smarty.block.parent}
{/if}
{/block}

View File

@@ -0,0 +1,11 @@
<?php
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT');
header('Cache-Control: no-store, no-cache, must-revalidate');
header('Cache-Control: post-check=0, pre-check=0', false);
header('Pragma: no-cache');
header('Location: ../');
exit;

View File

@@ -0,0 +1,11 @@
<?php
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT');
header('Cache-Control: no-store, no-cache, must-revalidate');
header('Cache-Control: post-check=0, pre-check=0', false);
header('Pragma: no-cache');
header('Location: ../');
exit;

View File

@@ -0,0 +1,11 @@
<?php
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT');
header('Cache-Control: no-store, no-cache, must-revalidate');
header('Cache-Control: post-check=0, pre-check=0', false);
header('Pragma: no-cache');
header('Location: ../');
exit;

View File

@@ -0,0 +1,13 @@
{* <div class="panel" id="module_default_configuration">
<div class="panel-heading">
{l s='General information about using GPSR module from X13' mod='x13gpsr'}
</div>
<div class="alert alert-warning">
{l s='Lorem ipsum.' mod='x13gpsr'}<br/>
</div>
</div>
<div class="panel">
{l s='Module documentation:' mod='x13gpsr'} <a href="https://x13.pl/doc/dokumentacja-historia-cen-omnibus-dla-prestashop" target="_blank">https://x13.pl/doc/dokumentacja-historia-cen-omnibus-dla-prestashop</a>
</div> *}

View File

@@ -0,0 +1,42 @@
<h4>{l s='Map Your Columns' mod='x13gpsr'}</h4>
<table class="table">
<thead>
<tr>
<th>{l s='Field' mod='x13gpsr'}</th>
<th>{l s='CSV Column' mod='x13gpsr'}</th>
</tr>
</thead>
<tbody>
{foreach from=$importableFields key=field item=details}
<tr>
<td>
<span>{$field}{if $details.required} <span style="color:red">*</span>{/if}</span>
</td>
<td>
<select class="form-control mapping-select" data-field="{$field}">
<option value="">{l s='Select a column' mod='x13gpsr'}</option>
<option value="skip">{l s='Skip Column' mod='x13gpsr'}</option>
{foreach from=$csvHeaders item=header key=index}
<option data-column="{$header|escape:'html'}" value="{$index}">{$header|escape:'html'}</option>
{/foreach}
</select>
</td>
</tr>
{/foreach}
{foreach from=$languages item=language}
<tr>
<td>extra_note_{$language.iso_code}</td>
<td>
<select class="form-control mapping-select" data-field="extra_note_{$language.iso_code}">
<option value="">{l s='Select a column' mod='x13gpsr'}</option>
<option value="skip">{l s='Skip Column' mod='x13gpsr'}</option>
{foreach from=$csvHeaders item=header key=index}
<option data-column="{$header|escape:'html'}" value="{$index}">{$header|escape:'html'}</option>
{/foreach}
</select>
</td>
</tr>
{/foreach}
</tbody>
</table>
<input type="hidden" id="xgpsr-temp-file-path" value="{$tempFilePath}">

View File

@@ -0,0 +1,39 @@
<div class="modal fade" id="xgpsr-csv-import-modal" tabindex="-1" role="dialog" aria-hidden="true">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title">{l s='Import CSV' mod='x13gpsr'}</h5>
<button type="button" class="close" data-dismiss="modal">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<div id="xgpsr-mapping-error-container" style="display: none;"></div>
<form id="xgpsr-csv-import-form">
<div class="form-group">
<label for="xgpsr-csv-file">{l s='Select CSV File' mod='x13gpsr'}</label>
<input type="file" class="form-control" id="xgpsr-csv-file" name="xgpsr-csv-file" required>
</div>
<div class="form-group">
<label for="xgpsr-csv-delimeter">{l s='CSV Delimiter' mod='x13gpsr'}</label>
<select class="form-control" id="xgpsr-csv-delimeter" name="xgpsr-csv-delimeter">
<option value=";">{l s='Semicolon (;)' mod='x13gpsr'}</option>
<option value=",">{l s='Comma (,)' mod='x13gpsr'}</option>
<option value="_">{l s='Underline (_)' mod='x13gpsr'}</option>
<option value="|">{l s='Pipe (|)' mod='x13gpsr'}</option>
<option value="\t">{l s='Tab' mod='x13gpsr'}</option>
</select>
</div>
<input type="hidden" id="xgpsr-temp-file-path" name="xgpsr-temp-file-path" value="">
</form>
<div id="xgpsr-mapping-container"></div>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary"
data-dismiss="modal">{l s='Close' mod='x13gpsr'}</button>
<button type="button" id="xgpsr-process-mapping" class="btn btn-primary"
disabled>{l s='Import' mod='x13gpsr'}</button>
</div>
</div>
</div>
</div>

View File

@@ -0,0 +1,11 @@
<?php
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT');
header('Cache-Control: no-store, no-cache, must-revalidate');
header('Cache-Control: post-check=0, pre-check=0', false);
header('Pragma: no-cache');
header('Location: ../');
exit;

View File

@@ -0,0 +1,14 @@
<div class="panel">
<div class="panel-heading">
{l s='Using the GPSR module from x13.pl' mod='x13gpsr'}
</div>
<div class="alert alert-warning">
<ul>
<li>{l s='After installing the module, you must check whether the information about the manufacturer and the person responsible is displayed correctly in the store.' mod='x13gpsr'}</li>
{* <li>{l s='After installing the module, you must fill in additional product information, including warnings and certificates, instructions, technical data, and attachments.' mod='x13gpsr'}</li> *}
<li>{l s='Make sure that you have full product safety information on the product page, which you can fill in directly in the store using features and description.' mod='x13gpsr'}</li>
<li>{l s='This module is provided as-is. All responsibility for compliance with the law rests with the store administrator.' mod='x13gpsr'}</li>
</ul>
</div>
</div>

View File

@@ -0,0 +1,8 @@
<a
href="{$href|escape:'html':'UTF-8'}"
title="{$title|escape:'html':'UTF-8'}"
data-action="{$action|escape:'html':'UTF-8'}"
data-type={$type|escape:'html':'UTF-8'}
data-id="{$product_id}" data-name="{$product_name}">
<i class="{$icon|escape:'html':'UTF-8'}"></i>&nbsp;{$title|escape:'html':'UTF-8'}
</a>

View File

@@ -0,0 +1,13 @@
<h2 class="h2">{l s='Products without a brand' mod='x13gpsr'}</h2>
<div class="alert alert-info">
{l s='Below you can find a list of products that do not have a brand assigned. You can assign a brand to them by selecting products and then using Bulk Update. This should help you to better manage the relation between responsible manufacturers and persons and their brands.' mod='x13gpsr'}
</div>
{if $hasDefaultResponsibleManufacturerAssigned}
<div class="alert alert-warning">
{l s='You have enabled the option to assign a default responsible manufacturer (it is set to: %s) for products that do not have a brand assigned. This option is enabled in the Responsible Manufacturers tab. Options set here for products with no brands will have a higher priority.' mod='x13gpsr' sprintf=$defaultResponsibleManufacturerName}
</div>
{/if}
<hr/>

View File

@@ -0,0 +1,18 @@
<h2 class="h2">{l s='Products without a responsible manufacturer' mod='x13gpsr'}</h2>
<div class="alert alert-warning">
<p>
<b>
{l s='Below you can find a list of products that do not have a responsible manufacturer assigned. You can assign a responsible manufacturer to them by selecting products and then using Bulk Update.' mod='x13gpsr'}
</b>
</p>
<p>
{l s='Be careful, assigning a responsible manufacturer to a product will remove the current responsible manufacturer.' mod='x13gpsr'}
</p>
<p class="text-danger">
{l s='If you already have a mapping between a Responsible Manufacturer and a Brand, performing an update action here will override your previously set mapping.' mod='x13gpsr'}
</p>
<p>
{l s='Options set for individual products have a higher priority. If possible, use PrestaShop Brands to map responsible manufacturers to products.' mod='x13gpsr'}
</p>
</div>
<hr/>

View File

@@ -0,0 +1,18 @@
<h2 class="h2">{l s='Products without a responsible person' mod='x13gpsr'}</h2>
<div class="alert alert-warning">
<p>
<b>
{l s='Below you can find a list of products that do not have a responsible person assigned. You can assign a responsible person to them by selecting products and then using Bulk Update.' mod='x13gpsr'}
</b>
</p>
<p>
{l s='Be careful, assigning a responsible person to a product will remove the current responsible person.' mod='x13gpsr'}
</p>
<p class="text-danger">
{l s='If you already have a mapping between a Responsible person and a Brand, performing an update action here will override your previously set mapping.' mod='x13gpsr'}
</p>
<p>
{l s='Options set for individual products have a higher priority. If possible, use PrestaShop Brands to map responsible persons to products.' mod='x13gpsr'}
</p>
</div>
<hr/>

View File

@@ -0,0 +1,56 @@
<div class="x13gpsr-kpi">
<div class="col">
<div class="panel x13gpsr-kpi-panel bpsr-kpi-no-brand">
<h4 class="x13gpsr-kpi-heading">
<img src="{$url_img}brand.svg" width="42" height="42">
{l s='Unbranded products' mod='x13gpsr'}
</h4>
<p class="x13gpsr-kpi-desc">
{l s='The number of all products that do not have a brand assigned.' mod='x13gpsr'}</p>
<p class="x13gpsr-kpi-number {$classNoBrand}">
<span>{$nbOfProductsWithNoBrand}</span> {l s='pcs' mod='x13gpsr'}
</p>
{if $isMultiStoreUsed}<span class="x13gpsr-kpi-multistore">{l s='(in all shop)' mod='x13gpsr'}</span>{/if}
</div>
</div>
<div class="col">
<div class="panel x13gpsr-kpi-panel bpsr-kpi-no-brand">
<h4 class="x13gpsr-kpi-heading">
<img src="{$url_img}responsible-manufacturer.svg" width="42" height="42">
{l s='No manufacturer assigned' mod='x13gpsr'}
</h4>
<p class="x13gpsr-kpi-desc">
{l s='Number of products that do not have an assigned responsible manufacturer by brand and individual.' mod='x13gpsr'}
</p>
<p class="x13gpsr-kpi-number {$classNoManufacturer}">
<span>{$nbOfProductsWithNoResponsibleManufacturer}</span> {l s='pcs' mod='x13gpsr'}
</p>
{if $isMultiStoreUsed}<span class="x13gpsr-kpi-multistore">{l s='(in all shop)' mod='x13gpsr'}</span>{/if}
</div>
</div>
<div class="col">
<div class="panel x13gpsr-kpi-panel bpsr-kpi-no-brand">
<h4 class="x13gpsr-kpi-heading">
<img src="{$url_img}responsible-person.svg" width="42" height="42">
{l s='No responsible person assigned' mod='x13gpsr'}
</h4>
<p class="x13gpsr-kpi-desc">
{l s='Number of products that do not have an assigned responsible person by brand and individual.' mod='x13gpsr'}<br/>
<span>{l s='Only required for non-EU products.' mod='x13gpsr'}</span>
</p>
<p class="x13gpsr-kpi-number {$classNoPerson}">
<span>{$nbOfProductsWithNoResponsiblePerson}</span> {l s='pcs' mod='x13gpsr'}
</p>
{if $isMultiStoreUsed}<span class="x13gpsr-kpi-multistore">{l s='(in all shop)' mod='x13gpsr'}</span>{/if}
</div>
</div>
</div>
<div class="alert alert-info">
{l s='This tab allows you to monitor products that do not have brands, manufacturers or responsible persons.' mod='x13gpsr'}<br/>
{l s='Here you can quickly assign missing data.' mod='x13gpsr'}<br/>
{l s='Remember that assigning manufacturers or responsible persons works as an individual assignment and will overwrite the setting by manufacturer after mapping. Make sure that you do not want to assign only brands, and based on them the data about the responsible person and manufacturer will be transferred automatically.' mod='x13gpsr'}
</div>
<hr/>

View File

@@ -0,0 +1,17 @@
<div class="alert alert-info">
{l s='In PrestaShop, the term "Brand" has been used instead of "Manufacturer" for quite some time. To make bulk data management easier, we decided to add a "Manufacturers" tab, where you can link the Brands from your store.' mod='x13gpsr'}<br/>
<br/>
<strong>{l s='What is the difference between a Brand and a Manufacturer?' mod='x13gpsr'}</strong><br/>
{l s='In short, a manufacturer is the company responsible for producing a product. However, it can manage multiple brands, which may belong to the same product category or entirely different ones.' mod='x13gpsr'}<br/>
{l s='For example, P&G (Procter & Gamble) is the manufacturer responsible for brands like Pampers, Oral-B, and Gillette. Similarly, Mars Incorporated is the manufacturer behind brands such as M&Ms, Pedigree, and Orbit.' mod='x13gpsr'}<br/>
<br/>
<strong>
{if $isX13AllegroInstalled}
{l s='You are using our PrestaShop integration with Allegro!' mod='x13gpsr'}<br/>
{else}
{l s='It looks like you are not using our Allegro Integration module yet!' mod='x13gpsr'}<br/>
{/if}
</strong>
{l s='You can map each manufacturer from our GPSR module with a manufacturer from Allegro - thanks to this, when listing and updating offers, their data will be transferred automatically.' mod='x13gpsr'} - wkrótce<br/><br/>
{l s='Keep in mind that while responsible manufacturers are typically mapped to brands for convenience, you can override these assignments for individual products directly. This flexibility allows you to customize the data as needed.' mod='x13gpsr'}
</div>

View File

@@ -0,0 +1,16 @@
<div class="alert alert-info">
{l s='When selling products originating from outside the European Union (EU), you are required to provide a contact person responsible for product safety. This can be either an individual or a company.' mod='x13gpsr'}<br/>
{l s='Typically, such a person is already designated within Europe, and information about them can be obtained from your supplier, importer, or manufacturer.' mod='x13gpsr'}<br/><br/>
{l s='To simplify assigning a responsible person to products, we have introduced the option to link them to multiple brands in your store.' mod='x13gpsr'}<br/>
<br/>
<strong>
{if $isX13AllegroInstalled}
{l s='You are using our PrestaShop integration with Allegro!' mod='x13gpsr'}<br/>
{else}
{l s='It looks like you are not using our Allegro Integration module yet!' mod='x13gpsr'}<br/>
{/if}
</strong>
{l s='You can map each responsible person from our GPSR module with a responsible person from Allegro - thanks to this, when listing and updating offers, their data will be transferred automatically.' mod='x13gpsr'} - wkrótce<br/><br/>
{l s='Keep in mind that while responsible persons are typically mapped to brands for convenience, you can override these assignments for individual products directly. This flexibility allows you to customize the data as needed.' mod='x13gpsr'}
</div>

View File

@@ -0,0 +1,15 @@
<div class="mb-3">
<h6 class="xgpsr-modal-bo-title">{l s='Selected Products' mod='x13gpsr'}</h6>
{if $selectedProducts|@count > 0}
<div style="max-height: 100px; overflow-y: auto; padding: 10px;">
{foreach from=$selectedProducts key=id item=name}
<div>
<strong>{$name}</strong> (ID: {$id})
<input type="hidden" name="selectedProducts[]" value="{$id}" data-name="{$name}">
</div>
{/foreach}
</div>
{else}
<div>{l s='No products selected.' mod='x13gpsr'}</div>
{/if}
</div>

View File

@@ -0,0 +1,9 @@
<div class="form-group">
<h6 class="xgpsr-modal-bo-title">{l s='Select a brand' mod='x13gpsr'}</h6>
<select id="id_brand" name="bulk_update_data[id_brand]" class="form-control">
<option value="0">{l s='Select a brand' mod='x13gpsr'}</option>
{foreach from=$brands item=brand}
<option value="{$brand.id_manufacturer}">{$brand.name}</option>
{/foreach}
</select>
</div>

View File

@@ -0,0 +1,42 @@
<div class="modal-dialog x13gpsr-modal" role="document">
<form>
<div class="modal-content">
<div class="modal-header x13gpsr-modal-header">
<h5 class="modal-title">{$x13gpsr_modal_title|escape}</h5>
<button type="button" class="close" data-dismiss="modal" aria-label="{l s='Close' mod='x13gpsr'}">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<div id="xgpsr-progress-container" style="display: none; margin-top: 15px;">
<div class="progress">
<div id="xgpsr-progress-bar" class="progress-bar" role="progressbar" style="width: 0%;"
aria-valuenow="0" aria-valuemin="0" aria-valuemax="100">0%</div>
</div>
</div>
{$x13gpsr_modal_selected_products_html nofilter}
<div id="xgpsr-updater-specific-container">
{$x13gpsr_modal_uppdater_specific_html nofilter}
</div>
<div class="x13gpsr-logs" style="display: none;">
<h6 class="xgpsr-modal-bo-title">{$eventLogText|escape:'html'}</h6>
<div id="xgpsr-bulk-update-logs">
{l s='Logs...' mod='x13gpsr'}
</div>
</div>
</div>
<div class="modal-footer d-flex justify-content-end">
<button type="button" class="btn btn-secondary" data-dismiss="modal" id="xgpsr-cancel-button">
{$cancelText|escape:'html'}
</button>
<button type="button" class="btn btn-primary" data-type="{$bulkEditType}" id="xgpsr-submit-bulk-update">
{$confirmText|escape:'html'}
</button>
<button type="button" class="btn btn-primary pull-right" data-dismiss="modal" id="xgpsr-close-button" style="display: none;">
{$closeText|escape:'html'}
</button>
</div>
</div>
</form>
</div>

View File

@@ -0,0 +1,10 @@
<div class="form-group">
<h6 class="xgpsr-modal-bo-title">{l s='Select a responsible manufacturer' mod='x13gpsr'}</h6>
<select name="bulk_update_data[id]" class="form-control">
<option value="0">{l s='Select a responsible manufacturer' mod='x13gpsr'}</option>
{* <option value="-1">{l s='Remove responsible manufacturer from the product individual settings' mod='x13gpsr'}</option> *}
{foreach from=$items item=record}
<option value="{$record.id}">{$record.name}</option>
{/foreach}
</select>
</div>

View File

@@ -0,0 +1,10 @@
<div class="form-group">
<h6 class="xgpsr-modal-bo-title">{l s='Select a responsible person' mod='x13gpsr'}</h6>
<select name="bulk_update_data[id]" class="form-control">
<option value="0">{l s='Select a responsible person' mod='x13gpsr'}</option>
{* <option value="-1">{l s='Remove responsible person from the product individual settings' mod='x13gpsr'}</option> *}
{foreach from=$items item=record}
<option value="{$record.id}">{$record.name}</option>
{/foreach}
</select>
</div>