Fix righe ordini con quantità a 0
This commit is contained in:
parent
1f4fca3c6e
commit
967c6a28d6
|
@ -213,6 +213,7 @@ foreach ($righe as $riga) {
|
|||
$evasione_bar['in_righe_interventi'] = 'warning';
|
||||
$evasione_bar['or_righe_ordini'] = 'success';
|
||||
foreach ($evasione_bar as $table => $color) {
|
||||
if ($righe_ev->count() > 0) {
|
||||
$righe_ev = $dbo->table($table)->where('original_id', $riga->id)->where('original_type', get_class($riga))->get();
|
||||
$perc_ev = $righe_ev->sum('qta') * 100 / $riga->qta;
|
||||
if ($perc_ev > 0) {
|
||||
|
@ -220,6 +221,7 @@ foreach ($righe as $riga) {
|
|||
<div class="progress-bar progress-bar-'.$color.'" style="width:'.$perc_ev.'%"></div>';
|
||||
}
|
||||
}
|
||||
}
|
||||
echo '
|
||||
</div>
|
||||
</td>';
|
||||
|
|
Loading…
Reference in New Issue