From 7d0199934151a74fffed057b9217ada73ede4266 Mon Sep 17 00:00:00 2001 From: MatteoPistorello Date: Thu, 17 Feb 2022 16:13:58 +0100 Subject: [PATCH] Aggiunto link listino articolo in fase di aggiunta riga --- include/common/articolo.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/include/common/articolo.php b/include/common/articolo.php index d3b1ec471..a8de2d124 100755 --- a/include/common/articolo.php +++ b/include/common/articolo.php @@ -141,6 +141,8 @@ $("#idarticolo").on("change", function() { $("#prezzi").html(""); $("#prezzivendita").html(""); $("#prezziacquisto").html(""); + $("#prezzo_unitario").val(""); + $("#sconto").val(""); } if (!$(this).val()) { @@ -186,7 +188,6 @@ $("#idarticolo").on("change", function() { $("#um").selectSetNew($data.um, $data.um); // Aggiornamento automatico di guadagno e margine - }); $("#idsede").on("change", function() { @@ -276,7 +277,10 @@ function verificaPrezzoArticolo() { } div.css("padding-top", "5px"); - div.html(`'.tr('Prezzo suggerito').': ` + prezzo_previsto.toLocale() + " " + globals.currency + ``); + div.html(`'.tr('Prezzo').': ` + prezzo_previsto.toLocale() + " " + globals.currency + " " + `'.Plugins::link(($options['dir'] == 'uscita' ? 'Listino Fornitori' : 'Listino Clienti'), $options['idanagrafica'], null, null, '').'`); + + edit_listino = $("#listino").find("a"); + edit_listino.attr("href", edit_listino.attr("href").replace(/id_record=[0-9]*/, "id_record=" + $("#idarticolo").val())); } /**