Compare commits
3 Commits
69b0c8281f
...
50184e54d0
| Author | SHA1 | Date | |
|---|---|---|---|
| 50184e54d0 | |||
| 96b944370e | |||
| dafaa9574e |
127
src/App.vue
127
src/App.vue
@ -1,14 +1,16 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<button class="pdf-button" @click="exportPdf">Esporta PDF</button>
|
<button class="pdf-button" @click="exportPdf(intestazione.nomefile ? `${intestazione.nomefile}.pdf` : 'certificato-prova.pdf')">Esporta PDF</button>
|
||||||
<div class="report" ref="printable" contenteditable="true">
|
<div class="report" ref="printable" contenteditable="true">
|
||||||
<header>
|
<header>
|
||||||
<img src="/report_header.png" alt="Intestazione Unilab" class="report-header-image" />
|
<img src="/report_header.png" alt="Intestazione Unilab" class="report-header-image" />
|
||||||
</header>
|
</header>
|
||||||
|
|
||||||
<h3 class="section-title">{{ intestazione.intest1 }}</h3>
|
<div class="header-row">
|
||||||
|
<h5 class="section-title">{{ intestazione.intest1 }}</h5>
|
||||||
<div>{{intestazione.modreport}}</div>
|
<div class="modreport">{{ intestazione.modreport }}</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<h3 class="section-title">{{ intestazione.intest2 }}</h3>
|
<h3 class="section-title">{{ intestazione.intest2 }}</h3>
|
||||||
|
|
||||||
@ -68,9 +70,16 @@
|
|||||||
|
|
||||||
|
|
||||||
<footer>
|
<footer>
|
||||||
|
<div class="notepp">{{ intestazione.notapp }}</div>
|
||||||
<div class="signatures">
|
<div class="signatures">
|
||||||
<p>Lo sperimentatore<br>Dott. Ing. Giacomo Calussi</p>
|
<div class="signblock">
|
||||||
<p>Il Direttore del Laboratorio<br>Dott. Ing. Paolo Neri</p>
|
<span class="sign1">Lo sperimentatore</span><br>
|
||||||
|
<span class="sign2">Dott. Ing. Giacomo Calussi</span>
|
||||||
|
</div>
|
||||||
|
<div class="signblock">
|
||||||
|
<span class="sign1">Il Direttore del Laboratorio</span><br>
|
||||||
|
<span class="sign2">Dott. Ing. Paolo Neri</span>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</footer>
|
</footer>
|
||||||
</div>
|
</div>
|
||||||
@ -82,11 +91,14 @@ import { ref, onMounted, watch } from 'vue'
|
|||||||
import html2pdf from 'html2pdf.js'
|
import html2pdf from 'html2pdf.js'
|
||||||
import A_CUB from './components/risultati/A_CUB.vue'
|
import A_CUB from './components/risultati/A_CUB.vue'
|
||||||
import A_CIL from './components/risultati/A_CIL.vue'
|
import A_CIL from './components/risultati/A_CIL.vue'
|
||||||
|
import B_BAR from './components/risultati/B_BAR.vue'
|
||||||
|
import B_RET from './components/risultati/B_RET.vue'
|
||||||
|
|
||||||
const componentMap = {
|
const componentMap = {
|
||||||
'A_CUB': A_CUB,
|
'A_CUB': A_CUB,
|
||||||
'A_CIL': A_CIL,
|
'A_CIL': A_CIL,
|
||||||
'B_BAR':B_BAR
|
'B_BAR':B_BAR,
|
||||||
|
'B_RET':B_RET
|
||||||
}
|
}
|
||||||
|
|
||||||
const printable = ref(null)
|
const printable = ref(null)
|
||||||
@ -121,7 +133,7 @@ onMounted(async () => {
|
|||||||
const data = await fetchReportDataWithToken(token, pSERCER);
|
const data = await fetchReportDataWithToken(token, pSERCER);
|
||||||
|
|
||||||
intestazione.value = data.intestazione
|
intestazione.value = data.intestazione
|
||||||
datiacc_info.value = capitalizeAllFields(data.datiacc_info)
|
datiacc_info.value = data.datiacc_info
|
||||||
datiacc_data.value = data.datiacc_data
|
datiacc_data.value = data.datiacc_data
|
||||||
risult_data.value = calcolaMediaRcPerGruppo(data.risult_data)
|
risult_data.value = calcolaMediaRcPerGruppo(data.risult_data)
|
||||||
note.value = data.note ?? []
|
note.value = data.note ?? []
|
||||||
@ -191,11 +203,11 @@ function capitalizeEachWord(str) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
function exportPdf() {
|
function exportPdf(filename = 'certificato-prova.pdf') {
|
||||||
html2pdf()
|
html2pdf()
|
||||||
.from(printable.value)
|
.from(printable.value)
|
||||||
.set({
|
.set({
|
||||||
filename: `certificato-prova.pdf`,
|
filename,
|
||||||
html2canvas: { scale: 2 },
|
html2canvas: { scale: 2 },
|
||||||
jsPDF: {
|
jsPDF: {
|
||||||
unit: 'mm',
|
unit: 'mm',
|
||||||
@ -257,16 +269,37 @@ body {
|
|||||||
padding: 2px;
|
padding: 2px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.header-row {
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
align-items: center;
|
||||||
|
margin-bottom: 8px; /* opzionale, spazio sotto la riga */
|
||||||
|
}
|
||||||
|
|
||||||
|
.header-row .section-title {
|
||||||
|
margin: 0;
|
||||||
|
text-align: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
.modreport {
|
||||||
|
font-weight: normal;
|
||||||
|
text-align: right;
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
.report-header-image {
|
.report-header-image {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: auto;
|
height: auto;
|
||||||
margin-bottom: 10px;
|
margin-bottom: 8px;
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
|
|
||||||
.report {
|
.report {
|
||||||
width: 100%;
|
/* Assicuriamoci che .report abbia altezza A4 e posizionamento relativo */
|
||||||
|
position: relative;
|
||||||
max-width: 210mm;
|
max-width: 210mm;
|
||||||
|
min-height: 289mm;
|
||||||
padding: 4mm;
|
padding: 4mm;
|
||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
background: white;
|
background: white;
|
||||||
@ -275,7 +308,7 @@ body {
|
|||||||
|
|
||||||
|
|
||||||
header {
|
header {
|
||||||
margin-bottom: 8px;
|
margin-bottom: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.center {
|
.center {
|
||||||
@ -285,14 +318,15 @@ header {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.section-title {
|
.section-title {
|
||||||
padding: 6px;
|
padding: 4px;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
margin-top: 10px;
|
margin-top: 16px;
|
||||||
|
margin-bottom: 2px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.sub-header {
|
.sub-header {
|
||||||
padding: 6px;
|
padding: 4px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -305,7 +339,7 @@ table {
|
|||||||
th,
|
th,
|
||||||
td {
|
td {
|
||||||
border: 1px solid #000;
|
border: 1px solid #000;
|
||||||
padding: 2px;
|
padding: 1px;
|
||||||
font-size: 0.85em;
|
font-size: 0.85em;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
@ -313,8 +347,7 @@ td {
|
|||||||
.info-table {
|
.info-table {
|
||||||
width: 80%;
|
width: 80%;
|
||||||
border: 2px solid black;
|
border: 2px solid black;
|
||||||
margin-left: auto;
|
margin: 0 auto;
|
||||||
margin-right: auto;
|
|
||||||
border-collapse: collapse;
|
border-collapse: collapse;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -333,7 +366,7 @@ td {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.note-section {
|
.note-section {
|
||||||
margin-top: 10px;
|
margin-top: 2px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.note-table {
|
.note-table {
|
||||||
@ -348,13 +381,6 @@ td {
|
|||||||
text-align: left;
|
text-align: left;
|
||||||
}
|
}
|
||||||
|
|
||||||
.signatures {
|
|
||||||
display: flex;
|
|
||||||
justify-content: space-between;
|
|
||||||
margin-top: 40px;
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
.pdf-button {
|
.pdf-button {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
top: 20px;
|
top: 20px;
|
||||||
@ -371,4 +397,51 @@ td {
|
|||||||
.pdf-button:hover {
|
.pdf-button:hover {
|
||||||
background-color: #0056b3;
|
background-color: #0056b3;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
footer {
|
||||||
|
/* Posizione assoluta in fondo al contenitore .report */
|
||||||
|
position: absolute;
|
||||||
|
bottom: 4mm; /* distanza dal bordo inferiore */
|
||||||
|
left: 4mm; /* stesso padding orizzontale di .report */
|
||||||
|
right: 4mm;
|
||||||
|
}
|
||||||
|
|
||||||
|
footer .signatures {
|
||||||
|
/* Manteniamo le firme in orizzontale ma riduciamo margine sopra se serve */
|
||||||
|
margin-top: 0;
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
text-align: center;
|
||||||
|
padding-left: 80px;
|
||||||
|
padding-right: 80px;
|
||||||
|
border-top: 1px solid #000;
|
||||||
|
}
|
||||||
|
|
||||||
|
footer .sign1{
|
||||||
|
font-size: 0.75em;
|
||||||
|
}
|
||||||
|
|
||||||
|
footer .sign2{
|
||||||
|
font-size: 0.65em;
|
||||||
|
}
|
||||||
|
|
||||||
|
footer .signblock{
|
||||||
|
border-bottom: 1px solid #000;
|
||||||
|
padding-bottom: 12mm;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Stilizzo il div di notepp (assumo classe .modreport o ne crei una nuova) */
|
||||||
|
.modreport {
|
||||||
|
font-size: 0.7em; /* carattere piccolo */
|
||||||
|
margin: 0; /* rimuovo margini inutili */
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Se la sezione delle notepp ha una sua classe, ad esempio .notepp: */
|
||||||
|
.notepp {
|
||||||
|
font-size: 0.7em;
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@ -5,7 +5,7 @@
|
|||||||
<tr>
|
<tr>
|
||||||
<th>ID<br>Provino</th>
|
<th>ID<br>Provino</th>
|
||||||
<th>Contrassegno</th>
|
<th>Contrassegno</th>
|
||||||
<th>Verbale<br>di prelievo n.</th>
|
<th>Verbale di<br>prelievo n.</th>
|
||||||
<th>Data<br>prelievo</th>
|
<th>Data<br>prelievo</th>
|
||||||
<th>R<sub>CK</sub></th>
|
<th>R<sub>CK</sub></th>
|
||||||
<th>Area o elemento strutturale</th>
|
<th>Area o elemento strutturale</th>
|
||||||
|
|||||||
@ -3,12 +3,22 @@
|
|||||||
<table>
|
<table>
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>ID<br>Provino</th>
|
<th rowspan="2">ID<br>Provino</th>
|
||||||
<th>Contrassegno</th>
|
<th rowspan="2">Contrass.</th>
|
||||||
<th>Verbale<br>di prelievo n.</th>
|
<th rowspan="2">Verbale<br>di prelievo n.</th>
|
||||||
<th>Data<br>prelievo</th>
|
<th rowspan="2">Data<br>prelievo</th>
|
||||||
<th>R<sub>CK</sub></th>
|
<th>Diametro<br>Nominale</th>
|
||||||
<th>Area o elemento strutturale</th>
|
<th>Lungh.</th>
|
||||||
|
<th>Massa</th>
|
||||||
|
<th>Diametro<br>Effettivo</th>
|
||||||
|
<th rowspan="2">Marchio</th>
|
||||||
|
<th rowspan="2">Struttura di<br>riferimento</th>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<th>[mm]</th>
|
||||||
|
<th>[mm]</th>
|
||||||
|
<th>[g]</th>
|
||||||
|
<th>[mm]</th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
@ -17,7 +27,11 @@
|
|||||||
<td>{{ row.contrassegno }}</td>
|
<td>{{ row.contrassegno }}</td>
|
||||||
<td>{{ row.verbale }}</td>
|
<td>{{ row.verbale }}</td>
|
||||||
<td>{{ formatDate(row.dataPrelievo) }}</td>
|
<td>{{ formatDate(row.dataPrelievo) }}</td>
|
||||||
<td>{{ formatNumber(row.rck, 0) }}</td>
|
<td>{{ formatNumber(row.diaNom,0) }}</td>
|
||||||
|
<td>{{ formatNumber(row.dimA,0) }}</td>
|
||||||
|
<td>{{ formatNumber(row.masG,1) }}</td>
|
||||||
|
<td>{{ formatNumber(row.diaEff,2) }}</td>
|
||||||
|
<td>{{ row.ferriera }}</td>
|
||||||
<td v-if="row.rowspanArea > 0" :rowspan="row.rowspanArea">{{ row.area }}</td>
|
<td v-if="row.rowspanArea > 0" :rowspan="row.rowspanArea">{{ row.area }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</tbody>
|
</tbody>
|
||||||
@ -30,45 +44,30 @@
|
|||||||
<table>
|
<table>
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th colspan="5">DATI PRELIMINARI ALLA PROVA</th>
|
<th>ID<br>Provino</th>
|
||||||
<th colspan="5">RESISTENZA ALLA COMPRESSIONE</th>
|
<th>Carico di<br>snevamento<br>F<sub>y</sub><br>[kN]</th>
|
||||||
</tr>
|
<th>Tensione di<br>snevamento<br>f<sub>y</sub><br>[N/mm²]</th>
|
||||||
<tr>
|
<th>Carico di<br>rottura<br>F<sub>t</sub><br>[kN]</th>
|
||||||
<th rowspan="3">ID<br>Provino</th>
|
<th>Tensione di<br>rottura<br>f<sub>t</sub><br>[N/mm²]</th>
|
||||||
<th rowspan="3">Data<br>prova</th>
|
<th>Allungamento<br>a rottura<br>A<sub>gt</sub><br>[%]</th>
|
||||||
<th colspan="2">Dimensioni</th>
|
<th>f<sub>t</sub>/f<sub>y</sub></th>
|
||||||
<th rowspan="2">Massa<br>volumica</th>
|
<th>f<sub>t</sub>/f<sub>ynom</sub></th>
|
||||||
<th rowspan="2">F</th>
|
<th>Mandrino<br><br>D<br>[mm]</th>
|
||||||
<th rowspan="2">R<sub>c</sub></th>
|
<th>Esito<br>Piega*</th>
|
||||||
<th rowspan="2">R<sub>PRELIEVO</sub></th>
|
|
||||||
<th rowspan="3">R**</th>
|
|
||||||
<th rowspan="3">P***</th>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<th>D</th>
|
|
||||||
<th>h</th>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<th>[mm]</th>
|
|
||||||
<th>[mm]</th>
|
|
||||||
<th>[kg/m³]</th>
|
|
||||||
<th>[kN]</th>
|
|
||||||
<th>[N/mm²]</th>
|
|
||||||
<th>[N/mm²]</th>
|
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr v-for="row in risult_data" :key="row.idProvino">
|
<tr v-for="row in risult_data" :key="row.idProvino">
|
||||||
<td>{{ row.idProvino }}</td>
|
<td>{{ row.idProvino }}</td>
|
||||||
<td>{{ formatDate(row.dataProva) }}</td>
|
<td>{{ formatNumber(row.carsne,2) }}</td>
|
||||||
<td>{{ formatNumber(row.dimA, 2) }}</td>
|
<td>{{ formatNumber(row.tensne,1) }}</td>
|
||||||
<td>{{ formatNumber(row.dimH, 2) }}</td>
|
<td>{{ formatNumber(row.carot,2) }}</td>
|
||||||
<td>{{ formatNumber(row.massaVolumica, 0) }}</td>
|
<td>{{ formatNumber(row.tenrot,1) }}</td>
|
||||||
<td>{{ formatNumber(row.f, 1) }}</td>
|
<td>{{ formatNumber(row.agt,1) }}</td>
|
||||||
<td>{{ formatNumber(row.rc, 2) }}</td>
|
<td>{{ formatNumber(row.ftFy,2) }}</td>
|
||||||
<td v-if="row.rowspanRprelievo > 0" :rowspan="row.rowspanRprelievo">{{ row.rprelievo }}</td>
|
<td>{{ formatNumber(row.ftFyNom,2) }}</td>
|
||||||
<td>{{ row.rType }}</td>
|
<td>{{ formatNumber(row.mandrino,0) }}</td>
|
||||||
<td>{{ row.pType }}</td>
|
<td>{{ row.esipie }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
@ -94,5 +93,4 @@
|
|||||||
: '—'
|
: '—'
|
||||||
}
|
}
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
99
src/components/risultati/B_RET.vue
Normal file
99
src/components/risultati/B_RET.vue
Normal file
@ -0,0 +1,99 @@
|
|||||||
|
<template>
|
||||||
|
<h3 class="section-title">DATI PRELIMINARI DI PROVA</h3>
|
||||||
|
<table>
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th rowspan="2">ID<br>Provino</th>
|
||||||
|
<th rowspan="2">Contrass.</th>
|
||||||
|
<th rowspan="2">Verbale<br>di prelievo n.</th>
|
||||||
|
<th rowspan="2">Data<br>prelievo</th>
|
||||||
|
<th>Diametro<br>Nominale</th>
|
||||||
|
<th>Lungh.</th>
|
||||||
|
<th>Massa</th>
|
||||||
|
<th>Diametro<br>Effettivo</th>
|
||||||
|
<th rowspan="2">Marchio</th>
|
||||||
|
<th rowspan="2">Struttura di<br>riferimento</th>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<th>[mm]</th>
|
||||||
|
<th>[mm]</th>
|
||||||
|
<th>[g]</th>
|
||||||
|
<th>[mm]</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
<tr v-for="(row, index) in datiacc_data" :key="row.idProvino">
|
||||||
|
<td>{{ row.idProvino }}</td>
|
||||||
|
<td>{{ row.contrassegno }}</td>
|
||||||
|
<td>{{ row.verbale }}</td>
|
||||||
|
<td>{{ formatDate(row.dataPrelievo) }}</td>
|
||||||
|
<td>{{ formatNumber(row.diaNom,0) }}</td>
|
||||||
|
<td>{{ formatNumber(row.dimA,0) }}</td>
|
||||||
|
<td>{{ formatNumber(row.masG,1) }}</td>
|
||||||
|
<td>{{ formatNumber(row.diaEff,2) }}</td>
|
||||||
|
<td>{{ row.ferriera }}</td>
|
||||||
|
<td v-if="row.rowspanArea > 0" :rowspan="row.rowspanArea">{{ row.area }}</td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
|
||||||
|
<!-- RISULTATI -->
|
||||||
|
|
||||||
|
<div class="section-title">{{ intestazione.prova1 }}</div>
|
||||||
|
<div class="sub-header">{{ intestazione.prova2 }}</div>
|
||||||
|
<table>
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th rowspan="2">ID<br>Provino</th>
|
||||||
|
<th rowspan="2">Carico di<br>snevamento<br>F<sub>y</sub><br>[kN]</th>
|
||||||
|
<th rowspan="2">Tensione di<br>snevamento<br>f<sub>y</sub><br>[N/mm²]</th>
|
||||||
|
<th rowspan="2">Carico di<br>rottura<br>F<sub>t</sub><br>[kN]</th>
|
||||||
|
<th rowspan="2">Tensione di<br>rottura<br>f<sub>t</sub><br>[N/mm²]</th>
|
||||||
|
<th rowspan="2">Allungamento<br>a rottura<br>A<sub>gt</sub><br>[%]</th>
|
||||||
|
<th rowspan="2">f<sub>t</sub>/f<sub>y</sub></th>
|
||||||
|
<th rowspan="2">f<sub>t</sub>/f<sub>ynom</sub></th>
|
||||||
|
<th colspan="2">Carico di rottura<br>nodo saldato</th>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<th>[kN]</th>
|
||||||
|
<th>Tipo*</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
<tr v-for="row in risult_data" :key="row.idProvino">
|
||||||
|
<td>{{ row.idProvino }}</td>
|
||||||
|
<td>{{ formatNumber(row.carsne,2) }}</td>
|
||||||
|
<td>{{ formatNumber(row.tensne,1) }}</td>
|
||||||
|
<td>{{ formatNumber(row.carot,2) }}</td>
|
||||||
|
<td>{{ formatNumber(row.tenrot,1) }}</td>
|
||||||
|
<td>{{ formatNumber(row.agt,1) }}</td>
|
||||||
|
<td>{{ formatNumber(row.ftFy,2) }}</td>
|
||||||
|
<td>{{ formatNumber(row.ftFyNom,2) }}</td>
|
||||||
|
<td>{{ formatNumber(row.disnod,2) }}</td>
|
||||||
|
<td>{{ row.tipdis }}</td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup>
|
||||||
|
defineProps({
|
||||||
|
risult_data: Array,
|
||||||
|
datiacc_data: Array,
|
||||||
|
intestazione: Object
|
||||||
|
})
|
||||||
|
|
||||||
|
function formatDate(dateStr) {
|
||||||
|
return new Date(dateStr).toLocaleDateString('it-IT')
|
||||||
|
}
|
||||||
|
|
||||||
|
function formatNumber(val, decimals) {
|
||||||
|
return val != null
|
||||||
|
? Number(val).toLocaleString('it-IT', {
|
||||||
|
minimumFractionDigits: decimals,
|
||||||
|
maximumFractionDigits: decimals
|
||||||
|
})
|
||||||
|
: '—'
|
||||||
|
}
|
||||||
|
|
||||||
|
</script>
|
||||||
Loading…
Reference in New Issue
Block a user