Corretto errore prorata
git-svn-id: svn://10.65.10.50/trunk@2616 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
581fbefbc0
commit
f1bfaa0fdc
@ -825,48 +825,33 @@ void TLiquidazione_app::describe_liq(int month, const char* codatts,
|
||||
|
||||
_DescrItem* TLiquidazione_app::describe_deleghe(int month)
|
||||
{
|
||||
/*
|
||||
if (!look_del(month,1)) return NULL;
|
||||
_stampa_vers = _stampa_acc = FALSE;
|
||||
|
||||
_DescrItem* d = new _DescrItem(DELEGA);
|
||||
|
||||
if (_del->get_bool("B0"))
|
||||
{
|
||||
d->_s0 = _del->get("S2"); // localita'
|
||||
d->_s1 = _del->get("S1"); // banca
|
||||
d->_s2 = _del->get("S7"); // ABI
|
||||
d->_s3 = _del->get("S8"); // CAB
|
||||
d->_r0 = _del->get_real("R0");
|
||||
d->_d0 = _del->get_date("D0");
|
||||
} // altrimenti lascia tutto in bianco e ci scriveranno i dati a mano
|
||||
}
|
||||
return d;
|
||||
*/
|
||||
bool stampa_vers = FALSE;
|
||||
if (_lim->get_real("R0") > ZERO)
|
||||
{
|
||||
real iva = _lim->get_real("R0") + _lim->get_real("R14");
|
||||
if (_isannual) iva.round(ROUND_MILLELIRE);
|
||||
if (month == 13) iva.round(ROUND_MILLELIRE);
|
||||
if (iva >= IVA_DA_RIPORTARE)
|
||||
stampa_vers = TRUE;
|
||||
_stampa_vers = TRUE;
|
||||
}
|
||||
|
||||
/***13/02/1996
|
||||
int mese = month;
|
||||
if (_freqviva == "T" && _isannual) mese = 12;
|
||||
|
||||
//17/11/1995
|
||||
/*
|
||||
if (!look_del(month,month == 13 ? 2 : 1) &&
|
||||
!look_del(mese,7) && !stampa_vers) return NULL;
|
||||
*/
|
||||
if (!look_del(mese,7) && !stampa_vers) return NULL;
|
||||
//fine
|
||||
***/
|
||||
|
||||
_stampa_acc = (month == 12 && (_freqviva == "M" || (_isbenzinaro && _gest4)))
|
||||
||(month == 13 && _freqviva == "T" && !(_isbenzinaro && _gest4));
|
||||
|
||||
if (!_stampa_vers && !(_stampa_acc && look_del(12,7))) return NULL;
|
||||
|
||||
_DescrItem* d = new _DescrItem(DELEGA);
|
||||
|
||||
d->_f0 = 0;
|
||||
|
||||
if (stampa_vers) //solo se sono a debito
|
||||
//prospettino versamento
|
||||
if (_stampa_vers) //solo se sono a debito
|
||||
if (look_del(month,month == 13 ? 2 : 1))
|
||||
{
|
||||
if (_del->get("S9").not_empty())
|
||||
@ -882,10 +867,10 @@ _DescrItem* TLiquidazione_app::describe_deleghe(int month)
|
||||
d->_d0 = _del->get_date("D0");
|
||||
} // altrimenti lascia tutto in bianco e ci scriveranno i dati a mano
|
||||
}
|
||||
|
||||
//prospettino acconto
|
||||
if ( (month == 12 && (_freqviva == "M" || (_isbenzinaro && _gest4)))
|
||||
|| (_isannual && _freqviva == "T" && !(_isbenzinaro && _gest4)) )
|
||||
if (look_del(12,7)) //sia che sia a debito oppure a credito
|
||||
|| (month == 13 && _freqviva == "T" && !(_isbenzinaro && _gest4)) )
|
||||
if (look_del(12,7)) //sia che sia a debito che a credito
|
||||
{
|
||||
d->_s4 = "ACC";
|
||||
if (_del->get("S9").not_empty())
|
||||
@ -1632,7 +1617,7 @@ void TLiquidazione_app::set_grand(_DescrItem& d)
|
||||
if (di._s4 == "ACC")
|
||||
{
|
||||
TToken_string ac(di._s5);
|
||||
if (!ac.empty_items())
|
||||
if (!ac.empty_items() && _stampa_vers)
|
||||
cont = 14;
|
||||
}
|
||||
if (rw < (printer().formlen() - cont))
|
||||
@ -1680,10 +1665,13 @@ void TLiquidazione_app::set_grand(_DescrItem& d)
|
||||
set_row(rw++, "@68gConcessione %s", (const char*)loc);
|
||||
}
|
||||
}
|
||||
set_row(rw++, "- SALDO -");
|
||||
//if (_stampa_vers) set_row(rw++, "- SALDO -");
|
||||
}
|
||||
//fine
|
||||
|
||||
if (_stampa_acc && _stampa_vers) set_row(rw++, "- SALDO -");
|
||||
|
||||
if (_stampa_vers)
|
||||
{
|
||||
set_row(rw, " Versamento di L. %s effettuato il %s",
|
||||
(const char*)vr,
|
||||
(const char*)dt);
|
||||
@ -1708,6 +1696,7 @@ void TLiquidazione_app::set_grand(_DescrItem& d)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!_is_visliq) set_auto_ff(TRUE);
|
||||
else set_auto_ff(FALSE);
|
||||
@ -1730,8 +1719,10 @@ bool TLiquidazione_app::set_annual(_DescrItem& d)
|
||||
{
|
||||
// non lo ha stampato prima se annuale, perche' vladimiro il nefido
|
||||
// pretende l'assurdo aggiornamento della perc. a quella nuova
|
||||
set_row(++row, "%% PRO-RATA ed IVA non detraibile (%s%%)@69g%r",
|
||||
(const char*)(d._r2.string()), &(d._r6));
|
||||
|
||||
//set_row(++row, "%% PRO-RATA ed IVA non detraibile (%s%%)@69g%r",
|
||||
// (const char*)(d._r2.string()), &(d._r6));
|
||||
set_row(++row,"CALCOLO DELLA PERCENTUALE DI INDETRAIBILITA'");
|
||||
row++;
|
||||
|
||||
set_bookmark("Calcolo pro-rata", _att_bookmark);
|
||||
@ -1739,8 +1730,10 @@ bool TLiquidazione_app::set_annual(_DescrItem& d)
|
||||
ret = TRUE;
|
||||
set_print_zero(TRUE);
|
||||
set_row(row++,"");
|
||||
set_row(row++,"CALCOLO DELLA PERCENTUALE DI INDETRAIBILITA'");
|
||||
set_row(row++,"");
|
||||
//set_row(row++,"CALCOLO DELLA PERCENTUALE DI INDETRAIBILITA'");
|
||||
set_row(row++, "%% PRO-RATA ed IVA non detraibile (%s%%)@69g%r",
|
||||
(const char*)(d._r2.string()), &(d._r6));
|
||||
//set_row(row++,"");
|
||||
set_row(row++,"Operazioni esenti riga B1@30g%r", &(d._r1));
|
||||
set_row(row++,"Operazioni esenti riga B2@30g%r", &(d._r4));
|
||||
set_row(row++,"Operazioni esenti riga B3@30g%r", &(d._r5));
|
||||
|
Loading…
x
Reference in New Issue
Block a user