Skip to content

Commit

Permalink
fix basket
Browse files Browse the repository at this point in the history
  • Loading branch information
DarkIncognito85 committed Mar 4, 2022
1 parent d0c5474 commit 523e102
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 12 deletions.
26 changes: 15 additions & 11 deletions Theme/Argon/Views/Basket/show.twig
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<div class="row">

{% for row in basket.rows %}
<div class="col-lg-6 col-md-6 col-12" class="row-{{ row.product.id }}">
<div class="col-lg-6 col-md-6 col-12 row-{{ row.product.id }}">
<div class="d-flex">
<div>
<h6 class="text-lg mb-0 mt-2">{{ row.product.name }}</h6>
Expand All @@ -25,33 +25,38 @@
<span class="badge bg-info" id="setupfee-{{ row.product.id }}">{{trans("setupfee") }}
:
{{ row.product.originalSetupfee(row.toRecurring().name) | formatted_price(true, 'none') | trans }}</span>
<p class="text-sm mb-3 mt-3">
<div class="row mt-3">
{% if row.product.data is empty %}
<input type="number" class="form-control quantity" name="quantity" value="{{ row.quantity }}" id="quantity-{{ row.quantity }}" style="width:5rem;" data-id="{{ row.product.id }}" onchange="changeQuantity(this)">
<div class="col-lg-3 col-sm-12">

<input type="number" class="form-control quantity" name="quantity" value="{{ row.quantity }}" id="quantity-{{ row.quantity }}" style="width:5rem;" data-id="{{ row.product.id }}" onchange="changeQuantity(this)">
</div>
{% else %}
{{ row.product.primaryData }}
<p>{{ row.product.primaryData }}</p>
{% endif %}
</p>

{% if row.product.free %}
{{ trans("recurrings.monthly") }}
<p>{{ trans("recurrings.monthly") }}</p>
{% elseif row.product.paymenttype == 'onetime' %}
{{ trans("onetime") }}
<p>{{ trans("onetime") }}</p>
{% else %}

{% if row.isUniqueCycle() %}
{{ trans(row.UniqueCycle.translateKey) }}
<p>{{ trans(row.UniqueCycle.translateKey) }}</p>
{% else %}

<div class="col-lg-9 col-sm-12">
<select class="form-control billing" data-id="{{ row.product.id }}" onchange="changeBilling(this)">
{% for cycle in row.cyclesAvailable %}
{% if row.product.originalPrice(cycle.name, 0, true) != 0 %}
<option value="{{ cycle.name }}" {% if cycle.name == row.billing %} selected {% endif %}>{{ trans(cycle.translateKey) }}</option>
<option value="{{ cycle.name }}" {% if cycle.name == row.billing %} selected {% endif %}>{{ trans(cycle.translateKey) }} {{ row.product.getDiscountForRecurring(cycle, row.UniqueCycle)!= 0 ? row.product.getDiscountForRecurring(cycle, row.UniqueCycle) ~ "% Saved" }}</option>
{% endif %}
{% endfor %}
</select>
</div>
{% endif %}
{% endif %}
</div>


</div>
</div>
Expand All @@ -69,7 +74,6 @@
<i class="fas fa-trash"></i>
</button>
</div>
</div>
{% endfor %}

<div class="col-lg-9 col-md-6 col-12"></div>
Expand Down
2 changes: 1 addition & 1 deletion Theme/Argon/layout.twig
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{% set mail_messages = mail_messages() %}

{% include "includes/head.twig" with {title: block('title') | html_decode} %}
<body class="argon g-sidenav-show">
<body class="argon g-sidenav-show boostrapv5">
{% include "includes/header.twig" with {title: block('title') | html_decode} %}

<div class="container-fluid py-4">
Expand Down

0 comments on commit 523e102

Please sign in to comment.