Patch level : 12.0 566
Files correlati : cg4.exe f171.dir f171.trr f23.dir f23.trr Modificata la liquidazione delle fatture in ritardo Aggiunta la gestione dell'uscita dal regime di cassa Sistemata la cancellazione di IVADIFF nei mesi e in 13. Aggiunto FLAG di iva liquidata sulla testata movimenti, che viene aggiornato dalla liquidazione. git-svn-id: svn://10.65.10.50/branches/R_10_00@24474 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
3dd669b20d
commit
e7e87ef9ff
@ -664,9 +664,9 @@ bool TLiquidazione_app::ivadiff_chiusa(const TRectype& mov, const TDate& fine) c
|
||||
for (; err == NOERR && rid.get_long(MOV_NUMREG) == numreg; err = id.next())
|
||||
{
|
||||
const TDate data = rid.get("DATAREGP");
|
||||
if (data > fine)
|
||||
if (data > fine && !_end_cassa)
|
||||
continue;
|
||||
if (data == fine && rid.get_long("NUMREGP") == numreg)
|
||||
if (data == fine && rid.get_long("NUMREGP") == numreg && !_end_cassa)
|
||||
continue; // Ignora pagamento automatico dopo un anno
|
||||
|
||||
const real imp = rid.get(RMI_IMPOSTA);
|
||||
@ -1156,7 +1156,7 @@ void TLiquidazione_app::recalc_att(int month, const char* codatt, TAssoc_array &
|
||||
#ifdef DBG
|
||||
long nr = _mov->get_long(MOV_NUMREG);
|
||||
|
||||
if (nr == 1931434 || nr == 27710)
|
||||
if (nr == 25722 || nr == 27710)
|
||||
int i = 1;
|
||||
#endif
|
||||
|
||||
@ -1236,7 +1236,7 @@ void TLiquidazione_app::recalc_att(int month, const char* codatt, TAssoc_array &
|
||||
#ifdef DBG
|
||||
nr = _mov->get_long(MOV_NUMREG);
|
||||
|
||||
if (nr == 29214 || nr == 27710)
|
||||
if (nr == 25722 || nr == 27710)
|
||||
int i = 1;
|
||||
#endif
|
||||
|
||||
@ -1283,7 +1283,7 @@ void TLiquidazione_app::recalc_att(int month, const char* codatt, TAssoc_array &
|
||||
#ifdef DBG
|
||||
nr = _mov->get_long(MOV_NUMREG);
|
||||
|
||||
if (nr == 29214 || nr == 27710)
|
||||
if (nr == 25722 || nr == 27710)
|
||||
int i = 1;
|
||||
#endif
|
||||
flag_pg_nc = rp.calcola_pagato_periodo(first_month ? botime : inizio + 1L, orizzonte, pg_per, nc_per, &pagscatt) && regular_month;
|
||||
@ -1388,8 +1388,10 @@ void TLiquidazione_app::recalc_att(int month, const char* codatt, TAssoc_array &
|
||||
tot_incassato = tot_da_incassare;
|
||||
|
||||
datainc = data_maturazione_IVA_diff(_mov->curr());
|
||||
if (iva_cass && _end_cassa)
|
||||
if (iva_cass && _end_cassa && datainc.year() != atoi(_year))
|
||||
datainc = data_end_cassa;
|
||||
else
|
||||
int i = 1;
|
||||
_mov->put(MOV_DATAINC, datainc);
|
||||
if (datainc < date)
|
||||
datainc = date;
|
||||
@ -1538,7 +1540,7 @@ void TLiquidazione_app::recalc_att(int month, const char* codatt, TAssoc_array &
|
||||
#ifdef DBG
|
||||
nr = _mov->get_long(MOV_NUMREG);
|
||||
|
||||
if (nr == 29214 || nr == 27710)
|
||||
if (nr == 25722 || nr == 27710)
|
||||
int i = 1;
|
||||
#endif
|
||||
|
||||
@ -1640,7 +1642,7 @@ void TLiquidazione_app::recalc_att(int month, const char* codatt, TAssoc_array &
|
||||
datapag = datafat;
|
||||
}
|
||||
else
|
||||
datapag = _mov->get_date(MOV_DATAINC);
|
||||
datapag = _mov->get_date(MOV_DATAINC) ;
|
||||
|
||||
bool ok = is_month_ok(datapag.month(), month) && (atoi(_year) == datapag.year());
|
||||
|
||||
@ -1716,7 +1718,7 @@ void TLiquidazione_app::recalc_att(int month, const char* codatt, TAssoc_array &
|
||||
id.put(PART_TIPOMOV, tipomov_pag);
|
||||
id.put("NUMREGP", nregpag);
|
||||
id.put("NUMRIGP", nrigp);
|
||||
id.put("DATAREGP", _mov->get(MOV_DATAINC));
|
||||
id.put("DATAREGP",datapag);
|
||||
id.put("ANNOLIQ", year_int);
|
||||
pagtmp.set(sezpag, pagsca.get_real(PAGSCA_IMPORTO));
|
||||
ultimo = true;
|
||||
@ -1844,6 +1846,15 @@ void TLiquidazione_app::recalc_att(int month, const char* codatt, TAssoc_array &
|
||||
id.rewrite();
|
||||
}
|
||||
}
|
||||
|
||||
const bool chiusa = _mov->get_bool(MOV_IVALIQ);
|
||||
|
||||
if (chiusa != ultimo)
|
||||
{
|
||||
_mov->put(MOV_IVALIQ, ultimo);
|
||||
_mov->rewrite();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1,3 +1,3 @@
|
||||
23
|
||||
0
|
||||
$mov|0|0|478|0|Movimenti di prima nota|NMOV||
|
||||
$mov|0|0|479|0|Movimenti di prima nota|NMOV||
|
||||
|
@ -1,5 +1,5 @@
|
||||
23
|
||||
58
|
||||
59
|
||||
ANNOES|9|4|0|Codice esercizio
|
||||
NUMREG|3|7|0|Numero di operazione
|
||||
DATAREG|5|8|0|Data operazione
|
||||
@ -58,6 +58,7 @@ CONTSEP|1|6|0|Contabilit
|
||||
CFBOLLADOG|1|7|0|Codice fornitore a cui è riferita la bolla doganale
|
||||
TFINVIO|7|1|0|Flag Invio Trasferimento Fatture
|
||||
TFDATA|5|8|0|Data ultimo invio Trasferimento Fatture
|
||||
IVALIQ|8|1|0|Iva per cassa liquidata completamente
|
||||
4
|
||||
NUMREG|
|
||||
DATAREG+NUMREG|X
|
||||
|
Loading…
x
Reference in New Issue
Block a user