mirror of
https://gitea.msk.dinamika-avia.ru/Constanta-Design/RRJServer.git
synced 2026-03-27 19:45:43 +03:00
Оптимизировал CommonView
This commit is contained in:
@@ -112,7 +112,7 @@ void EditorInstructors::on_btnDeleteInstructor_clicked()
|
||||
if(treeItemParent == nullptr)
|
||||
{//Выбран Инструктор
|
||||
|
||||
int id = treeItemCurrent->text(ColumnsTreeInsructors::clmn_ID).toInt();
|
||||
int id = treeItemCurrent->text(ColumnsTreeUsers::clmn_ID).toInt();
|
||||
|
||||
if(connectorToServer->isAdminInstructor(id))
|
||||
{//Это Админ!
|
||||
@@ -145,7 +145,7 @@ void EditorInstructors::on_btnToOrFromArchive_clicked()
|
||||
if(treeItemParent == nullptr)
|
||||
{//Выбран Инструктор
|
||||
|
||||
int id = treeItemCurrent->text(ColumnsTreeInsructors::clmn_ID).toInt();
|
||||
int id = treeItemCurrent->text(ColumnsTreeUsers::clmn_ID).toInt();
|
||||
|
||||
Instructor instructor = connectorToServer->getInstructor(id);
|
||||
if(instructor.getID() == 0)
|
||||
@@ -194,7 +194,7 @@ void EditorInstructors::on_btnEdit_clicked()
|
||||
if(treeItemParent == nullptr)
|
||||
{//Выбран Инструктор
|
||||
|
||||
int id = treeItemCurrent->text(ColumnsTreeInsructors::clmn_ID).toInt();
|
||||
int id = treeItemCurrent->text(ColumnsTreeUsers::clmn_ID).toInt();
|
||||
|
||||
if(connectorToServer->isLoggedInInstructor(id))
|
||||
{//Инструктор залогирован!
|
||||
@@ -252,7 +252,7 @@ void EditorInstructors::on_treeWidgetCurrentItemChanged(QTreeWidgetItem *current
|
||||
if(treeItemParent == nullptr)
|
||||
{//Выбран инструктор
|
||||
|
||||
int id = current->text(ColumnsTreeInsructors::clmn_ID).toInt();
|
||||
int id = current->text(ColumnsTreeUsers::clmn_ID).toInt();
|
||||
|
||||
lastCurrentID = id;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user