Browse Source

[Boutique] Commander : calendrier affiché même si aucune distribution à venir

feature/rotating_product
Guillaume Bourgeois 6 months ago
parent
commit
da3351352f
2 changed files with 7 additions and 13 deletions
  1. +6
    -12
      producer/views/order/order.php
  2. +1
    -1
      producer/web/js/vuejs/order-order.js

+ 6
- 12
producer/views/order/order.php View File

</div> </div>
</div> </div>
<div class="wrapper"> <div class="wrapper">
<div v-if="!loadingInit && distributions.length == 0" class="alert alert-warning">
<div v-if="!loadingInit && !pointSaleActive && distributions.length == 0" class="alert alert-warning">
Aucune distribution à venir chez ce producteur. Aucune distribution à venir chez ce producteur.
</div> </div>
<div v-else> <div v-else>
{{ countProductOrdered() }} produit{{ (countProductOrdered() > 1) ? 's' : '' }} {{ countProductOrdered() }} produit{{ (countProductOrdered() > 1) ? 's' : '' }}
</div> </div>
</li> </li>
<!--<li id="step-payment" :class="'col-md-3 '+((step == 'payment') ? 'active' : '')">
<button @click="changeStep('payment')"
:class="'btn '+ (step == 'payment' ? 'btn-primary' : 'btn-secondary')"
:disabled="step == 'date' || step == 'point-sale' || step == 'products'">
<span class="button-content"><span
class="glyphicon glyphicon-ok"></span> Confirmation</span>
</button>
</li>-->
</ul> </ul>
<div class="clr"></div> <div class="clr"></div>
</div> </div>
</div> </div>
<transition name="slide"> <transition name="slide">
<div id="content-step-date" v-if="step == 'date'"> <div id="content-step-date" v-if="step == 'date'">
<div v-if="!loading">
<div v-if="!loading && pointSaleActive && distributions.length == 0" class="alert alert-warning">
Aucune distribution à venir sur ce point de vente.
</div>
<div v-else-if="!loading">
<?php if ($producer->behavior_order_select_distribution == Producer::BEHAVIOR_ORDER_SELECT_DISTRIBUTION_LIST): ?> <?php if ($producer->behavior_order_select_distribution == Producer::BEHAVIOR_ORDER_SELECT_DISTRIBUTION_LIST): ?>
<div style="display:none ;"> <div style="display:none ;">
<?php endif; ?> <?php endif; ?>
<div id="legend"> <div id="legend">
<div><span id="distribution-date-color"></span> Prochains jours de distribution
</div>
<div><span id="distribution-date-color"></span> Prochains jours de distribution</div>
<div><span id="order-date-color"></span> Vos commandes déjà enregistrées</div> <div><span id="order-date-color"></span> Vos commandes déjà enregistrées</div>
</div> </div>
<div id="calendar"> <div id="calendar">

+ 1
- 1
producer/web/js/vuejs/order-order.js View File

app.calendar.availableDates = []; app.calendar.availableDates = [];


var distributions = response.data.distributions; var distributions = response.data.distributions;
app.distributions = distributions;
if (distributions.length) { if (distributions.length) {
app.distributions = distributions;
var arrayDate; var arrayDate;
var highlightStyle = { var highlightStyle = {
style: { style: {

Loading…
Cancel
Save