Merged PR 164: update export

update export
This commit is contained in:
Mariapia Lorusso
2025-06-12 07:51:36 +00:00
committed by Ferrelli, Emanuele
2 changed files with 4 additions and 4 deletions

View File

@@ -488,14 +488,14 @@ const exportExecutions = () => {
// Crea il CSV manualmente // Crea il CSV manualmente
const headers = Object.keys(dataForExport[0]); const headers = Object.keys(dataForExport[0]);
const csvContent = [headers.join(','), ...dataForExport.map((row) => headers.map((header) => `"${row[header]}"`).join(','))].join('\n'); const csvContent = [headers.join(';'), ...dataForExport.map((row) => headers.map((header) => `"${row[header]}"`).join(';'))].join('\n');
// Download del file // Download del file
const blob = new Blob([csvContent], { type: 'text/csv;charset=utf-8;' }); const blob = new Blob([csvContent], { type: 'text/csv;charset=utf-8;' });
const link = document.createElement('a'); const link = document.createElement('a');
const url = URL.createObjectURL(blob); const url = URL.createObjectURL(blob);
link.setAttribute('href', url); link.setAttribute('href', url);
link.setAttribute('download', `executions_${moment().format('YYYY-MM-DD')}.csv`); link.setAttribute('download', `Executions_${moment().format('YYYY-MM-DD_mm-ss')}.csv`);
link.style.visibility = 'hidden'; link.style.visibility = 'hidden';
document.body.appendChild(link); document.body.appendChild(link);
link.click(); link.click();

View File

@@ -92,7 +92,7 @@ import { UserPrefStore } from '../../stores/UserPrefStore.js';
const scenarioTypeOp = ref([ const scenarioTypeOp = ref([
{ name: 'All', value: 'all' }, { name: 'All', value: 'all' },
{ name: 'Cross', value: 'cross' }, //{ name: 'Cross', value: 'cross' },
{ name: 'Project', value: 'project' }, { name: 'Project', value: 'project' },
{ name: 'Application', value: 'application' } { name: 'Application', value: 'application' }
@@ -103,7 +103,7 @@ const scenarioTypeOp = ref([
scenario_store.setFilterString(''); scenario_store.setFilterString('');
userPrefStore.fetchUserData().then(() => { userPrefStore.fetchUserData().then(() => {
scenario_store.fetchScenariosCross(); //scenario_store.fetchScenariosCross();
scenario_store.fetchScenarios(); scenario_store.fetchScenarios();
if(userPrefStore.getSelApp != null){ if(userPrefStore.getSelApp != null){
scenario_store.fetchApplicationScenarios(); scenario_store.fetchApplicationScenarios();