-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmainwindow.h
More file actions
107 lines (69 loc) · 2.26 KB
/
mainwindow.h
File metadata and controls
107 lines (69 loc) · 2.26 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
#ifndef MAINWINDOW_H
#define MAINWINDOW_H
#include <QMainWindow>
#include <QMessageBox>
#include "dbmanager.h"
QT_BEGIN_NAMESPACE
namespace Ui { class MainWindow; }
QT_END_NAMESPACE
class MainWindow : public QMainWindow
{
Q_OBJECT
public:
MainWindow(QWidget *parent = nullptr);
~MainWindow();
private slots:
void on_but_deleteFaculty_clicked();
void on_cBox_faculties_currentIndexChanged(int index);
void on_but_addFaculty_clicked();
void on_but_addGroup_clicked();
void on_but_deleteGroup_clicked();
void on_but_addStud_clicked();
void on_but_deleteStud_clicked();
void on_tbView_students_doubleClicked(const QModelIndex &index);
void on_cBox_subject_tab4_currentIndexChanged(int index);
void on_but_addGrade_clicked();
void on_but_deleteGrade_clicked();
void on_but_addSubject_clicked();
void on_but_deleteSubject_clicked();
void on_but_addTeacher_clicked();
void on_but_deleteTeacher_clicked();
void on_cBox_group_tab5_currentIndexChanged(int index);
void on_cBox_subs_tab5_2_currentIndexChanged(int index);
void on_cBox_teacher_tab5_currentIndexChanged(int index);
void on_but_attachSubToGroup_clicked();
void on_but_deattachSubToGroup_clicked();
void on_but_attachSubAndTeacher_clicked();
void on_but_deattachTeacherFromSub_clicked();
void on_but_deattachSubFromTeacher_clicked();
private:
Ui::MainWindow *ui;
void initModels();
DBManager* db;
UtilFaculty* util;
QList<Faculty*> faculties;
FacultyListModel* fac_model;
FacultyGroupModel* fac_gr_model;
QList<Group*> groups;
GroupListModel* group_model;
QList<Teacher*> teachers;
TeacherListModel* teach_model;
QList<Subject*> subjects;
SubjectListModel* sub_model;
QList<QString> check_types;
QList<Student*> students;
StudentFilterModel* stud_filter_model;
StudTableModel* stud_model;
QList<Grade*> grades;
//tab4 models
Student* curr_stud;
GradeTableModel* grade_model;
SubjectListModel* subs_t4_model;
TeacherListModel* teachers_t4_model;
//tab5 models
SubjectListModel* subs_t5_model_1;
SubjectListModel* subs_t5_model_2;
TeacherListModel* teachers_t5_model;
void tab4_init();
};
#endif // MAINWINDOW_H