git-svn-id: svn://10.65.10.50/branches/R_10_00@22954 c028cbd2-c16b-5b4b-a496-9718f37d4682

This commit is contained in:
guy 2014-06-24 12:38:27 +00:00
parent ea3143334d
commit cb17b9335f

View File

@ -860,45 +860,20 @@ bool TExplode_distinta_form::validate(TForm_item &f, TToken_string &t)
else
if (code == "_DES")
{
TToken_string fa(re.path(), '~');
TToken_string key(fa.get(0));
TToken_string tmp("", '~');
TString code;
TToken_string & p = (TToken_string &) re.path();
p.get(-2, (TString &)tmp);
tmp.get(2, code);
key.add(code);
valore = cache().get(LF_RDIST, key, RDIST_DESCR);
if (valore.full())
{
f.set(valore);
return true;
}
switch (tipo)
{
case 'A':
{
valore = cache().get(LF_ANAMAG, re.articolo(), ANAMAG_DESCR);
break;
}
case 'L':
case 'L':
{
const TLavorazione lav(re.articolo());
valore = lav.descr();
break;
}
case 'V':
{
const TRectype & dist = cache().get(LF_DIST, re.articolo());
valore = dist.get("DESCR");
break;
}
default:
break;
break;
case 'V':
valore = cache().get(LF_DIST, re.articolo(), "DESCR");
break;
default:
valore = cache().get(LF_ANAMAG, re.articolo(), ANAMAG_DESCR);
break;
}
if (livelli_giacenza().enabled())
{