cg2102.cpp Corretto errore MI6269: riporta descrizione in testata
sulla prima riga contabile solo se questa e' vuota. Corretto errore MI3599: non generare contropartite con conti incompleti. git-svn-id: svn://10.65.10.50/trunk@4754 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
a2439c25b1
commit
65a45f7705
@ -369,8 +369,11 @@ int TPrimanota_application::set_cgs_row(int n, const TImporto& imp,
|
|||||||
if (tipo == 'T') // Calcolo contropartita
|
if (tipo == 'T') // Calcolo contropartita
|
||||||
{
|
{
|
||||||
TToken_string& irow = ivas().row(0);
|
TToken_string& irow = ivas().row(0);
|
||||||
for (int i = 5; i < 10; i++)
|
TBill contro(irow, 5, 0x3);
|
||||||
row.add(irow.get(i == 5 ? 5 : -1));
|
if (contro.ok()) // Errore MI3599
|
||||||
|
row.add(contro.string(0x3));
|
||||||
|
else
|
||||||
|
row.add(" | | | | ");
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -378,9 +381,11 @@ int TPrimanota_application::set_cgs_row(int n, const TImporto& imp,
|
|||||||
if (pos >= 0)
|
if (pos >= 0)
|
||||||
{
|
{
|
||||||
TBill contro(cg.row(pos), 2, 0x3);
|
TBill contro(cg.row(pos), 2, 0x3);
|
||||||
|
if (contro.ok())
|
||||||
row.add(contro.string(0x3));
|
row.add(contro.string(0x3));
|
||||||
}
|
}
|
||||||
else row.add(" | | | | ");
|
else
|
||||||
|
row.add(" | | | | ");
|
||||||
}
|
}
|
||||||
|
|
||||||
row << "| |" << tipo;
|
row << "| |" << tipo;
|
||||||
@ -956,11 +961,15 @@ bool TPrimanota_application::descr_handler(TMask_field& f, KEY k)
|
|||||||
if (first >= 0)
|
if (first >= 0)
|
||||||
{
|
{
|
||||||
TSheet_field& cg = app().cgs();
|
TSheet_field& cg = app().cgs();
|
||||||
|
const TString80 old = cg.row(first).get(8);
|
||||||
|
if (old.blank)
|
||||||
|
{
|
||||||
cg.row(first).add(f.get(), 8);
|
cg.row(first).add(f.get(), 8);
|
||||||
cg.force_update(first);
|
cg.force_update(first);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
if (k == K_ENTER && f.get().empty())
|
if (k == K_ENTER && f.get().empty())
|
||||||
{
|
{
|
||||||
if (f.mask().get(F_CODCAUS).empty())
|
if (f.mask().get(F_CODCAUS).empty())
|
||||||
|
Loading…
x
Reference in New Issue
Block a user