*** empty log message ***

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@2288 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
Dave Peticolas 2000-05-10 05:37:04 +00:00
parent 1da23090d2
commit a74bb32ac5
4 changed files with 16 additions and 8 deletions

View File

@ -1,5 +1,9 @@
2000-05-09 Dave Peticolas <peticola@cs.ucdavis.edu>
* src/gnome/dialog-add.c (gnc_ui_accWindow_create_account): insert
the account *after* setting the account values so the sort order
is correct.
* src/engine/Account.c (xaccAccountInsertSplit): check the currency
before inserting.

View File

@ -41,6 +41,8 @@ default:
@echo "qt kde/qt version (unfinished)"
@echo "qt-static kde/qt statically linked version (unfinished)"
@echo " "
@echo "The motif and qt versions do not compile!"
@echo " "
# This inclusion must come after the first target, and after the
# definitions of *_SRCS, etc., but before the usage of *_OBJS.

View File

@ -551,7 +551,7 @@ xaccGroupInsertAccount( AccountGroup *grp, Account *acc )
int i,nacc;
Account **arr;
int ralo = 1;
if (NULL == grp) return;
if (NULL == acc) return;
@ -566,7 +566,7 @@ xaccGroupInsertAccount( AccountGroup *grp, Account *acc )
}
grp->saved = GNC_F;
/* set back-pointer to the accounts parent */
/* set back-pointer to the account's parent */
acc->parent = grp;
nacc = grp->numAcc;

View File

@ -343,19 +343,15 @@ static void
gnc_ui_accWindow_create_account(Account * account, Account * parent,
gint type, AccountFieldStrings * strings)
{
xaccAccountBeginEdit(parent, 0);
xaccAccountBeginEdit(account, 0);
if (parent != NULL)
xaccInsertSubAccount (parent, account);
else
xaccGroupInsertAccount(gncGetCurrentGroup(), account);
xaccAccountSetType (account, type);
gnc_ui_install_field_strings(account, strings, TRUE);
{ /* make a default transaction */
Transaction *trans = xaccMallocTransaction();
Transaction *trans = xaccMallocTransaction();
xaccTransBeginEdit(trans, 1);
xaccTransSetDateToday (trans);
@ -365,7 +361,13 @@ gnc_ui_accWindow_create_account(Account * account, Account * parent,
xaccAccountInsertSplit (account, xaccTransGetSplit (trans, 0) );
}
if (parent != NULL)
xaccInsertSubAccount (parent, account);
else
xaccGroupInsertAccount(gncGetCurrentGroup(), account);
xaccAccountCommitEdit (account);
xaccAccountCommitEdit (parent);
gnc_account_tree_insert_account(gnc_get_current_account_tree(), account);