r15868 - gnucash/trunk/src/import-export/hbci - Use aqbanking's FiId field for correct OFX duplicate matching. #418072, patch by David Reiser.

Christian Stimming cstim at cvs.gnucash.org
Tue Apr 10 15:32:31 EDT 2007


Author: cstim
Date: 2007-04-10 15:32:30 -0400 (Tue, 10 Apr 2007)
New Revision: 15868
Trac: http://svn.gnucash.org/trac/changeset/15868

Modified:
   gnucash/trunk/src/import-export/hbci/gnc-hbci-gettrans.c
Log:
Use aqbanking's FiId field for correct OFX duplicate matching. #418072, patch by David Reiser.

Modified: gnucash/trunk/src/import-export/hbci/gnc-hbci-gettrans.c
===================================================================
--- gnucash/trunk/src/import-export/hbci/gnc-hbci-gettrans.c	2007-04-10 19:01:25 UTC (rev 15867)
+++ gnucash/trunk/src/import-export/hbci/gnc-hbci-gettrans.c	2007-04-10 19:32:30 UTC (rev 15868)
@@ -39,6 +39,7 @@
 #include "dialog-hbcitrans.h"
 #include "gnc-hbci-kvp.h"
 #include "dialog-daterange.h"
+#include "import-utilities.h"
 
 /* static short module = MOD_IMPORT; */
 
@@ -261,11 +262,14 @@
   /* Create new gnucash transaction for the given hbci one */
   gnc_trans = xaccMallocTransaction(book);
   xaccTransBeginEdit(gnc_trans);
+    
+  {
+    /* OFX unique transaction ID */
+    const char *fitid = AB_Transaction_GetFiId(h_trans);
+    if (fitid && (strlen (fitid) > 0))
+      gnc_import_set_trans_online_id(gnc_trans, fitid);
+  }
 
-  /*if(data.fi_id_valid==true){
-    gnc_import_set_trans_online_id(gnc_trans, data.fi_id);
-    }*/
-
   normalDate = AB_Transaction_GetDate(h_trans);
   valutaDate = AB_Transaction_GetValutaDate(h_trans);
   if (normalDate && !valutaDate)



More information about the gnucash-changes mailing list