fixed alert issue

This commit is contained in:
Lasha Kapanadze 2025-09-10 20:54:31 +04:00
parent ac09d8d0eb
commit 586226ceaf
2 changed files with 5 additions and 2 deletions

View File

@ -73,7 +73,9 @@ try {
"IdCommessa" => $commessaId,
"CodiceCommessa" => "TEST001",
"IdCliente" => $clienteId,
"Fields" => $fieldValues
"IdSchema" => $schemaId,
"Fields" => $fieldValues,
"Inviato" => 1
];
} else {
// 🔹 REAL API FLOW
@ -82,6 +84,7 @@ try {
// 1. Create CommessaWeb
$commessaPayload = [
"IdCliente" => $clienteId,
"IdSchema" => $schemaId,
"IdSchemaCustomFields" => $schemaId,
"Inviato" => 1
];

View File

@ -724,7 +724,7 @@ foreach ($stmt->fetchAll(PDO::FETCH_ASSOC) as $row) {
},
success: function (response) {
if (response.success) {
alert("✅ CommessaWeb created. ID: " + response.comessa);
alert("✅ CommessaWeb created. ID: " + response.commessa.IdCommessa);
} else {
alert("❌ Error: " + response.message);
}