Начал реализовывать обмен запросами к БД

This commit is contained in:
krivoshein
2024-12-06 11:15:02 +03:00
parent 53b37240eb
commit 2f48cf3921
107 changed files with 938 additions and 1189 deletions

View File

@@ -2,8 +2,8 @@
#include <QTranslator>
#include "instructorsview.h"
InstructorsView::InstructorsView(InterfaceDataBaseLMS* dbLMS, TypeView type, QWidget *parent):
CommonView(dbLMS, type, parent)
InstructorsView::InstructorsView(ConnectorToServer* connectorToServer, TypeView type, QWidget *parent):
CommonView(connectorToServer, type, parent)
{
}
@@ -99,15 +99,14 @@ void InstructorsView::loadInstructorsFromDB()
//Обновление дерева
treeWidget->clear();
if(!dbLMS->DBisConnected())
{
mtxTreeWidget.unlock();
return;
}
//Инструкторы
QList<Instructor> listInstructors;
listInstructors = dbLMS->getListInstructors();
//TODO
//listInstructors = dbLMS->getListInstructors();
//sendSystem->getListInstructors();
listInstructors = connectorToServer->getListInstructors();
for(Instructor instructor : listInstructors)
{
QTreeWidgetItem *ItemInstructor = new QTreeWidgetItem(treeWidget);