[grisbi-cvs] grisbi/src accueil.c, 1.227, 1.228 balance_estimate_tab.c, 1.65, 1.66 gsb_account_property.c, 1.52, 1.53 gsb_data_transaction.c, 1.87, 1.88 gsb_file_load.c, 1.220, 1.221 structures.h, 1.245, 1.246

Pierre Biava pbiava at users.sourceforge.net
Sat Apr 24 07:39:27 CEST 2010


Update of /cvsroot/grisbi/grisbi/src
In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv30973/src

Modified Files:
	accueil.c balance_estimate_tab.c gsb_account_property.c 
	gsb_data_transaction.c gsb_file_load.c structures.h 
Log Message:
fixes a bug for display code BIC and minor changes

Index: structures.h
===================================================================
RCS file: /cvsroot/grisbi/grisbi/src/structures.h,v
retrieving revision 1.245
retrieving revision 1.246
diff -u -d -r1.245 -r1.246
--- structures.h	5 Apr 2010 21:24:53 -0000	1.245
+++ structures.h	24 Apr 2010 05:39:25 -0000	1.246
@@ -13,7 +13,7 @@
 #define VERSION_FICHIER "0.6.0"
 
 /* Define this when in CVS development branch. */
-#define IS_DEVELOPMENT_VERSION 1
+#define IS_DEVELOPMENT_VERSION 0
 
 #define VERSION_FICHIER_ETAT "0.6.0"
 #define VERSION_FICHIER_CATEG "0.6.0"

Index: gsb_data_transaction.c
===================================================================
RCS file: /cvsroot/grisbi/grisbi/src/gsb_data_transaction.c,v
retrieving revision 1.87
retrieving revision 1.88
diff -u -d -r1.87 -r1.88
--- gsb_data_transaction.c	18 Apr 2010 07:53:06 -0000	1.87
+++ gsb_data_transaction.c	24 Apr 2010 05:39:25 -0000	1.88
@@ -647,7 +647,7 @@
     if ( !transaction )
 	return NULL;
 
-    if ( transaction -> value_date )
+    if ( transaction -> value_date && g_date_valid ( transaction -> value_date ) )
         return transaction -> value_date;
     else
         return transaction -> date;

Index: accueil.c
===================================================================
RCS file: /cvsroot/grisbi/grisbi/src/accueil.c,v
retrieving revision 1.227
retrieving revision 1.228
diff -u -d -r1.227 -r1.228
--- accueil.c	20 Apr 2010 21:34:33 -0000	1.227
+++ accueil.c	24 Apr 2010 05:39:25 -0000	1.228
@@ -2022,7 +2022,7 @@
     /* create the model */
     list_store = gsb_partial_balance_create_model ( );
 
-    /* remplit le modèle si nécessaire */
+    /* populate the model if necessary */
     if ( g_slist_length ( gsb_data_partial_balance_get_list ( ) ) > 0 )
         gsb_partial_balance_fill_model ( list_store );
 

Index: gsb_account_property.c
===================================================================
RCS file: /cvsroot/grisbi/grisbi/src/gsb_account_property.c,v
retrieving revision 1.52
retrieving revision 1.53
diff -u -d -r1.52 -r1.53
--- gsb_account_property.c	18 Apr 2010 14:38:28 -0000	1.52
+++ gsb_account_property.c	24 Apr 2010 05:39:25 -0000	1.53
@@ -627,6 +627,7 @@
 
     /* fill bank information */
     bank_number = gsb_data_account_get_bank (current_account);
+    gsb_account_property_set_label_code_bic ( bank_number );
 
     gsb_account_property_iban_set_iban (
                         gsb_data_account_get_bank_account_iban (current_account) );

Index: gsb_file_load.c
===================================================================
RCS file: /cvsroot/grisbi/grisbi/src/gsb_file_load.c,v
retrieving revision 1.220
retrieving revision 1.221
diff -u -d -r1.220 -r1.221
--- gsb_file_load.c	20 Apr 2010 21:34:33 -0000	1.220
+++ gsb_file_load.c	24 Apr 2010 05:39:25 -0000	1.221
@@ -1610,7 +1610,6 @@
     if ( !strcmp ( attribute_names[i],
                         "Owner_address" ))
     {
-        printf ("attribute_values[i] = %s\n",attribute_values[i]);
         if ( g_strstr_len ( attribute_values[i], -1, "
" ) )
         {
             gchar **owner_tab;

Index: balance_estimate_tab.c
===================================================================
RCS file: /cvsroot/grisbi/grisbi/src/balance_estimate_tab.c,v
retrieving revision 1.65
retrieving revision 1.66
diff -u -d -r1.65 -r1.66
--- balance_estimate_tab.c	20 Apr 2010 21:34:33 -0000	1.65
+++ balance_estimate_tab.c	24 Apr 2010 05:39:25 -0000	1.66
@@ -216,7 +216,8 @@
         return -1;
 
     /* get first date to compare */
-    gtk_tree_model_get_value ( model, itera, SPP_ESTIMATE_TREE_SORT_DATE_COLUMN, &date_value_a );
+    gtk_tree_model_get_value ( model, itera, 
+                        SPP_ESTIMATE_TREE_SORT_DATE_COLUMN, &date_value_a );
     date_a = g_value_get_boxed ( &date_value_a );
     if ( date_a == NULL )
         return -1;
@@ -229,6 +230,40 @@
 
     gint result = g_date_compare (date_b, date_a);
 
+    if ( result == 0 )
+    {
+        gint origine;
+        gchar *str_amount_a;
+        gchar *str_amount_b;
+        gsb_real amount_a = null_real;
+        gsb_real amount_b = null_real;
+
+        gtk_tree_model_get ( GTK_TREE_MODEL ( model ), itera,
+                        SPP_ESTIMATE_TREE_ORIGIN_DATA, &origine,
+                        SPP_ESTIMATE_TREE_AMOUNT_COLUMN, &str_amount_a,
+                        -1 );
+
+        if ( origine == SPP_ORIGIN_HISTORICAL )
+        {
+            gtk_tree_model_get ( GTK_TREE_MODEL ( model ), iterb,
+                        SPP_ESTIMATE_TREE_ORIGIN_DATA, &origine,
+                        SPP_ESTIMATE_TREE_AMOUNT_COLUMN, &str_amount_b,
+                        -1 );
+            if ( origine != SPP_ORIGIN_HISTORICAL )
+                result = -1;
+            else
+            {
+                amount_a = gsb_real_import_from_string ( str_amount_a );
+                amount_b = gsb_real_import_from_string ( str_amount_b );
+                result = - ( gsb_real_cmp ( amount_a, amount_b ) );
+            }
+
+            g_free ( str_amount_b );
+        }
+
+        g_free ( str_amount_a );
+    }
+
     g_value_unset ( &date_value_b );
     g_value_unset ( &date_value_a );
 
@@ -1281,7 +1316,7 @@
                     tree_selection );
     gtk_menu_shell_append ( GTK_MENU_SHELL ( menu ), menu_item );
 
-    /* Delete item */
+    /* Delete convert item */
     switch ( origine )
     {
         case SPP_ORIGIN_TRANSACTION:



More information about the cvs mailing list