mirror of
https://gitea.msk.dinamika-avia.ru/Constanta-Design/RRJServer.git
synced 2026-03-28 19:55:48 +03:00
before interface 13.11.2024
This commit is contained in:
@@ -16,6 +16,8 @@ add_library(DataBaseLMS SHARED
|
||||
DataBaseLMS_global.h
|
||||
databaselms.cpp
|
||||
databaselms.h
|
||||
interfacedatabaselms.cpp
|
||||
interfacedatabaselms.h
|
||||
basicentity.cpp
|
||||
basicentity.h
|
||||
user.cpp
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE QtCreatorProject>
|
||||
<!-- Written by QtCreator 4.11.1, 2024-11-06T16:05:43. -->
|
||||
<!-- Written by QtCreator 4.11.1, 2024-11-13T09:53:44. -->
|
||||
<qtcreator>
|
||||
<data>
|
||||
<variable>EnvironmentId</variable>
|
||||
|
||||
@@ -5,7 +5,8 @@
|
||||
#include <QMessageBox>
|
||||
|
||||
DataBaseLMS::DataBaseLMS():
|
||||
db(nullptr)
|
||||
db(nullptr),
|
||||
transactionBegined(false)
|
||||
{
|
||||
createConnection();
|
||||
}
|
||||
@@ -35,14 +36,40 @@ bool DataBaseLMS::createConnection()
|
||||
|
||||
void DataBaseLMS::deleteConnection()
|
||||
{
|
||||
if(transactionBegined)
|
||||
QSqlDatabase::database().rollback();
|
||||
|
||||
if(db != nullptr)
|
||||
{
|
||||
if(db->isOpen())
|
||||
db->close();
|
||||
|
||||
delete db;
|
||||
db = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
bool DataBaseLMS::transactionBegin()
|
||||
{
|
||||
if(transactionBegined)
|
||||
QSqlDatabase::database().rollback();
|
||||
|
||||
transactionBegined = true;
|
||||
|
||||
return QSqlDatabase::database().transaction();
|
||||
}
|
||||
|
||||
bool DataBaseLMS::transactionEnd()
|
||||
{
|
||||
if(transactionBegined)
|
||||
{
|
||||
transactionBegined = false;
|
||||
|
||||
return QSqlDatabase::database().commit();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
QList<Instructor> DataBaseLMS::selectAllInstructors()
|
||||
{
|
||||
QList<Instructor> listInstructors;
|
||||
@@ -51,10 +78,11 @@ QList<Instructor> DataBaseLMS::selectAllInstructors()
|
||||
"FROM public.instructors "
|
||||
"ORDER BY instructor_id ASC");
|
||||
|
||||
QSqlQuery query(*db);
|
||||
QSqlQuery query = QSqlQuery(*db);
|
||||
|
||||
if(!query.exec(queryStr))
|
||||
{
|
||||
messageWarningErrorQuery(queryStr);
|
||||
messageWarningErrorQuery(queryStr, &query);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -89,10 +117,11 @@ QList<Trainee> DataBaseLMS::selectAllTrainees()
|
||||
"LEFT OUTER JOIN public.classrooms ON classrooms.classroom_id = computers.classroom_computer "
|
||||
"ORDER BY groups.name, trainees.name ASC");
|
||||
|
||||
QSqlQuery query(*db);
|
||||
QSqlQuery query = QSqlQuery(*db);
|
||||
|
||||
if(!query.exec(queryStr))
|
||||
{
|
||||
messageWarningErrorQuery(queryStr);
|
||||
messageWarningErrorQuery(queryStr, &query);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -104,7 +133,7 @@ QList<Trainee> DataBaseLMS::selectAllTrainees()
|
||||
trainee.setName(query.value(1).toString());
|
||||
trainee.setLogin(query.value(2).toString());
|
||||
trainee.setPassword(query.value(3).toString());
|
||||
trainee.setArchived(query.value(4).toBool());
|
||||
trainee.setArchived(query.value(4).toBool());
|
||||
trainee.setLoggedIn(query.value(5).toBool());
|
||||
|
||||
Group group = Group(query.value(6).toInt(), query.value(7).toString());
|
||||
@@ -131,10 +160,11 @@ QList<Group> DataBaseLMS::selectAllGroups()
|
||||
"FROM public.groups "
|
||||
"ORDER BY group_id ASC");
|
||||
|
||||
QSqlQuery query(*db);
|
||||
QSqlQuery query = QSqlQuery(*db);
|
||||
|
||||
if(!query.exec(queryStr))
|
||||
{
|
||||
messageWarningErrorQuery(queryStr);
|
||||
messageWarningErrorQuery(queryStr, &query);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -151,10 +181,162 @@ QList<Group> DataBaseLMS::selectAllGroups()
|
||||
return listGroups;
|
||||
}
|
||||
|
||||
Instructor DataBaseLMS::selectInstructor(int id_instructor)
|
||||
{
|
||||
Instructor instructor;
|
||||
|
||||
QString queryStr = QString("SELECT instructor_id, name, login, password, is_admin, archived, logged_in "
|
||||
"FROM public.instructors "
|
||||
"WHERE instructors.instructor_id = %1 ").arg(
|
||||
id_instructor);
|
||||
|
||||
QSqlQuery query = QSqlQuery(*db);
|
||||
|
||||
if(!query.exec(queryStr))
|
||||
{
|
||||
messageWarningErrorQuery(queryStr, &query);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (query.first())
|
||||
{//Инструктор
|
||||
instructor.setID(query.value(0).toInt());
|
||||
instructor.setName(query.value(1).toString());
|
||||
instructor.setLogin(query.value(2).toString());
|
||||
instructor.setPassword(query.value(3).toString());
|
||||
instructor.setIsAdmin(query.value(4).toBool());
|
||||
instructor.setArchived(query.value(5).toBool());
|
||||
instructor.setLoggedIn(query.value(6).toBool());
|
||||
}
|
||||
}
|
||||
|
||||
return instructor;
|
||||
}
|
||||
|
||||
int DataBaseLMS::selectInstructorID(QString login, QString password)
|
||||
{
|
||||
QString queryStr;
|
||||
|
||||
if(password != QStringLiteral(""))
|
||||
{
|
||||
queryStr = QString("SELECT instructors.instructor_id "
|
||||
"FROM public.instructors "
|
||||
"WHERE login = '%1' AND password = '%2' ").arg(
|
||||
login,
|
||||
password );
|
||||
}
|
||||
else
|
||||
{
|
||||
queryStr = QString("SELECT instructors.instructor_id "
|
||||
"FROM public.instructors "
|
||||
"WHERE login = '%1' ").arg(
|
||||
login );
|
||||
}
|
||||
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
bool DataBaseLMS::selectInstructorIsAdmin(int id_instructor)
|
||||
{
|
||||
QString queryStr = QString("SELECT instructors.is_admin "
|
||||
"FROM public.instructors "
|
||||
"WHERE instructor_id = %1 ").arg(
|
||||
id_instructor );
|
||||
|
||||
QSqlQuery query = QSqlQuery(*db);
|
||||
|
||||
if(!query.exec(queryStr))
|
||||
{
|
||||
messageWarningErrorQuery(queryStr, &query);
|
||||
}
|
||||
else
|
||||
{
|
||||
if(query.next())
|
||||
return query.value(0).toBool();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
bool DataBaseLMS::selectInstructorLoggedIn(int id_instructor)
|
||||
{
|
||||
QString queryStr = QString("SELECT instructors.logged_in "
|
||||
"FROM public.instructors "
|
||||
"WHERE instructor_id = %1 ").arg(
|
||||
id_instructor );
|
||||
|
||||
QSqlQuery query = QSqlQuery(*db);
|
||||
|
||||
if(!query.exec(queryStr))
|
||||
{
|
||||
messageWarningErrorQuery(queryStr, &query);
|
||||
}
|
||||
else
|
||||
{
|
||||
if(query.next())
|
||||
return query.value(0).toBool();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
bool DataBaseLMS::selectInstructorArchived(int id_instructor)
|
||||
{
|
||||
QString queryStr = QString("SELECT instructors.archived "
|
||||
"FROM public.instructors "
|
||||
"WHERE instructor_id = %1 ").arg(
|
||||
id_instructor );
|
||||
|
||||
QSqlQuery query = QSqlQuery(*db);
|
||||
|
||||
if(!query.exec(queryStr))
|
||||
{
|
||||
messageWarningErrorQuery(queryStr, &query);
|
||||
}
|
||||
else
|
||||
{
|
||||
if(query.next())
|
||||
return query.value(0).toBool();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
int DataBaseLMS::updateInstructorLoggedIn(int id_instructor, bool loggedIn)
|
||||
{
|
||||
QString queryStr = QString("UPDATE public.instructors "
|
||||
"SET logged_in = %1 "
|
||||
"WHERE instructor_id = %2 "
|
||||
"RETURNING instructors.instructor_id").arg(
|
||||
loggedIn ? "true" : "false",
|
||||
QString::number(id_instructor) );
|
||||
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
int DataBaseLMS::updateInstructorArchived(int id_instructor, bool archived)
|
||||
{
|
||||
QString queryStr = QString("UPDATE public.instructors "
|
||||
"SET archived = %1 "
|
||||
"WHERE instructor_id = %2 "
|
||||
"RETURNING instructors.instructor_id").arg(
|
||||
archived ? "true" : "false",
|
||||
QString::number(id_instructor) );
|
||||
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
int DataBaseLMS::insertInstructor()
|
||||
{
|
||||
QString queryStr = QString("INSERT INTO public.instructors "
|
||||
"DEFAULT VALUES "
|
||||
"RETURNING instructor_id");
|
||||
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
int DataBaseLMS::insertInstructor(Instructor instructor)
|
||||
{
|
||||
QString queryStr = QString("INSERT INTO public.instructors (name, login, password, is_admin, archived, logged_in) "
|
||||
"VALUES ('%1', '%2', '%3', %4, %5, %6) RETURNING instructor_id").arg(
|
||||
"VALUES ('%1', '%2', '%3', %4, %5, %6) "
|
||||
"RETURNING instructor_id").arg(
|
||||
instructor.getName(),
|
||||
instructor.getLogin(),
|
||||
instructor.getPassword(),
|
||||
@@ -162,21 +344,25 @@ int DataBaseLMS::insertInstructor(Instructor instructor)
|
||||
instructor.getArchived() ? "true" : "false",
|
||||
instructor.getLoggedIn() ? "true" : "false");
|
||||
|
||||
return queryExec(queryStr);
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
int DataBaseLMS::deleteInstructor(int instructor_id)
|
||||
int DataBaseLMS::deleteInstructor(int id_instructor)
|
||||
{
|
||||
QString queryStr = QString("DELETE FROM public.instructors WHERE instructor_id = %1 RETURNING instructors.instructor_id").arg(QString::number(instructor_id));
|
||||
QString queryStr = QString("DELETE FROM public.instructors "
|
||||
"WHERE instructor_id = %1 "
|
||||
"RETURNING instructors.instructor_id").arg(
|
||||
QString::number(id_instructor));
|
||||
|
||||
return queryExec(queryStr);
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
int DataBaseLMS::updateInstructor(Instructor instructor)
|
||||
{
|
||||
QString queryStr = QString("UPDATE public.instructors "
|
||||
"SET name = '%1', login = '%2', password = '%3', is_admin = %4, archived = %5, logged_in = %6 "
|
||||
"WHERE instructor_id = %7 RETURNING instructors.instructor_id").arg(
|
||||
"WHERE instructor_id = %7 "
|
||||
"RETURNING instructors.instructor_id").arg(
|
||||
instructor.getName(),
|
||||
instructor.getLogin(),
|
||||
instructor.getPassword(),
|
||||
@@ -185,38 +371,226 @@ int DataBaseLMS::updateInstructor(Instructor instructor)
|
||||
instructor.getLoggedIn() ? "true" : "false",
|
||||
QString::number(instructor.getID()) );
|
||||
|
||||
return queryExec(queryStr);
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
Group DataBaseLMS::selectGroup(int id_group)
|
||||
{
|
||||
Group group;
|
||||
|
||||
QString queryStr = QString("SELECT group_id, name "
|
||||
"FROM public.groups "
|
||||
"WHERE groups.group_id = %1 ").arg(
|
||||
id_group);
|
||||
|
||||
QSqlQuery query = QSqlQuery(*db);
|
||||
|
||||
if(!query.exec(queryStr))
|
||||
{
|
||||
messageWarningErrorQuery(queryStr, &query);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (query.first())
|
||||
{//Инструктор
|
||||
group.setID(query.value(0).toInt());
|
||||
group.setName(query.value(1).toString());
|
||||
}
|
||||
}
|
||||
|
||||
return group;
|
||||
}
|
||||
|
||||
int DataBaseLMS::insertGroup()
|
||||
{
|
||||
QString queryStr = QString("INSERT INTO public.groups "
|
||||
"DEFAULT VALUES "
|
||||
"RETURNING group_id");
|
||||
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
int DataBaseLMS::insertGroup(Group group)
|
||||
{
|
||||
QString queryStr = QString("INSERT INTO public.groups (name) "
|
||||
"VALUES ('%1') RETURNING groups.group_id").arg(
|
||||
"VALUES ('%1') "
|
||||
"RETURNING groups.group_id").arg(
|
||||
group.getName());
|
||||
|
||||
return queryExec(queryStr);
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
int DataBaseLMS::deleteGroup(int group_id)
|
||||
{
|
||||
QString queryStr = QString("DELETE FROM public.groups WHERE group_id = %1 RETURNING groups.group_id").arg(QString::number(group_id));
|
||||
QString queryStr = QString("DELETE FROM public.groups "
|
||||
"WHERE group_id = %1 "
|
||||
"RETURNING groups.group_id").arg(
|
||||
QString::number(group_id));
|
||||
|
||||
return queryExec(queryStr);
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
int DataBaseLMS::updateGroup(Group group)
|
||||
{
|
||||
QString queryStr = QString("UPDATE public.groups SET name = '%1' WHERE group_id = %2 RETURNING groups.group_id").arg(
|
||||
QString queryStr = QString("UPDATE public.groups SET name = '%1' "
|
||||
"WHERE group_id = %2 "
|
||||
"RETURNING groups.group_id").arg(
|
||||
group.getName(),
|
||||
QString::number(group.getID()) );
|
||||
|
||||
return queryExec(queryStr);
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
Trainee DataBaseLMS::selectTrainee(int id_trainee)
|
||||
{
|
||||
Trainee trainee;
|
||||
|
||||
QString queryStr = QString("SELECT trainees.trainee_id, trainees.name, trainees.login, trainees.password, trainees.archived, trainees.logged_in, "
|
||||
"groups.group_id, groups.name, "
|
||||
"computers.computer_id, computers.name, computers.ip_address, "
|
||||
"classrooms.classroom_id, classrooms.name "
|
||||
"FROM public.trainees JOIN public.groups ON groups.group_id = trainees.group_trainee "
|
||||
"LEFT OUTER JOIN public.computers ON computers.computer_id = trainees.computer_trainee "
|
||||
"LEFT OUTER JOIN public.classrooms ON classrooms.classroom_id = computers.classroom_computer "
|
||||
"WHERE trainees.trainee_id = %1 "
|
||||
"ORDER BY groups.name, trainees.name ASC").arg(
|
||||
id_trainee);
|
||||
|
||||
QSqlQuery query = QSqlQuery(*db);
|
||||
|
||||
if(!query.exec(queryStr))
|
||||
{
|
||||
messageWarningErrorQuery(queryStr, &query);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (query.first())
|
||||
{//Инструктор
|
||||
trainee.setID(query.value(0).toInt());
|
||||
trainee.setName(query.value(1).toString());
|
||||
trainee.setLogin(query.value(2).toString());
|
||||
trainee.setPassword(query.value(3).toString());
|
||||
trainee.setArchived(query.value(4).toBool());
|
||||
trainee.setLoggedIn(query.value(5).toBool());
|
||||
|
||||
Group group = Group(query.value(6).toInt(), query.value(7).toString());
|
||||
trainee.setGroup(group);
|
||||
|
||||
Classroom classroom = Classroom(query.value(11).toInt(), query.value(12).toString());
|
||||
Computer computer = Computer(query.value(8).toInt(), query.value(9).toString(), query.value(10).toString(), classroom);
|
||||
trainee.setComputer(computer);
|
||||
|
||||
trainee.setTasks(selectTasksOfTrainee(trainee.getID()));
|
||||
}
|
||||
}
|
||||
|
||||
return trainee;
|
||||
}
|
||||
|
||||
int DataBaseLMS::selectTraineeID(QString login, QString password)
|
||||
{
|
||||
QString queryStr;
|
||||
|
||||
if(password != QStringLiteral(""))
|
||||
{
|
||||
queryStr = QString("SELECT trainees.trainee_id "
|
||||
"FROM public.trainees "
|
||||
"WHERE login = '%1' AND password = '%2' ").arg(
|
||||
login,
|
||||
password );
|
||||
}
|
||||
else
|
||||
{
|
||||
queryStr = QString("SELECT trainees.trainee_id "
|
||||
"FROM public.trainees "
|
||||
"WHERE login = '%1' ").arg(
|
||||
login );
|
||||
}
|
||||
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
bool DataBaseLMS::selectTraineeArchived(int id_trainee)
|
||||
{
|
||||
QString queryStr = QString("SELECT trainees.archived "
|
||||
"FROM public.trainees "
|
||||
"WHERE trainee_id = %1 ").arg(
|
||||
id_trainee );
|
||||
|
||||
QSqlQuery query = QSqlQuery(*db);
|
||||
|
||||
if(!query.exec(queryStr))
|
||||
{
|
||||
messageWarningErrorQuery(queryStr, &query);
|
||||
}
|
||||
else
|
||||
{
|
||||
if(query.next())
|
||||
return query.value(0).toBool();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
bool DataBaseLMS::selectTraineeLoggedIn(int id_trainee)
|
||||
{
|
||||
QString queryStr = QString("SELECT trainees.logged_in "
|
||||
"FROM public.trainees "
|
||||
"WHERE trainee_id = %1 ").arg(
|
||||
id_trainee );
|
||||
|
||||
QSqlQuery query = QSqlQuery(*db);
|
||||
|
||||
if(!query.exec(queryStr))
|
||||
{
|
||||
messageWarningErrorQuery(queryStr, &query);
|
||||
}
|
||||
else
|
||||
{
|
||||
if(query.next())
|
||||
return query.value(0).toBool();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
int DataBaseLMS::updateTraineeLoggedIn(int id_trainee, bool loggedIn)
|
||||
{
|
||||
QString queryStr = QString("UPDATE public.trainees "
|
||||
"SET logged_in = %1 "
|
||||
"WHERE trainee_id = %2 "
|
||||
"RETURNING trainees.trainee_id").arg(
|
||||
loggedIn ? "true" : "false",
|
||||
QString::number(id_trainee) );
|
||||
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
int DataBaseLMS::updateTraineeArchived(int id_trainee, bool archived)
|
||||
{
|
||||
QString queryStr = QString("UPDATE public.trainees "
|
||||
"SET archived = %1 "
|
||||
"WHERE trainee_id = %2 "
|
||||
"RETURNING trainees.trainee_id").arg(
|
||||
archived ? "true" : "false",
|
||||
QString::number(id_trainee) );
|
||||
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
int DataBaseLMS::insertTrainee(int id_group)
|
||||
{
|
||||
QString queryStr = QString("INSERT INTO public.trainees (name, login, password, archived, logged_in, group_trainee) "
|
||||
"VALUES (DEFAULT, DEFAULT, DEFAULT, DEFAULT, DEFAULT, %1) "
|
||||
"RETURNING trainees.trainee_id").arg(
|
||||
QString::number(id_group));
|
||||
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
int DataBaseLMS::insertTrainee(Trainee trainee)
|
||||
{
|
||||
QString queryStr = QString("INSERT INTO public.trainees (name, login, password, archived, logged_in, group_trainee) "
|
||||
"VALUES ('%1', '%2', '%3', %4, %5, %6) RETURNING trainees.trainee_id").arg(
|
||||
"VALUES ('%1', '%2', '%3', %4, %5, %6) "
|
||||
"RETURNING trainees.trainee_id").arg(
|
||||
trainee.getName(),
|
||||
trainee.getLogin(),
|
||||
trainee.getPassword(),
|
||||
@@ -224,14 +598,17 @@ int DataBaseLMS::insertTrainee(Trainee trainee)
|
||||
trainee.getLoggedIn() ? "true" : "false",
|
||||
QString::number(trainee.getGroup().getID()));
|
||||
|
||||
return queryExec(queryStr);
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
int DataBaseLMS::deleteTrainee(int trainee_id)
|
||||
{
|
||||
QString queryStr = QString("DELETE FROM public.trainees WHERE trainee_id = %1 RETURNING trainees.trainee_id").arg(QString::number(trainee_id));
|
||||
QString queryStr = QString("DELETE FROM public.trainees "
|
||||
"WHERE trainee_id = %1 "
|
||||
"RETURNING trainees.trainee_id").arg(
|
||||
QString::number(trainee_id));
|
||||
|
||||
return queryExec(queryStr);
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
int DataBaseLMS::updateTrainee(Trainee trainee)
|
||||
@@ -242,7 +619,8 @@ int DataBaseLMS::updateTrainee(Trainee trainee)
|
||||
"SET name = '%1', login = '%2', password = '%3', archived = %4, logged_in = %5, "
|
||||
"group_trainee = %6, "
|
||||
"computer_trainee = %7 "
|
||||
"WHERE trainee_id = %8 RETURNING trainees.trainee_id").arg(
|
||||
"WHERE trainee_id = %8 "
|
||||
"RETURNING trainees.trainee_id").arg(
|
||||
trainee.getName(),
|
||||
trainee.getLogin(),
|
||||
trainee.getPassword(),
|
||||
@@ -252,7 +630,7 @@ int DataBaseLMS::updateTrainee(Trainee trainee)
|
||||
computer_id,
|
||||
QString::number(trainee.getID()) );
|
||||
|
||||
return queryExec(queryStr);
|
||||
return queryExecInt(queryStr);
|
||||
}
|
||||
|
||||
QList<Task> DataBaseLMS::selectTasksOfTrainee(int trainee_id)
|
||||
@@ -260,17 +638,18 @@ QList<Task> DataBaseLMS::selectTasksOfTrainee(int trainee_id)
|
||||
QList<Task> tasks;
|
||||
|
||||
QString queryStr = QString("SELECT tasks.task_id, tasks.name "
|
||||
"FROM public.trainees "
|
||||
"JOIN public.trainees_tasks ON trainees_tasks.trainee_id = trainees.trainee_id "
|
||||
"JOIN public.tasks ON tasks.task_id = trainees_tasks.task_id "
|
||||
"WHERE trainees.trainee_id = %1 "
|
||||
"ORDER BY tasks.name ASC").arg(
|
||||
trainee_id);
|
||||
"FROM public.trainees "
|
||||
"JOIN public.trainees_tasks ON trainees_tasks.trainee_id = trainees.trainee_id "
|
||||
"JOIN public.tasks ON tasks.task_id = trainees_tasks.task_id "
|
||||
"WHERE trainees.trainee_id = %1 "
|
||||
"ORDER BY tasks.name ASC").arg(
|
||||
trainee_id);
|
||||
|
||||
QSqlQuery query = QSqlQuery(*db);
|
||||
|
||||
QSqlQuery query(*db);
|
||||
if(!query.exec(queryStr))
|
||||
{
|
||||
messageWarningErrorQuery(queryStr);
|
||||
messageWarningErrorQuery(queryStr, &query);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -286,24 +665,46 @@ QList<Task> DataBaseLMS::selectTasksOfTrainee(int trainee_id)
|
||||
return tasks;
|
||||
}
|
||||
|
||||
int DataBaseLMS::queryExec(QString queryStr)
|
||||
int DataBaseLMS::queryExecInt(QString queryStr)
|
||||
{
|
||||
QSqlQuery query(*db);
|
||||
QSqlQuery query = QSqlQuery(*db);
|
||||
|
||||
if(!query.exec(queryStr))
|
||||
{
|
||||
messageWarningErrorQuery(queryStr);
|
||||
messageWarningErrorQuery(queryStr, &query);
|
||||
return 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
if(query.next())
|
||||
if(query.first())
|
||||
return query.value(0).toInt();
|
||||
else
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
void DataBaseLMS::messageWarningErrorQuery(QString queryStr)
|
||||
/*
|
||||
bool DataBaseLMS::queryExecBool(QString queryStr)
|
||||
{
|
||||
QMessageBox::warning(nullptr, dbName, "Error query: " + queryStr + "\n" + db->lastError().text());
|
||||
QSqlQuery query = QSqlQuery(*db);
|
||||
|
||||
if(!query.exec(queryStr))
|
||||
{
|
||||
messageWarningErrorQuery(queryStr, &query);
|
||||
return 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
if(query.first())
|
||||
return query.value(0).toBool();
|
||||
else
|
||||
return 0;
|
||||
}
|
||||
}*/
|
||||
|
||||
void DataBaseLMS::messageWarningErrorQuery(QString queryStr, QSqlQuery* query)
|
||||
{
|
||||
QMessageBox::warning(nullptr, dbName,
|
||||
"Error query:\n" + query->lastError().text() + "\n" +
|
||||
"String of query:\n" + queryStr + "\n" +
|
||||
"Executed query:\n" + query->executedQuery());
|
||||
}
|
||||
|
||||
@@ -15,22 +15,51 @@ public:
|
||||
DataBaseLMS();
|
||||
~DataBaseLMS();
|
||||
|
||||
public:
|
||||
protected:
|
||||
public:
|
||||
//Подключение
|
||||
bool createConnection();
|
||||
void deleteConnection();
|
||||
|
||||
//Транзакции
|
||||
bool transactionBegin();
|
||||
bool transactionEnd();
|
||||
|
||||
//Списки
|
||||
QList<Instructor> selectAllInstructors();
|
||||
QList<Trainee> selectAllTrainees();
|
||||
QList<Group> selectAllGroups();
|
||||
|
||||
//Инструктор
|
||||
Instructor selectInstructor(int id_instructor);
|
||||
int selectInstructorID(QString login, QString password = QStringLiteral(""));
|
||||
bool selectInstructorIsAdmin(int id_instructor);
|
||||
bool selectInstructorLoggedIn(int id_instructor);
|
||||
bool selectInstructorArchived(int id_instructor);
|
||||
int updateInstructorLoggedIn(int id_instructor, bool loggedIn);
|
||||
int updateInstructorArchived(int id_instructor, bool archived);
|
||||
|
||||
int insertInstructor();
|
||||
int insertInstructor(Instructor instructor);
|
||||
int deleteInstructor(int instructor_id);
|
||||
int deleteInstructor(int id_instructor);
|
||||
int updateInstructor(Instructor instructor);
|
||||
|
||||
//Группа
|
||||
Group selectGroup(int id_group);//
|
||||
int insertGroup();//
|
||||
int insertGroup(Group group);
|
||||
int deleteGroup(int group_id);
|
||||
int updateGroup(Group group);
|
||||
|
||||
//Обучаемый
|
||||
Trainee selectTrainee(int id_trainee);//
|
||||
int selectTraineeID(QString login, QString password = QStringLiteral(""));//
|
||||
bool selectTraineeArchived(int id_trainee);//
|
||||
bool selectTraineeLoggedIn(int id_trainee);//
|
||||
int updateTraineeLoggedIn(int id_trainee, bool loggedIn);//
|
||||
int updateTraineeArchived(int id_trainee, bool archived);//
|
||||
|
||||
int insertTrainee(int id_group);//
|
||||
int insertTrainee(Trainee trainee);
|
||||
int deleteTrainee(int trainee_id);
|
||||
int updateTrainee(Trainee trainee);
|
||||
@@ -38,11 +67,13 @@ public:
|
||||
QList<Task> selectTasksOfTrainee(int trainee_id);
|
||||
|
||||
private:
|
||||
int queryExec(QString queryStr);
|
||||
void messageWarningErrorQuery(QString queryStr);
|
||||
int queryExecInt(QString queryStr);
|
||||
//bool queryExecBool(QString queryStr);
|
||||
void messageWarningErrorQuery(QString queryStr, QSqlQuery* query);
|
||||
|
||||
private:
|
||||
QSqlDatabase* db;
|
||||
bool transactionBegined;
|
||||
const QString dbName = "DataBaseLMS";
|
||||
const QString dbUserName = "postgres";
|
||||
const QString dbPassword = "12345678";
|
||||
|
||||
6
DB_LMS/DataBaseLMS/interfacedatabaselms.cpp
Normal file
6
DB_LMS/DataBaseLMS/interfacedatabaselms.cpp
Normal file
@@ -0,0 +1,6 @@
|
||||
#include "interfacedatabaselms.h"
|
||||
|
||||
InterfaceDataBaseLMS::InterfaceDataBaseLMS()
|
||||
{
|
||||
|
||||
}
|
||||
13
DB_LMS/DataBaseLMS/interfacedatabaselms.h
Normal file
13
DB_LMS/DataBaseLMS/interfacedatabaselms.h
Normal file
@@ -0,0 +1,13 @@
|
||||
#ifndef INTERFACEDATABASELMS_H
|
||||
#define INTERFACEDATABASELMS_H
|
||||
|
||||
#include "DataBaseLMS_global.h"
|
||||
#include "databaselms.h"
|
||||
|
||||
class DATABASELMS_EXPORT InterfaceDataBaseLMS : public DataBaseLMS
|
||||
{
|
||||
public:
|
||||
InterfaceDataBaseLMS();
|
||||
};
|
||||
|
||||
#endif // INTERFACEDATABASELMS_H
|
||||
@@ -41,7 +41,7 @@
|
||||
{
|
||||
"directoryIndex" : 0,
|
||||
"id" : "DataBaseLMS::@6890427a1f51a3e7e1df",
|
||||
"jsonFile" : "target-DataBaseLMS-Debug-788469329fca20560302.json",
|
||||
"jsonFile" : "target-DataBaseLMS-Debug-5eb45d4d55eb23675b98.json",
|
||||
"name" : "DataBaseLMS",
|
||||
"projectIndex" : 0
|
||||
},
|
||||
@@ -26,7 +26,7 @@
|
||||
"objects" :
|
||||
[
|
||||
{
|
||||
"jsonFile" : "codemodel-v2-75aa5940d6c94493455f.json",
|
||||
"jsonFile" : "codemodel-v2-4c4ecc1a053153a57cf7.json",
|
||||
"kind" : "codemodel",
|
||||
"version" :
|
||||
{
|
||||
@@ -77,7 +77,7 @@
|
||||
},
|
||||
"codemodel-v2" :
|
||||
{
|
||||
"jsonFile" : "codemodel-v2-75aa5940d6c94493455f.json",
|
||||
"jsonFile" : "codemodel-v2-4c4ecc1a053153a57cf7.json",
|
||||
"kind" : "codemodel",
|
||||
"version" :
|
||||
{
|
||||
@@ -43,13 +43,13 @@
|
||||
{
|
||||
"command" : 1,
|
||||
"file" : 0,
|
||||
"line" : 37,
|
||||
"line" : 39,
|
||||
"parent" : 0
|
||||
},
|
||||
{
|
||||
"command" : 1,
|
||||
"file" : 0,
|
||||
"line" : 38,
|
||||
"line" : 40,
|
||||
"parent" : 0
|
||||
},
|
||||
{
|
||||
@@ -87,7 +87,7 @@
|
||||
{
|
||||
"command" : 5,
|
||||
"file" : 0,
|
||||
"line" : 40,
|
||||
"line" : 42,
|
||||
"parent" : 0
|
||||
}
|
||||
]
|
||||
@@ -195,7 +195,8 @@
|
||||
12,
|
||||
14,
|
||||
16,
|
||||
18
|
||||
18,
|
||||
20
|
||||
]
|
||||
}
|
||||
],
|
||||
@@ -264,7 +265,8 @@
|
||||
12,
|
||||
14,
|
||||
16,
|
||||
18
|
||||
18,
|
||||
20
|
||||
]
|
||||
},
|
||||
{
|
||||
@@ -280,7 +282,8 @@
|
||||
13,
|
||||
15,
|
||||
17,
|
||||
19
|
||||
19,
|
||||
21
|
||||
]
|
||||
}
|
||||
],
|
||||
@@ -309,6 +312,17 @@
|
||||
"path" : "databaselms.h",
|
||||
"sourceGroupIndex" : 1
|
||||
},
|
||||
{
|
||||
"backtrace" : 1,
|
||||
"compileGroupIndex" : 0,
|
||||
"path" : "interfacedatabaselms.cpp",
|
||||
"sourceGroupIndex" : 0
|
||||
},
|
||||
{
|
||||
"backtrace" : 1,
|
||||
"path" : "interfacedatabaselms.h",
|
||||
"sourceGroupIndex" : 1
|
||||
},
|
||||
{
|
||||
"backtrace" : 1,
|
||||
"compileGroupIndex" : 0,
|
||||
Binary file not shown.
@@ -1,81 +1,43 @@
|
||||
# ninja log v5
|
||||
11 35 0 CMakeFiles/clean.additional 7155004b3956b606
|
||||
2059 2218 7525088392927135 libDataBaseLMS.dll 3b716bd5e0562557
|
||||
2059 2218 7525088392927135 libDataBaseLMS.dll.a 3b716bd5e0562557
|
||||
35 42 0 clean 9c4b4372737ab8da
|
||||
95 1643 7524982876371819 CMakeFiles/DataBaseLMS.dir/computer.cpp.obj 5930684a0b27a14f
|
||||
14 49 0 D:/LMS/DB_LMS/Debug64/DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
83 1635 7524982876272093 CMakeFiles/DataBaseLMS.dir/basicentity.cpp.obj 99b734c728959a94
|
||||
88 1636 7524982876292025 CMakeFiles/DataBaseLMS.dir/instructor.cpp.obj fb68571e9d220198
|
||||
97 1633 7524982876272093 CMakeFiles/DataBaseLMS.dir/task.cpp.obj b003a0cb68c6b2bb
|
||||
92 1636 7524982876292025 CMakeFiles/DataBaseLMS.dir/group.cpp.obj 70fefc8893e4cb77
|
||||
156 788 7524397271272665 CMakeFiles/DataBaseLMS.dir/DataBaseLMS_autogen/mocs_compilation.cpp.obj d9dc0a262f9d4ccd
|
||||
50 2059 7525088391343479 CMakeFiles/DataBaseLMS.dir/databaselms.cpp.obj 202016fcb2dffc59
|
||||
90 1752 7524982877478794 CMakeFiles/DataBaseLMS.dir/trainee.cpp.obj 4ac35fd8ef58e9f
|
||||
100 1640 7524982876341892 CMakeFiles/DataBaseLMS.dir/classroom.cpp.obj e9b501dc7cb3286a
|
||||
14 49 0 DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
14 49 0 CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
85 1635 7524982876282051 CMakeFiles/DataBaseLMS.dir/user.cpp.obj 4ee7a17d2a43f188
|
||||
14 49 0 D:/LMS/DB_LMS/Debug64/CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
90 131 7525981640473406 CMakeFiles/DataBaseLMS.dir/DataBaseLMS_autogen/mocs_compilation.cpp.obj d9dc0a262f9d4ccd
|
||||
54 113 0 D:/LMS/DB_LMS/Debug64/CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
97 657 7525981645725604 CMakeFiles/DataBaseLMS.dir/user.cpp.obj 4ee7a17d2a43f188
|
||||
54 113 0 CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
108 693 7525981646098521 CMakeFiles/DataBaseLMS.dir/computer.cpp.obj 5930684a0b27a14f
|
||||
105 653 7525981645685710 CMakeFiles/DataBaseLMS.dir/group.cpp.obj 70fefc8893e4cb77
|
||||
7 31 0 CMakeFiles/clean.additional 7155004b3956b606
|
||||
2048 2211 7531044009955548 libDataBaseLMS.dll 3b716bd5e0562557
|
||||
2048 2211 7531044009955548 libDataBaseLMS.dll.a 3b716bd5e0562557
|
||||
31 38 0 clean 9c4b4372737ab8da
|
||||
52 2047 7531044008328505 CMakeFiles/DataBaseLMS.dir/databaselms.cpp.obj 202016fcb2dffc59
|
||||
95 655 7525981645705675 CMakeFiles/DataBaseLMS.dir/basicentity.cpp.obj 99b734c728959a94
|
||||
54 113 0 D:/LMS/DB_LMS/Debug64/DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
100 738 7525981646532033 CMakeFiles/DataBaseLMS.dir/instructor.cpp.obj fb68571e9d220198
|
||||
110 683 7525981645966249 CMakeFiles/DataBaseLMS.dir/task.cpp.obj b003a0cb68c6b2bb
|
||||
54 113 0 DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
113 607 7525981645223557 CMakeFiles/DataBaseLMS.dir/classroom.cpp.obj e9b501dc7cb3286a
|
||||
102 767 7525981646832047 CMakeFiles/DataBaseLMS.dir/trainee.cpp.obj 4ac35fd8ef58e9f
|
||||
16 56 0 CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
16 56 0 DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
16 56 0 D:/LMS/DB_LMS/Debug64/CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
16 56 0 D:/LMS/DB_LMS/Debug64/DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
59 1069 7531836962549807 CMakeFiles/DataBaseLMS.dir/interfacedatabaselms.cpp.obj d76eac97fda56f5b
|
||||
56 2141 7531836973258075 CMakeFiles/DataBaseLMS.dir/databaselms.cpp.obj 202016fcb2dffc59
|
||||
2141 2512 7531836976956111 libDataBaseLMS.dll 31a19f1f3436f66b
|
||||
2141 2512 7531836976956111 libDataBaseLMS.dll.a 31a19f1f3436f66b
|
||||
16 53 0 CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
16 53 0 DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
16 53 0 D:/LMS/DB_LMS/Debug64/CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
16 53 0 D:/LMS/DB_LMS/Debug64/DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
53 2060 7525091330946435 CMakeFiles/DataBaseLMS.dir/databaselms.cpp.obj 202016fcb2dffc59
|
||||
2060 2220 7525091332543436 libDataBaseLMS.dll 3b716bd5e0562557
|
||||
2060 2220 7525091332543436 libDataBaseLMS.dll.a 3b716bd5e0562557
|
||||
15 51 0 CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
15 51 0 DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
15 51 0 D:/LMS/DB_LMS/Debug64/CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
15 51 0 D:/LMS/DB_LMS/Debug64/DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
51 2037 7525100271403312 CMakeFiles/DataBaseLMS.dir/databaselms.cpp.obj 202016fcb2dffc59
|
||||
2037 2197 7525100272988261 libDataBaseLMS.dll 3b716bd5e0562557
|
||||
2037 2197 7525100272988261 libDataBaseLMS.dll.a 3b716bd5e0562557
|
||||
15 49 0 CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
15 49 0 DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
15 49 0 D:/LMS/DB_LMS/Debug64/CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
15 49 0 D:/LMS/DB_LMS/Debug64/DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
10 42 0 CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
10 42 0 DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
10 42 0 D:/LMS/DB_LMS/Debug64/CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
10 42 0 D:/LMS/DB_LMS/Debug64/DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
43 1971 7525212838352129 CMakeFiles/DataBaseLMS.dir/databaselms.cpp.obj 202016fcb2dffc59
|
||||
1971 2129 7525212839934527 libDataBaseLMS.dll 3b716bd5e0562557
|
||||
1971 2129 7525212839934527 libDataBaseLMS.dll.a 3b716bd5e0562557
|
||||
15 50 0 CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
15 50 0 DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
15 50 0 D:/LMS/DB_LMS/Debug64/CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
15 50 0 D:/LMS/DB_LMS/Debug64/DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
50 1981 7525216791870122 CMakeFiles/DataBaseLMS.dir/databaselms.cpp.obj 202016fcb2dffc59
|
||||
1981 2140 7525216793455149 libDataBaseLMS.dll 3b716bd5e0562557
|
||||
1981 2140 7525216793455149 libDataBaseLMS.dll.a 3b716bd5e0562557
|
||||
14 48 0 CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
14 48 0 DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
14 48 0 D:/LMS/DB_LMS/Debug64/CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
14 48 0 D:/LMS/DB_LMS/Debug64/DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
25 67 0 CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
25 67 0 DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
25 67 0 D:/LMS/DB_LMS/Debug64/CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
25 67 0 D:/LMS/DB_LMS/Debug64/DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
24 74 0 CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
24 74 0 DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
24 74 0 D:/LMS/DB_LMS/Debug64/CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
24 74 0 D:/LMS/DB_LMS/Debug64/DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
7 31 0 CMakeFiles/clean.additional 7155004b3956b606
|
||||
31 38 0 clean 9c4b4372737ab8da
|
||||
11 90 0 CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
11 90 0 DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
11 90 0 D:/LMS/DB_LMS/Debug64/CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
11 90 0 D:/LMS/DB_LMS/Debug64/DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
90 131 7525981640473406 CMakeFiles/DataBaseLMS.dir/DataBaseLMS_autogen/mocs_compilation.cpp.obj d9dc0a262f9d4ccd
|
||||
113 607 7525981645223557 CMakeFiles/DataBaseLMS.dir/classroom.cpp.obj e9b501dc7cb3286a
|
||||
105 653 7525981645685710 CMakeFiles/DataBaseLMS.dir/group.cpp.obj 70fefc8893e4cb77
|
||||
95 655 7525981645705675 CMakeFiles/DataBaseLMS.dir/basicentity.cpp.obj 99b734c728959a94
|
||||
97 657 7525981645725604 CMakeFiles/DataBaseLMS.dir/user.cpp.obj 4ee7a17d2a43f188
|
||||
110 683 7525981645966249 CMakeFiles/DataBaseLMS.dir/task.cpp.obj b003a0cb68c6b2bb
|
||||
108 693 7525981646098521 CMakeFiles/DataBaseLMS.dir/computer.cpp.obj 5930684a0b27a14f
|
||||
100 738 7525981646532033 CMakeFiles/DataBaseLMS.dir/instructor.cpp.obj fb68571e9d220198
|
||||
102 767 7525981646832047 CMakeFiles/DataBaseLMS.dir/trainee.cpp.obj 4ac35fd8ef58e9f
|
||||
93 2171 7525981660831212 CMakeFiles/DataBaseLMS.dir/databaselms.cpp.obj 202016fcb2dffc59
|
||||
2171 2342 7525981662561308 libDataBaseLMS.dll 3b716bd5e0562557
|
||||
2171 2342 7525981662561308 libDataBaseLMS.dll.a 3b716bd5e0562557
|
||||
56 598 7531839242498807 CMakeFiles/DataBaseLMS.dir/interfacedatabaselms.cpp.obj d76eac97fda56f5b
|
||||
53 2026 7531839256769605 CMakeFiles/DataBaseLMS.dir/databaselms.cpp.obj 202016fcb2dffc59
|
||||
2026 2210 7531839258594933 libDataBaseLMS.dll 31a19f1f3436f66b
|
||||
2026 2210 7531839258594933 libDataBaseLMS.dll.a 31a19f1f3436f66b
|
||||
15 52 0 CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
15 52 0 DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
15 52 0 D:/LMS/DB_LMS/Debug64/CMakeFiles/DataBaseLMS_autogen b8e538c54fdbce20
|
||||
15 52 0 D:/LMS/DB_LMS/Debug64/DataBaseLMS_autogen/mocs_compilation.cpp b8e538c54fdbce20
|
||||
55 606 7531839486381107 CMakeFiles/DataBaseLMS.dir/interfacedatabaselms.cpp.obj d76eac97fda56f5b
|
||||
52 2049 7531839500798537 CMakeFiles/DataBaseLMS.dir/databaselms.cpp.obj 202016fcb2dffc59
|
||||
2049 2220 7531839502500362 libDataBaseLMS.dll 31a19f1f3436f66b
|
||||
2049 2220 7531839502500362 libDataBaseLMS.dll.a 31a19f1f3436f66b
|
||||
|
||||
Binary file not shown.
Binary file not shown.
@@ -123,6 +123,12 @@
|
||||
"EWIEGA46WW/moc_instructor.cpp",
|
||||
null
|
||||
],
|
||||
[
|
||||
"D:/LMS/DB_LMS/DataBaseLMS/interfacedatabaselms.h",
|
||||
"MU",
|
||||
"EWIEGA46WW/moc_interfacedatabaselms.cpp",
|
||||
null
|
||||
],
|
||||
[
|
||||
"D:/LMS/DB_LMS/DataBaseLMS/task.h",
|
||||
"MU",
|
||||
@@ -210,6 +216,7 @@
|
||||
[ "D:/LMS/DB_LMS/DataBaseLMS/databaselms.cpp", "MU", null ],
|
||||
[ "D:/LMS/DB_LMS/DataBaseLMS/group.cpp", "MU", null ],
|
||||
[ "D:/LMS/DB_LMS/DataBaseLMS/instructor.cpp", "MU", null ],
|
||||
[ "D:/LMS/DB_LMS/DataBaseLMS/interfacedatabaselms.cpp", "MU", null ],
|
||||
[ "D:/LMS/DB_LMS/DataBaseLMS/task.cpp", "MU", null ],
|
||||
[ "D:/LMS/DB_LMS/DataBaseLMS/trainee.cpp", "MU", null ],
|
||||
[ "D:/LMS/DB_LMS/DataBaseLMS/user.cpp", "MU", null ]
|
||||
|
||||
@@ -1,20 +1,22 @@
|
||||
# Generated by CMake. Changes will be overwritten.
|
||||
D:/LMS/DB_LMS/DataBaseLMS/user.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/trainee.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/task.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/group.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/databaselms.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/DataBaseLMS_global.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/user.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/instructor.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/classroom.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/basicentity.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/computer.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/computer.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/databaselms.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/group.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/instructor.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/trainee.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/basicentity.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/task.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/classroom.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/databaselms.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/databaselms.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/DataBaseLMS_global.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/group.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/user.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/group.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/task.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/interfacedatabaselms.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/instructor.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/user.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/trainee.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/interfacedatabaselms.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/computer.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/basicentity.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/basicentity.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/trainee.cpp
|
||||
D:/LMS/DB_LMS/DataBaseLMS/computer.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/classroom.h
|
||||
D:/LMS/DB_LMS/DataBaseLMS/instructor.cpp
|
||||
|
||||
@@ -159,6 +159,12 @@
|
||||
<Unit filename="D:/LMS/DB_LMS/DataBaseLMS/instructor.h">
|
||||
<Option target="DataBaseLMS"/>
|
||||
</Unit>
|
||||
<Unit filename="D:/LMS/DB_LMS/DataBaseLMS/interfacedatabaselms.cpp">
|
||||
<Option target="DataBaseLMS"/>
|
||||
</Unit>
|
||||
<Unit filename="D:/LMS/DB_LMS/DataBaseLMS/interfacedatabaselms.h">
|
||||
<Option target="DataBaseLMS"/>
|
||||
</Unit>
|
||||
<Unit filename="D:/LMS/DB_LMS/DataBaseLMS/task.cpp">
|
||||
<Option target="DataBaseLMS"/>
|
||||
</Unit>
|
||||
|
||||
@@ -65,6 +65,14 @@ build CMakeFiles/DataBaseLMS.dir/databaselms.cpp.obj: CXX_COMPILER__DataBaseLMS_
|
||||
OBJECT_DIR = CMakeFiles\DataBaseLMS.dir
|
||||
OBJECT_FILE_DIR = CMakeFiles\DataBaseLMS.dir
|
||||
|
||||
build CMakeFiles/DataBaseLMS.dir/interfacedatabaselms.cpp.obj: CXX_COMPILER__DataBaseLMS_unscanned_Debug D$:/LMS/DB_LMS/DataBaseLMS/interfacedatabaselms.cpp || cmake_object_order_depends_target_DataBaseLMS
|
||||
DEFINES = -DDATABASELMS_LIBRARY -DDataBaseLMS_EXPORTS -DQT_CORE_LIB -DQT_GUI_LIB -DQT_SQL_LIB -DQT_WIDGETS_LIB
|
||||
DEP_FILE = CMakeFiles\DataBaseLMS.dir\interfacedatabaselms.cpp.obj.d
|
||||
FLAGS = -g -std=gnu++11
|
||||
INCLUDES = -ID:/LMS/DB_LMS/Debug64 -ID:/LMS/DB_LMS/DataBaseLMS -ID:/LMS/DB_LMS/Debug64/DataBaseLMS_autogen/include -isystem C:/Qt/Qt5.14.2/5.14.2/mingw73_64/include -isystem C:/Qt/Qt5.14.2/5.14.2/mingw73_64/include/QtWidgets -isystem C:/Qt/Qt5.14.2/5.14.2/mingw73_64/include/QtGui -isystem C:/Qt/Qt5.14.2/5.14.2/mingw73_64/include/QtANGLE -isystem C:/Qt/Qt5.14.2/5.14.2/mingw73_64/include/QtCore -isystem C:/Qt/Qt5.14.2/5.14.2/mingw73_64/./mkspecs/win32-g++ -isystem C:/Qt/Qt5.14.2/5.14.2/mingw73_64/include/QtSql
|
||||
OBJECT_DIR = CMakeFiles\DataBaseLMS.dir
|
||||
OBJECT_FILE_DIR = CMakeFiles\DataBaseLMS.dir
|
||||
|
||||
build CMakeFiles/DataBaseLMS.dir/basicentity.cpp.obj: CXX_COMPILER__DataBaseLMS_unscanned_Debug D$:/LMS/DB_LMS/DataBaseLMS/basicentity.cpp || cmake_object_order_depends_target_DataBaseLMS
|
||||
DEFINES = -DDATABASELMS_LIBRARY -DDataBaseLMS_EXPORTS -DQT_CORE_LIB -DQT_GUI_LIB -DQT_SQL_LIB -DQT_WIDGETS_LIB
|
||||
DEP_FILE = CMakeFiles\DataBaseLMS.dir\basicentity.cpp.obj.d
|
||||
@@ -137,7 +145,7 @@ build CMakeFiles/DataBaseLMS.dir/classroom.cpp.obj: CXX_COMPILER__DataBaseLMS_un
|
||||
#############################################
|
||||
# Link the shared library libDataBaseLMS.dll
|
||||
|
||||
build libDataBaseLMS.dll libDataBaseLMS.dll.a: CXX_SHARED_LIBRARY_LINKER__DataBaseLMS_Debug CMakeFiles/DataBaseLMS.dir/DataBaseLMS_autogen/mocs_compilation.cpp.obj CMakeFiles/DataBaseLMS.dir/databaselms.cpp.obj CMakeFiles/DataBaseLMS.dir/basicentity.cpp.obj CMakeFiles/DataBaseLMS.dir/user.cpp.obj CMakeFiles/DataBaseLMS.dir/instructor.cpp.obj CMakeFiles/DataBaseLMS.dir/trainee.cpp.obj CMakeFiles/DataBaseLMS.dir/group.cpp.obj CMakeFiles/DataBaseLMS.dir/computer.cpp.obj CMakeFiles/DataBaseLMS.dir/task.cpp.obj CMakeFiles/DataBaseLMS.dir/classroom.cpp.obj | C$:/Qt/Qt5.14.2/5.14.2/mingw73_64/lib/libQt5Widgets.a C$:/Qt/Qt5.14.2/5.14.2/mingw73_64/lib/libQt5Sql.a C$:/Qt/Qt5.14.2/5.14.2/mingw73_64/lib/libQt5Gui.a C$:/Qt/Qt5.14.2/5.14.2/mingw73_64/lib/libQt5Core.a || DataBaseLMS_autogen
|
||||
build libDataBaseLMS.dll libDataBaseLMS.dll.a: CXX_SHARED_LIBRARY_LINKER__DataBaseLMS_Debug CMakeFiles/DataBaseLMS.dir/DataBaseLMS_autogen/mocs_compilation.cpp.obj CMakeFiles/DataBaseLMS.dir/databaselms.cpp.obj CMakeFiles/DataBaseLMS.dir/interfacedatabaselms.cpp.obj CMakeFiles/DataBaseLMS.dir/basicentity.cpp.obj CMakeFiles/DataBaseLMS.dir/user.cpp.obj CMakeFiles/DataBaseLMS.dir/instructor.cpp.obj CMakeFiles/DataBaseLMS.dir/trainee.cpp.obj CMakeFiles/DataBaseLMS.dir/group.cpp.obj CMakeFiles/DataBaseLMS.dir/computer.cpp.obj CMakeFiles/DataBaseLMS.dir/task.cpp.obj CMakeFiles/DataBaseLMS.dir/classroom.cpp.obj | C$:/Qt/Qt5.14.2/5.14.2/mingw73_64/lib/libQt5Widgets.a C$:/Qt/Qt5.14.2/5.14.2/mingw73_64/lib/libQt5Sql.a C$:/Qt/Qt5.14.2/5.14.2/mingw73_64/lib/libQt5Gui.a C$:/Qt/Qt5.14.2/5.14.2/mingw73_64/lib/libQt5Core.a || DataBaseLMS_autogen
|
||||
LANGUAGE_COMPILE_FLAGS = -g
|
||||
LINK_LIBRARIES = C:/Qt/Qt5.14.2/5.14.2/mingw73_64/lib/libQt5Widgets.a C:/Qt/Qt5.14.2/5.14.2/mingw73_64/lib/libQt5Sql.a C:/Qt/Qt5.14.2/5.14.2/mingw73_64/lib/libQt5Gui.a C:/Qt/Qt5.14.2/5.14.2/mingw73_64/lib/libQt5Core.a -lkernel32 -luser32 -lgdi32 -lwinspool -lshell32 -lole32 -loleaut32 -luuid -lcomdlg32 -ladvapi32
|
||||
OBJECT_DIR = CMakeFiles\DataBaseLMS.dir
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user