diff --git a/ca/ca3700.cpp b/ca/ca3700.cpp
index 6bbc9b14f..e681351b4 100755
--- a/ca/ca3700.cpp
+++ b/ca/ca3700.cpp
@@ -539,7 +539,6 @@ void TPrint_rendiconto_ca_recordset::scrive_riga(const TRectype& rmovana, const
int tipo_babbo = TTipo_documento::_altro;
TString80 riferimento; //stringa su cui scrivere gli estremi del doc padre (se lo trova!)
- real totale_doc_babbo; //totale del doc padre
const int rows = newdoc->physical_rows(); //righe del doc attuale
for (int i = 1; riferimento.empty() && i <= rows; i++)
@@ -554,7 +553,6 @@ void TPrint_rendiconto_ca_recordset::scrive_riga(const TRectype& rmovana, const
riferimento << babbo_codnum << '-' << anno << '-' << ndoc;
TDocumento doc_babbo('D', anno, babbo_codnum, ndoc); //crea una copia del doc padre per prendere..
tipo_babbo = doc_babbo.tipo_riclassificato(); //..il tipo documento..
- totale_doc_babbo = doc_babbo.totale_doc(); //..il suo totale
} //if (babbo != NULL)..
} //for (int i..
@@ -607,8 +605,9 @@ F=IMF*/
const char sezione = rmovana.get_char(RMOVANA_SEZIONE);
TImporto imp(sezione, rmovana.get_real(RMOVANA_IMPORTO));
+ const int anno_caus = movana.get_date(MOVANA_DATAREG).year();
- TCausale caus(movana.get(MOVANA_CODCAUS));
+ TCausale caus(movana.get(MOVANA_CODCAUS), anno_caus);
TipoIVA tipoiva = caus.iva();
char sezione_normale;
@@ -645,6 +644,7 @@ F=IMF*/
}
tmpcurr.put("NUMREG", rmovana.get(RMOVANA_NUMREG));
+ tmpcurr.put("NUMREGCG", movana.get(MOVANA_NUMREGCG)); //numero di registrazione contabile
tmpcurr.put("DESC", descr); //descrizione movana
tmpcurr.put("NRIGA", rmovana.get(RMOVANA_NUMRIG)); //numero riga
tmpcurr.put("DESCRIGA", rmovana.get(RMOVANA_DESCR)); //descrizione rmovana
@@ -908,13 +908,14 @@ void TPrint_rendiconto_ca_recordset::crea_trr(const TFilename& trr) const
{
ofstream of(trr);
of << 1000 << endl;
- of << 17 << endl;
+ of << 18 << endl;
of << "CONTO|1|20|0|Conto analitico" << endl;
of << "DATA|5|8|0|Data movimento o documento" << endl;
of << "CODNUM|1|4|0|Numerazione documento" << endl;
of << "NUMRD|3|7|0|Numero registrazione contabile o numero documento di origine" << endl;
of << "NRIGA|2|3|0|Riga movimento o documento" << endl;
of << "NUMREG|3|7|0|Numero registrazione del movimento analitico" << endl;
+ of << "NUMREGCG|3|7|Numero registrazione contabile" << endl;
of << "ANNO|9|4|0|Anno" << endl;
of << "NUMDOCRIF|1|7|0|Numero documento riferimento" << endl;
of << "DATADOCRIF|5|8|0|Data documento riferimento" << endl;
diff --git a/ca/ca3700a.rep b/ca/ca3700a.rep
index 4cb69b5b5..f9228dd58 100755
--- a/ca/ca3700a.rep
+++ b/ca/ca3700a.rep
@@ -15,16 +15,17 @@
-
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
@@ -192,23 +193,26 @@ MESSAGE RESET,F2.103
-
+
+
+
+
-
+
-
+
-
+
-
+
-
+