1
0
mirror of https://github.com/devcode-it/openstamanager.git synced 2025-01-24 21:01:27 +01:00

Bugfix check su FE

This commit is contained in:
Thomas Zilio 2019-09-23 10:48:38 +02:00
parent 066e11cb2b
commit 9bfdf3ee41

View File

@ -370,7 +370,7 @@ class FatturaElettronica
$errors = []; $errors = [];
// Controlli sulla fattura stessa // Controlli sulla fattura stessa
if ($fattura->stato->descrizione != 'Emessa') { if ($fattura->stato->descrizione == 'Bozza') {
$missing = [ $missing = [
'state' => tr('Stato ("Emessa")'), 'state' => tr('Stato ("Emessa")'),
]; ];
@ -451,7 +451,7 @@ class FatturaElettronica
$missing = []; $missing = [];
if (!empty($data)) { if (!empty($data)) {
foreach ($fields as $key => $name) { foreach ($fields as $key => $name) {
if (empty($data[$key])) { if (empty($data[$key]) && !empty($name)) {
$missing[] = $name; $missing[] = $name;
} }
} }
@ -493,7 +493,7 @@ class FatturaElettronica
$missing = []; $missing = [];
if (!empty($data)) { if (!empty($data)) {
foreach ($fields as $key => $name) { foreach ($fields as $key => $name) {
if (empty($data[$key])) { if (empty($data[$key]) && !empty($name)) {
$missing[] = $name; $missing[] = $name;
} }
} }