Change message for new users
Fix a bug : updating operations doesn't work
This commit is contained in:
parent
34a36199a2
commit
f1661e315c
|
@ -1,6 +1,6 @@
|
|||
v0.3 (05/05/2012)
|
||||
** User **
|
||||
New interface in Qt
|
||||
New interface in Qt4
|
||||
Use BDD file from .local/share/kisscount
|
||||
Use libkchart for graphics
|
||||
Use oxygen icons
|
||||
|
|
3
TODO
3
TODO
|
@ -37,3 +37,6 @@ it's not taken in account by UpdateStats
|
|||
it will not be displayed. In this case we must load whole meta.
|
||||
This bug can't be resolved without use of hashtable because of
|
||||
complexity in searching this issue.
|
||||
|
||||
* When changing date in a sub operation (set date > main date),
|
||||
meta amount is set to 0
|
|
@ -88,14 +88,11 @@ void Database::CreateDatabase()
|
|||
QString sPath = GetDatabaseHome() + GetDatabaseFile();
|
||||
QDir dirname( GetDatabaseHome());
|
||||
QFile file(sPath);
|
||||
QString message = _("No database found, would you like to create a new one ?\n\n");
|
||||
message += _("!! Warning !! If there was a bug, the old database will be suppressed !");
|
||||
QString message;
|
||||
|
||||
if (dirname.exists())
|
||||
{
|
||||
if (QMessageBox::question(0, "KissCount", message, QMessageBox::Yes|QMessageBox::No) == QMessageBox::No)
|
||||
throw std::string("No database") ;
|
||||
}
|
||||
message = _("A new database will be created, continue ?");
|
||||
if (QMessageBox::question(0, "KissCount", message, QMessageBox::Yes|QMessageBox::No) == QMessageBox::No)
|
||||
throw std::string("Abort") ;
|
||||
|
||||
if (!init_script.exists() || !init_script.open(QIODevice::ReadOnly | QIODevice::Text))
|
||||
{
|
||||
|
|
|
@ -50,7 +50,18 @@ bool XMLExportEngine::SaveAccounts()
|
|||
|
||||
for(it=_accounts.begin(); it!=_accounts.end(); it++)
|
||||
{
|
||||
account = _user->GetAccount(it->first);
|
||||
try
|
||||
{
|
||||
account = _user->GetAccount(it->first);
|
||||
}
|
||||
catch(User::AccountNotFound)
|
||||
{
|
||||
account.id = it->first;
|
||||
account.name = "Unknown";
|
||||
account.blocked = false;
|
||||
account._virtual = false;
|
||||
account.hidden = false;
|
||||
}
|
||||
|
||||
ESCAPE_CHARS(account.name);
|
||||
ESCAPE_CHARS(account.number);
|
||||
|
|
|
@ -1037,14 +1037,11 @@ void GridAccount::OnOperationModified(int row, int col)
|
|||
{
|
||||
need_insertion = true;
|
||||
removeRow(row);
|
||||
DeleteOperation(cur_op);
|
||||
_displayedOperations.erase(_displayedOperations.begin()+row);
|
||||
if (fix_cost)
|
||||
_fixCosts--;
|
||||
}
|
||||
else
|
||||
(_displayedOperations)[row] = new_op;
|
||||
}
|
||||
|
||||
(_displayedOperations)[row] = new_op;
|
||||
UpdateOperation(new_op);
|
||||
}
|
||||
// Add an operation
|
||||
|
|
Loading…
Reference in New Issue
Block a user