Patch level : 12.0 902

Files correlati     : tp0.exe
Commento           to :

Gestione conai
This commit is contained in:
Alessandro Bonazzi 2019-11-25 22:13:25 +01:00
parent 7c845b7ad4
commit af91e542a1
2 changed files with 16 additions and 1 deletions

View File

@ -469,7 +469,8 @@ void TTrasferimentoPack_mask::trasferisci()
if (go_on && get_bool(F_BOLLE))
{
TPack_ddt pc;
pc.activate_custref(get_bool(F_CUSTREF));
pc.activate_custref(get_bool(F_CUSTREF));
pc.activate_paper_info(get_bool(F_PAPER));
pc.activate_paper_size(get_bool(F_SIZE));
pc.activate_customer_code(get_bool(F_CUSTCODE));

View File

@ -829,6 +829,10 @@ bool TPack_ddt::trasferisci()
const TString4 conai_subclass = get_str("SubclassCode");
const TCONAI_class ct = conai_str2class(conai_subclass);
if (cache().get("&VECSS", conai_subclass).empty())
log_error(format(TR("Bolla %ld - Articolo %s - Sottocategoria %s assente"),
ndoc, (const char *) (rowtype == "01" ? codart : custcode),
(const char *) conai_subclass));
if (conai_scheme == 1)
{
// La sottocategoria della bolla prevale su quella anagrafica
@ -846,6 +850,11 @@ bool TPack_ddt::trasferisci()
{
const TString& cs = art.conai_subclass(i - 1); // Codice sottocategoria su ANAMAG
if (cache().get("&VECSS", cs).empty())
log_error(format(TR("Bolla %ld - Articolo %s - Sottocategoria %s assente"),
ndoc, (const char *)(rowtype == "01" ? codart : custcode),
(const char *)cs));
if (cs.full()) // la presenza della sottoclasse implica anche un peso positivo
{
const real& weight = art.conai_weight(i - 1); // Peso imballo su ANAMAG
@ -870,6 +879,11 @@ bool TPack_ddt::trasferisci()
{
const real& weight = art.conai_weight(i - 1); // Peso imballo su ANAMAG
if (cache().get("&VECSS", cs).empty())
log_error(format(TR("Bolla %ld - Articolo %s - Sottocategoria %s assente"),
ndoc, (const char *)(rowtype == "01" ? codart : custcode),
(const char *)cs));
rdoc.put(conai_sottocat_name(i + 1), cs);
rdoc.put(conai_peso_name(i + 1), weight); // ex QTAGG1
rdoc.put(conai_esenzione_name(conai_str2class(cs.left(2)), LF_RIGHEDOC),