Ver código fonte

[Administration] Distributions > calendrier : dates passées dans une couleur différente #1269

feature/souke
Guillaume Bourgeois 1 ano atrás
pai
commit
a7f88403c6
1 arquivos alterados com 14 adições e 2 exclusões
  1. +14
    -2
      backend/web/js/vuejs/distribution-index.js

+ 14
- 2
backend/web/js/vuejs/distribution-index.js Ver arquivo

@@ -212,11 +212,23 @@ var app = new Vue({
}

if (distributions.length) {
var fillMode = 'solid';
var dayToday = app.formatDate(new Date());
for (var i = 0; i < distributions.length; i++) {
if(distributions[i].date < dayToday) {
fillMode = 'outline';
}
else {
fillMode = 'solid';
}

app.calendar.attrs.push({
key: distributions[i].date,
highlight: true,
dates: distributions[i].date
dates: distributions[i].date,
highlight: {
color: 'green',
fillMode: fillMode
}
});

if (distributions[i].date == dateFormatCompare) {

Carregando…
Cancelar
Salvar