r20169 - gnucash/trunk/src/plugins/bi_import - Open the newly created invoices for editing after import.
Mike Evans
mikee at code.gnucash.org
Wed Jan 26 12:13:09 EST 2011
Author: mikee
Date: 2011-01-26 12:13:09 -0500 (Wed, 26 Jan 2011)
New Revision: 20169
Trac: http://svn.gnucash.org/trac/changeset/20169
Modified:
gnucash/trunk/src/plugins/bi_import/Makefile.am
gnucash/trunk/src/plugins/bi_import/bi_import.c
Log:
Open the newly created invoices for editing after import.
Modified: gnucash/trunk/src/plugins/bi_import/Makefile.am
===================================================================
--- gnucash/trunk/src/plugins/bi_import/Makefile.am 2011-01-25 17:06:59 UTC (rev 20168)
+++ gnucash/trunk/src/plugins/bi_import/Makefile.am 2011-01-26 17:13:09 UTC (rev 20169)
@@ -33,9 +33,14 @@
AM_CFLAGS = \
-I${top_srcdir}/src \
-I${top_srcdir}/src/gnome \
+ -I${top_srcdir}/src/business/business-gnome/ \
+ -I${top_srcdir}/src/report/report-gnome \
+ -I${top_srcdir}/src/gnome-search/ \
-I${top_srcdir}/src/register/ledger-core \
+ -I${top_srcdir}/src/business/business-ledger/ \
-I${top_srcdir}/src/register/register-gnome \
-I${top_srcdir}/src/register/register-core \
+ -I${top_srcdir}/src/business/dialog-tax-table \
-I${top_srcdir}/src/gnome-utils \
-I${top_srcdir}/src/app-utils \
-I${top_srcdir}/src/engine \
Modified: gnucash/trunk/src/plugins/bi_import/bi_import.c
===================================================================
--- gnucash/trunk/src/plugins/bi_import/bi_import.c 2011-01-25 17:06:59 UTC (rev 20168)
+++ gnucash/trunk/src/plugins/bi_import/bi_import.c 2011-01-26 17:13:09 UTC (rev 20169)
@@ -61,10 +61,11 @@
#include "bi_import.h"
#include "helpers.h"
+// To open the incoices for editing
+#include "gnc-plugin-page.h"
+#include "dialog-invoice.c"
-
-
//#ifdef HAVE_GLIB_2_14
// glib >= 2.14.0
// perl regular expressions are available
@@ -488,8 +489,9 @@
enum update {YES = GTK_RESPONSE_YES, NO = GTK_RESPONSE_NO} update;
GtkWidget *dialog;
Timespec today;
+ GncPluginPage *new_page;
+ InvoiceWindow *iw;
-
// these arguments are needed
g_return_if_fail (store && book);
@@ -575,6 +577,9 @@
//if (g_ascii_strcasecmp(type,"INVOICE"))gncInvoiceSetBillTo( invoice, billto );
(*n_invoices_created)++;
update = YES;
+ // Open the newly created invoice(s) in a tab. Could be made optional?
+ iw = gnc_ui_invoice_edit (invoice);
+ new_page = gnc_plugin_page_invoice_new (iw);
}
// I want to warn the user that an existing billvoice exists, but not every
// time.
More information about the gnucash-changes
mailing list