changed user -> id_user in decklist_folders and decklist_files (issue #48)

This commit is contained in:
Max-Wilhelm Bruker
2013-01-10 00:01:06 +01:00
parent 2e06b95e5c
commit 915e809eb5
3 changed files with 19 additions and 19 deletions

View File

@@ -489,15 +489,15 @@ void Servatrice_DatabaseInterface::storeGameInformation(const QString &roomName,
}
}
DeckList *Servatrice_DatabaseInterface::getDeckFromDatabase(int deckId, const QString &userName)
DeckList *Servatrice_DatabaseInterface::getDeckFromDatabase(int deckId, int userId)
{
checkSql();
QSqlQuery query(sqlDatabase);
query.prepare("select content from " + server->getDbPrefix() + "_decklist_files where id = :id and user = :user");
query.prepare("select content from " + server->getDbPrefix() + "_decklist_files where id = :id and id_user = :id_user");
query.bindValue(":id", deckId);
query.bindValue(":user", userName);
query.bindValue(":id_user", userId);
execSqlQuery(query);
if (!query.next())
throw Response::RespNameNotFound;