1 #ifndef PROJECTDATABASE_H
2 #define PROJECTDATABASE_H
3 #include "database/database.h"
5 #include "exceptions/dbexception.h"
7 #include "models/project.h"
9 #include "utils/string.h"
10 #include "utils/log.h"
11 #include "gui/widgets/widgetsmodels/projectstablemodel.h"
13 using namespace Utils;
14 using namespace Exceptions;
15 using namespace Gui::Widgets;
67 void removeProject(
const int pId);
82 int getNbProjects(
const int customerId);
89 QMap<int, Models::Project> getProjectsOfCustomer(
90 QSharedPointer<Models::Customer> c,
const bool projectLocked=
true);
97 QList<Models::Project> getProjects(
const int customerId);
112 QSharedPointer<Project> updateProject(QSqlQuery &q);
118 QList<Project*> getAllProjects();
126 double getCostProjects(QList<Project*> projects);
138 #endif // PROJECTDATABASE_H
The DbException class for database exception : queries, db file, …
Definition: dbexception.h:18
The Database class Master class for all database access.
Definition: database.h:34
The Project class : Project linked to a Customer.
Definition: project.h:17
The ProjectDatabase class Project table database.
Definition: projectdatabase.h:25