diff --git a/include/common/articolo.php b/include/common/articolo.php index bc065dc5e..e0ec67883 100755 --- a/include/common/articolo.php +++ b/include/common/articolo.php @@ -179,9 +179,7 @@ $("#idarticolo").on("change", function() { $("#um").selectSetNew($data.um, $data.um); // Aggiornamento automatico di guadagno e margine - if (direzione === "entrata") { - aggiorna_guadagno(); - } + }); $(document).on("change", "input[name^=qta], input[name^=prezzo_unitario], input[name^=sconto]", function() { @@ -333,4 +331,7 @@ function aggiornaQtaMinima() { div.removeClass("text-danger").addClass("text-success"); } } +if (direzione === "entrata") { + aggiorna_guadagno(); +} '; diff --git a/modules/checklists/modutil.php b/modules/checklists/modutil.php index 6e0763ee2..cf6b9d4ec 100755 --- a/modules/checklists/modutil.php +++ b/modules/checklists/modutil.php @@ -26,9 +26,16 @@ function renderChecklist($check, $level = 0)
  • checked_at) ? 'checked' : '').'> - '.$check->content.' - '.(!empty($check->checked_at) ? 'Verificato da '.$check->checkUser->username.' il '.timestampFormat($check->checked_at) : '').''; + '.$check->content.''; + + if (empty($check->user) || $check->user->id == $user->id) { + $result .= ' +
    + +
    '; + } + if ($level == 0) { $result .= ' @@ -37,13 +44,12 @@ function renderChecklist($check, $level = 0) '; } - if (empty($check->user) || $check->user->id == $user->id) { - $result .= ' -
    - -
    '; - } - + $result .= ' + '.(!empty($check->checked_at) ? tr('Verificato da _NAME_ il _DATE_', [ + '_NAME_' => $check->checkUser->username, + '_DATE_' => timestampFormat($check->checked_at), + ]) : '').''; + $result .= '