Bladeren bron

changes

master
Florian Eisenmenger 4 jaren geleden
bovenliggende
commit
713becf4e6
11 gewijzigde bestanden met toevoegingen van 126 en 39 verwijderingen
  1. +12
    -15
      zenitPlatformAtmosSet1/src/Resources/app/storefront/dist/storefront/js/zenit-platform-atmos-set1.js
  2. +9
    -0
      zenitPlatformAtmosSet1/src/Resources/app/storefront/src/scss/component/_card.scss
  3. +1
    -1
      zenitPlatformAtmosSet1/src/Resources/app/storefront/src/scss/overrides.scss
  4. +19
    -1
      zenitPlatformAtmosSet1/src/Resources/views/storefront/component/buy-widget/buy-widget-price.html.twig
  5. +4
    -2
      zenitPlatformAtmosSet1/src/Resources/views/storefront/component/checkout/offcanvas-cart.html.twig
  6. +21
    -2
      zenitPlatformAtmosSet1/src/Resources/views/storefront/page/product-detail/buy-widget-price.html.twig
  7. +12
    -15
      zenitPlatformAtmosSet2/src/Resources/app/storefront/dist/storefront/js/zenit-platform-atmos-set2.js
  8. +9
    -0
      zenitPlatformAtmosSet2/src/Resources/app/storefront/src/scss/component/_card.scss
  9. +1
    -1
      zenitPlatformAtmosSet2/src/Resources/app/storefront/src/scss/overrides.scss
  10. +19
    -1
      zenitPlatformAtmosSet2/src/Resources/views/storefront/component/buy-widget/buy-widget-price.html.twig
  11. +19
    -1
      zenitPlatformAtmosSet2/src/Resources/views/storefront/page/product-detail/buy-widget-price.html.twig

+ 12
- 15
zenitPlatformAtmosSet1/src/Resources/app/storefront/dist/storefront/js/zenit-platform-atmos-set1.js Bestand weergeven

