@ -45,8 +45,9 @@ public:
QSharedPointer<T> loadById(int id) {
odb::database *db = Context::instance().db();
odb::transaction tx(db->begin());
db->template load<T>(id);
QSharedPointer<T> entity = db->template load<T>(id);
tx.commit();
return entity;
}
};