Compare commits

...

2 Commits

Author SHA1 Message Date
valentina 5c86d3b748 Fix ricerca globale 2024-08-22 10:19:35 +02:00
valentina 1fac42854f Fix riferimento normativo in fattura 2024-08-22 09:26:08 +02:00
5 changed files with 14 additions and 14 deletions

View File

@ -50,14 +50,14 @@ $(document).ready(function () {
data = data ? data : [];
// Trasformazione risultati in formato leggibile
const results = data.map(function (result) {
return {
label: result.badge ? result.badge : '<h4>' + result.title + '</h4>' + result.badges
.join('').split('<br/>,').join('<br/>'),
group: result.category,
link: result.link,
value: result.title
}
const results = data.map(result => {
const title = result.title;
const labels = result.labels.join('').split('<br/>,').join('<br/>');
const label = result.label ? result.label : `<h5>${title}</h5><small>${labels}</small>`;
const group = result.category;
const link = result.link;
const value = result.title;
return { label, group, link, value };
});
// Rimozione ricerca in corso
@ -87,8 +87,8 @@ $(document).ready(function () {
},
render: function(item, currentValue){
const itemElement = document.createElement("div");
itemElement.innerHTML = item.badge;
// <a href='" + item.link + "' title='Clicca per aprire'><b>" + item.value + "</b><br/>" + item.badge + "</a>
itemElement.innerHTML = item.label;
// <a href='" + item.link + "' title='Clicca per aprire'><b>" + item.value + "</b><br/>" + item.label + "</a>
return itemElement;
}
});

View File

@ -322,7 +322,7 @@ function impostaCategorieAllegatiDisponibili(gestione, categorie) {
update(results);
},
onSelect: function (item) {
input.value = item.badge;
input.value = item.label;
},
});
}

View File

@ -90,7 +90,7 @@ $(document).ready(function () {
update(results);
},
onSelect: function (item) {
input.value = item.badge;
input.value = item.label;
},
});
});

View File

@ -862,7 +862,7 @@ if (empty($record['deleted_at'])) {
update(results);
},
onSelect: function (item) {
input.value = item.badge;
input.value = item.label;
},
});
}

View File

@ -1606,7 +1606,7 @@ class FatturaElettronica implements \Stringable
'ImponibileImporto' => $totale,
'Imposta' => $imposta,
'EsigibilitaIVA' => $dati->esigibilita,
'RiferimentoNormativo' => $dati->descrizione,
'RiferimentoNormativo' => $dati->getTranslation('title'),
];
// Con split payment EsigibilitaIVA sempre a S