@@ -17,7 +17,8 @@ $(document).ready(function() {
dpInput.prop('disabled', true);
dpInput.wrap('<div class="spwn-date-wrapper"></div>');
$("<span id='spwn-remove-date' title='Zurücksetzen'></span>").insertAfter(dpInput);
$("<div id='spwn-delivery'><p></p><div class='spwn-delivery--time'></div></div>").insertAfter(".confirm-delivery-date");
let doNotShow = $(".do-not-show").length ? " class='do-not-show'" : "";
$("<div id='spwn-delivery'" + doNotShow + "><p></p><div class='spwn-delivery--time'></div></div>").insertAfter(".confirm-delivery-date");
fp.config.onChange.push(function() {
manipulateDateInputValue();
});
@@ -37,7 +38,11 @@ $(document).ready(function() {
});
/* Set first selectable day selected */
setDateSelected();

spawnDateInputValue = $(".confirm-delivery-date #dtgs-datepicker-inputfield").val();
if (spawnDateInputValue === '') {
setDateSelected();
}

changeDelivery(fp);
}
@@ -93,24 +98,16 @@ function manipulateDateInputValue() {
function setDateSelected() {
let spwnFirstSelectableDay = $(".flatpickr-day:not(.flatpickr-disabled)").first().text();
let spwnFPdate = new Date();

let spwnDay = spwnFPdate.getDate();
let spwnMonth = spwnFPdate.getMonth();
let spwnMonthTemp = 0;
// month +1 (january == 0)
spwnMonth = spwnMonth + 1;
if((String(spwnMonth)).length === 1) {
spwnMonthTemp = spwnMonth;
spwnMonth = '0' + spwnMonth;
}
if (spwnFirstSelectableDay < spwnDay) {
spwnMonth = spwnMonthTemp + 1;
if((String(spwnMonth)).length === 1) {
spwnMonth = '0' + spwnMonth;
}
// if selectable day in next month add +1 to month
spwnMonth = spwnMonth + 1;
}
let spwnFrmattedDate = spwnFPdate.getFullYear() + '/' + spwnMonth + '/' + spwnFirstSelectableDay;

fp.setDate(new Date(spwnFrmattedDate));
fp.setDate(new Date(spwnFrmattedDate), true);
spawnDateInputValue = spwnFirstSelectableDay + '.' + spwnMonth + '.' + spwnFPdate.getFullYear();
}

@@ -153,8 +150,8 @@ function changeDelivery(fp) {
if (spawnDateInputValue === "" || spawnDateInputValue.indexOf("Uhr") === -1) {
manipulateDateInputValue();
}
// If DPD date is not in Abendzustellung range
} else {
// If DPD date is not in Abendzustellung range
setDateSelected();
}
} else {


+ 9
- 0
zenitPlatformAtmosSet1/src/Resources/app/storefront/src/scss/component/_card.scss Bestand weergeven

@@ -86,11 +86,20 @@
border-radius: 3px;
background: rgba(#86B04B, 0.15);
color: #86B04B;
&.spwn-c-p-more {
background-color: #33548c;
color: #fff;
}
.icon {
min-width: 22px;
align-self: auto;
color: #86B04B;
}
&.spwn-c-p-more {
.icon {
color: #fff;
}
}
}
.cart-item {
&.is-discountable-item {


+ 1
- 1
zenitPlatformAtmosSet1/src/Resources/app/storefront/src/scss/overrides.scss Bestand weergeven

@@ -179,6 +179,6 @@ input.custom-number[type=number] {
}

.confirm-delivery-date.do-not-show,
#spwn-delivery {
#spwn-delivery.do-not-show {
display: none !important;
}

+ 19
- 1
zenitPlatformAtmosSet1/src/Resources/views/storefront/component/buy-widget/buy-widget-price.html.twig Bestand weergeven

@@ -4,7 +4,8 @@
{% set listPrice = price.listPrice %}
<p class="product-detail-price{% if listPrice.percentage > 0 %} with-list-price{% endif %}">
{{ price.unitPrice|currency }}{{ "general.star"|trans|sw_sanitize }}
{{ price.unitPrice|currency }}
{# {{ "general.star"|trans|sw_sanitize }}#}
</p>
{% set weekProductCount = 0 %}
@@ -43,4 +44,21 @@
{% endblock %}
{% endblock %}
{% endif %}
{% endblock %}
{% block buy_widget_price_unit %}
<div class="product-detail-price-unit">
{{ block ('buy_widget_price_unit_label') }}
{{ block ('buy_widget_price_unit_content') }}
{% if price.referencePrice is not null %}
{% block buy_widget_price_unit_reference_content %}
<span class="price-unit-reference-content">
({{ price.referencePrice.price|currency }} / {{ price.referencePrice.referenceUnit }} {{ price.referencePrice.unitName }})
{# {{ "general.star"|trans|sw_sanitize }}#}
</span>
{% endblock %}
{% endif %}
</div>
{% endblock %}

+ 4
- 2
zenitPlatformAtmosSet1/src/Resources/views/storefront/component/checkout/offcanvas-cart.html.twig Bestand weergeven

@@ -17,14 +17,16 @@
{% endfor %}
<div class="offcanvas-cart-items">
{# spawntree start #}
{% if customizedProductsCount == 1 || customizedProductsCount == 2 %}
<div class="spwn-customized-products">
{% if customizedProductsCount == 1 || customizedProductsCount == 2 || customizedProductsCount > 3 %}
<div class="spwn-customized-products{% if customizedProductsCount > 3 %} spwn-c-p-more{% endif %}">
{% sw_icon 'checkmark-circle' %}
<div class="spwn-customized-products--text">
{% if customizedProductsCount == 1 %}
{{ "checkout.diaekoProgramNoticeFirst"|trans|sw_sanitize }}
{% elseif customizedProductsCount == 2 %}
{{ "checkout.diaekoProgramNoticeSecond"|trans|sw_sanitize }}
{% elseif customizedProductsCount > 3 %}
{{ "checkout.diaekoProgramNoticeMore"|trans|sw_sanitize }}
{% endif %}
</div>
</div>


+ 21
- 2
zenitPlatformAtmosSet1/src/Resources/views/storefront/page/product-detail/buy-widget-price.html.twig Bestand weergeven

@@ -4,7 +4,8 @@
{% set listPrice = price.listPrice %}
<p class="product-detail-price{% if listPrice.percentage > 0 %} with-list-price{% endif %}">
{{ price.unitPrice|currency }}{{ "general.star"|trans|sw_sanitize }}
{{ price.unitPrice|currency }}
{# {{ "general.star"|trans|sw_sanitize }}#}
</p>
{% if listPrice.percentage > 0 %}
@@ -32,4 +33,22 @@
{% endblock %}
{% endblock %}
{% endif %}
{% endblock %}
{% endblock %}
{% block page_product_detail_price_unit %}
<div class="product-detail-price-unit">
{{ block ('page_product_detail_price_unit_label') }}
{{ block ('page_product_detail_price_unit_content') }}
{% if price.referencePrice is not null %}
{% block page_product_detail_price_unit_reference_content %}
<span class="price-unit-reference-content">
({{ price.referencePrice.price|currency }} / {{ price.referencePrice.referenceUnit }} {{ price.referencePrice.unitName }})
{# {{ "general.star"|trans|sw_sanitize }}#}
</span>
{% endblock %}
{% endif %}
</div>
{% endblock %}

+ 12
- 15
zenitPlatformAtmosSet2/src/Resources/app/storefront/dist/storefront/js/zenit-platform-atmos-set2.js Bestand weergeven

@@ -17,7 +17,8 @@ $(document).ready(function() {
dpInput.prop('disabled', true);
dpInput.wrap('<div class="spwn-date-wrapper"></div>');
$("<span id='spwn-remove-date' title='Zurücksetzen'></span>").insertAfter(dpInput);
$("<div id='spwn-delivery'><p></p><div class='spwn-delivery--time'></div></div>").insertAfter(".confirm-delivery-date");
let doNotShow = $(".do-not-show").length ? " class='do-not-show'" : "";
$("<div id='spwn-delivery'" + doNotShow + "><p></p><div class='spwn-delivery--time'></div></div>").insertAfter(".confirm-delivery-date");
fp.config.onChange.push(function() {
manipulateDateInputValue();
});
@@ -37,7 +38,11 @@ $(document).ready(function() {
});

/* Set first selectable day selected */
setDateSelected();

spawnDateInputValue = $(".confirm-delivery-date #dtgs-datepicker-inputfield").val();
if (spawnDateInputValue === '') {
setDateSelected();
}

changeDelivery(fp);
}
@@ -93,24 +98,16 @@ function manipulateDateInputValue() {
function setDateSelected() {
let spwnFirstSelectableDay = $(".flatpickr-day:not(.flatpickr-disabled)").first().text();
let spwnFPdate = new Date();

let spwnDay = spwnFPdate.getDate();
let spwnMonth = spwnFPdate.getMonth();
let spwnMonthTemp = 0;
// month +1 (january == 0)
spwnMonth = spwnMonth + 1;
if((String(spwnMonth)).length === 1) {
spwnMonthTemp = spwnMonth;
spwnMonth = '0' + spwnMonth;
}
if (spwnFirstSelectableDay < spwnDay) {
spwnMonth = spwnMonthTemp + 1;
if((String(spwnMonth)).length === 1) {
spwnMonth = '0' + spwnMonth;
}
// if selectable day in next month add +1 to month
spwnMonth = spwnMonth + 1;
}
let spwnFrmattedDate = spwnFPdate.getFullYear() + '/' + spwnMonth + '/' + spwnFirstSelectableDay;

fp.setDate(new Date(spwnFrmattedDate));
fp.setDate(new Date(spwnFrmattedDate), true);
spawnDateInputValue = spwnFirstSelectableDay + '.' + spwnMonth + '.' + spwnFPdate.getFullYear();
}

@@ -153,8 +150,8 @@ function changeDelivery(fp) {
if (spawnDateInputValue === "" || spawnDateInputValue.indexOf("Uhr") === -1) {
manipulateDateInputValue();
}
// If DPD date is not in Abendzustellung range
} else {
// If DPD date is not in Abendzustellung range
setDateSelected();
}
} else {


+ 9
- 0
zenitPlatformAtmosSet2/src/Resources/app/storefront/src/scss/component/_card.scss Bestand weergeven

@@ -92,11 +92,20 @@
border-radius: 3px;
background: rgba(#86B04B, 0.15);
color: #86B04B;
&.spwn-c-p-more {
background-color: #86b04b;
color: #272527;
}
.icon {
min-width: 22px;
align-self: auto;
color: #86B04B;
}
&.spwn-c-p-more {
.icon {
color: #272527;
}
}
}
.cart-item {
&.is-discountable-item {


+ 1
- 1
zenitPlatformAtmosSet2/src/Resources/app/storefront/src/scss/overrides.scss Bestand weergeven

@@ -167,6 +167,6 @@ input.custom-number[type=number] {
}

.confirm-delivery-date.do-not-show,
#spwn-delivery {
#spwn-delivery.do-not-show {
display: none !important;
}

+ 19
- 1
zenitPlatformAtmosSet2/src/Resources/views/storefront/component/buy-widget/buy-widget-price.html.twig Bestand weergeven

@@ -4,7 +4,8 @@
{% set listPrice = price.listPrice %}
<p class="product-detail-price{% if listPrice.percentage > 0 %} with-list-price{% endif %}">
{{ price.unitPrice|currency }}{{ "general.star"|trans|sw_sanitize }}
{{ price.unitPrice|currency }}
{# {{ "general.star"|trans|sw_sanitize }}#}
</p>
{% set weekProductCount = 0 %}
@@ -43,4 +44,21 @@
{% endblock %}
{% endblock %}
{% endif %}
{% endblock %}
{% block buy_widget_price_unit %}
<div class="product-detail-price-unit">
{{ block ('buy_widget_price_unit_label') }}
{{ block ('buy_widget_price_unit_content') }}
{% if price.referencePrice is not null %}
{% block buy_widget_price_unit_reference_content %}
<span class="price-unit-reference-content">
({{ price.referencePrice.price|currency }} / {{ price.referencePrice.referenceUnit }} {{ price.referencePrice.unitName }})
{# {{ "general.star"|trans|sw_sanitize }}#}
</span>
{% endblock %}
{% endif %}
</div>
{% endblock %}

+ 19
- 1
zenitPlatformAtmosSet2/src/Resources/views/storefront/page/product-detail/buy-widget-price.html.twig Bestand weergeven

@@ -4,7 +4,8 @@
{% set listPrice = price.listPrice %}
<p class="product-detail-price{% if listPrice.percentage > 0 %} with-list-price{% endif %}">
{{ price.unitPrice|currency }}{{ "general.star"|trans|sw_sanitize }}
{{ price.unitPrice|currency }}
{# {{ "general.star"|trans|sw_sanitize }}#}
</p>
{% if listPrice.percentage > 0 %}
@@ -32,4 +33,21 @@
{% endblock %}
{% endblock %}
{% endif %}
{% endblock %}
{% block page_product_detail_price_unit %}
<div class="product-detail-price-unit">
{{ block ('page_product_detail_price_unit_label') }}
{{ block ('page_product_detail_price_unit_content') }}
{% if price.referencePrice is not null %}
{% block page_product_detail_price_unit_reference_content %}
<span class="price-unit-reference-content">
({{ price.referencePrice.price|currency }} / {{ price.referencePrice.referenceUnit }} {{ price.referencePrice.unitName }})
{# {{ "general.star"|trans|sw_sanitize }}#}
</span>
{% endblock %}
{% endif %}
</div>
{% endblock %}

Laden…
Annuleren
Opslaan