1 #ifndef __vvQPacsConnection_h_INCLUDED__
2 #define __vvQPacsConnection_h_INCLUDED__
4 #include <QTGUI/QWidget>
5 #include "ui_vvPacsConnection.h"
6 #include "gdcmCompositeNetworkFunctions.h"
7 #include <QtGui/QStandardItemModel.h>
8 #include <QtGui/QStringListModel.h>
10 #include "vvDicomServerQueryFactory.h"
15 //=====================================================================
16 //======================================================================
19 gdcm::ERootType theRoot;
20 gdcm::EQueryLevel theLevel;
21 std::vector< std::pair<gdcm::Tag, std::string> > keys;
24 class vvQPacsConnection : public QDialog
28 //vvQPacsConnection(){}
29 vvQPacsConnection(QWidget *parent=0);
31 ~vvQPacsConnection(){}
32 void refreshNetworks();
33 std::vector <std::string> getFileNames();
36 void selectStudies(const QModelIndex &index);
37 void selectSeries(const QModelIndex &index);
38 void selectImages(const QModelIndex &index);
40 void on_scanButton_clicked();
41 void on_clearButton_clicked();
42 void on_optionsButton_clicked();
43 void on_check_ModAll_clicked(bool state);
44 void on_importButton_clicked();
45 void chooseServer(int index);
51 vvQuery getQueryPatient(const std::string i_patname, const std::string i_patid);
54 Ui::vvPacsConnection ui;
55 std::vector< std::pair<gdcm::Tag, std::string> > getKeys();
56 std::vector< std::pair<gdcm::Tag, std::string> > getPatientKeys(const std::string , const std::string );
57 std::vector< std::pair<gdcm::Tag, std::string> > getStudyKeys(const std::string);
58 std::vector< std::pair<gdcm::Tag, std::string> > getSeriesKeys(const std::string i_val);
59 std::vector< std::pair<gdcm::Tag, std::string> > getImageKeys(const std::string i_val);
60 void manageStudiesFilter(bool i_enable);
61 void createTreeView();
64 QStandardItemModel *Patientmodel;
65 QStandardItemModel *Studymodel;
66 QStandardItemModel *Seriesmodel;
67 QStandardItemModel *Imagesmodel;
68 void convertDataSet(std::vector<gdcm::DataSet> i_ds, QStandardItemModel *i_model, std::vector< std::pair<gdcm::Tag, std::string> > keys);
69 void manageSeriesFilter(bool i_enable);
70 std::vector< std::pair<gdcm::Tag, std::string> > fillMoveKeys();
71 std::string m_patient;
74 gdcm::EQueryLevel m_level;
76 std::string m_aetitle;
78 std::string m_nickname;
79 vvDicomServerQueryFactory mquery;
82 gdcm::Directory::FilenamesType m_files;
84 vvQuery getQueryforSeries(const std::string study_id);
86 vvQuery getQueryforStudy(const std::string patient_id);
87 std::vector< std::pair<gdcm::Tag, std::string> > getQueryKeysforStudy(const std::string patient_id);
89 }; // class vvQPacsConnection
90 //=====================================================================
94 #endif // __vvQPacsConnection_h_INCLUDED__