Implemetanto metodo Upload_logo per caricamento loghi azienda
This commit is contained in:
parent
00c31ceee3
commit
d3cc5b8526
@ -14106,18 +14106,13 @@ namespace ApiPolo.Controllers
|
||||
try
|
||||
{
|
||||
// Percorso base su Linux (già presente nella macchina server)
|
||||
string basePath = "/zucchetti/api/api-vt.poloinformatico.it/app/wwwroot/VIRTU";
|
||||
string basePath = _configuration["Percorsi:PathLogo"];
|
||||
|
||||
// Cartella azienda, es. "AZI02"
|
||||
string aziendaFolder = ten2.Trim();
|
||||
|
||||
// Costruisco il percorso completo in modo portabile
|
||||
string folderPath = Path.Combine(basePath, aziendaFolder);
|
||||
|
||||
//// Creo la cartella se non esiste
|
||||
//if (!Directory.Exists(folderPath))
|
||||
// Directory.CreateDirectory(folderPath);
|
||||
|
||||
// Percorso finale del file
|
||||
string fullPath = Path.Combine(folderPath, file.FileName);
|
||||
|
||||
@ -14136,7 +14131,6 @@ namespace ApiPolo.Controllers
|
||||
message = "Logo caricato con successo",
|
||||
url = fileUrl,
|
||||
fileName = file.FileName,
|
||||
savedPath = fullPath // 👈 aggiunto per debug
|
||||
});
|
||||
}
|
||||
catch (Exception ex)
|
||||
|
||||
@ -25,7 +25,7 @@
|
||||
"Secret": "ByYM000OLlMQG6VVVp1OH7Xzyr7gHuw1qvUC5dcGt3SNM"
|
||||
},
|
||||
"Percorsi": {
|
||||
"PathLogo": "/zucchetti/api/api-vt.poloinformatico.it/app/wwwroot/VIRTU",
|
||||
"PathLogo": "./wwwroot/VIRTU",
|
||||
"PublicBaseUrl": "https://api-vt.poloinformatico.it/VIRTU/"
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user