Create default categories using locales (need better translation)

This commit is contained in:
2010-07-07 21:19:47 +02:00
parent 63ca3a9c22
commit cef0e4eb3c
3 changed files with 16 additions and 31 deletions

View File

@@ -226,6 +226,7 @@ void KissCount::NewUser(const wxString& name)
{
wxDateTime curDate;
Account ac = {wxT(""), wxT("Account 1"), wxT(""), false, true};
Category cat ;
_db->NewUser(name);
if (_user) delete _user;
@@ -234,6 +235,20 @@ void KissCount::NewUser(const wxString& name)
curDate.SetToCurrent();
AddAccount(ac);
cat.parent = wxT("0") ; cat.name = _("Fix") ; cat.color = OWN_YELLOW ;
AddCategory(cat);
cat.parent = wxT("0") ; cat.name = _("Groceries") ; cat.color = OWN_GREEN;
AddCategory(cat);
cat.parent = wxT("0") ; cat.name = _("Loisirs") ; cat.color = OWN_GREEN;
AddCategory(cat);
cat.parent = wxT("0") ; cat.name = _("Normal life") ; cat.color = OWN_GREEN;
AddCategory(cat);
cat.parent = wxT("0") ; cat.name = _("Unexpected") ; cat.color = OWN_GREEN;
AddCategory(cat);
cat.parent = wxT("0") ; cat.name = _("Other") ; cat.color = OWN_GREEN;
AddCategory(cat);
_db->GenerateMonth(_user, -1, -1, (int)curDate.GetMonth(), curDate.GetYear());
}