feat: Changes study Query column header and detail, add some miss translate
This commit is contained in:
@@ -12,9 +12,10 @@ struct PACSStudyInfo {
|
|||||||
QString patientSex;
|
QString patientSex;
|
||||||
QString patientAge;
|
QString patientAge;
|
||||||
QString studyInstanceUID;
|
QString studyInstanceUID;
|
||||||
QString studyID;
|
QString studyDescription;
|
||||||
QString requestingPhysician;
|
QString modality;
|
||||||
QString relatedInstanceNumber;
|
QString relatedInstanceNumber;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
struct PACSSeriesInfo {
|
struct PACSSeriesInfo {
|
||||||
|
|||||||
@@ -230,7 +230,7 @@ void QueryWorker::onFoundResult(int index, DcmDataset *response)
|
|||||||
{
|
{
|
||||||
std::string studyDate_, patientName_, patientID_, accessionNumber_,
|
std::string studyDate_, patientName_, patientID_, accessionNumber_,
|
||||||
patientBirthDate_, patientSex_, studyInstanceUID_,
|
patientBirthDate_, patientSex_, studyInstanceUID_,
|
||||||
studyID_, requestingPhysician_, seriesUid_, modality_, seriesNumber_,
|
studyDescription_, modality_, seriesUid_, seriesNumber_,
|
||||||
instanceNumber_;
|
instanceNumber_;
|
||||||
response->findAndGetOFString(DCM_StudyDate, studyDate_);
|
response->findAndGetOFString(DCM_StudyDate, studyDate_);
|
||||||
response->findAndGetOFString(DCM_PatientName, patientName_);
|
response->findAndGetOFString(DCM_PatientName, patientName_);
|
||||||
@@ -239,10 +239,9 @@ void QueryWorker::onFoundResult(int index, DcmDataset *response)
|
|||||||
response->findAndGetOFString(DCM_PatientBirthDate, patientBirthDate_);
|
response->findAndGetOFString(DCM_PatientBirthDate, patientBirthDate_);
|
||||||
response->findAndGetOFString(DCM_PatientSex, patientSex_);
|
response->findAndGetOFString(DCM_PatientSex, patientSex_);
|
||||||
response->findAndGetOFString(DCM_StudyInstanceUID, studyInstanceUID_);
|
response->findAndGetOFString(DCM_StudyInstanceUID, studyInstanceUID_);
|
||||||
response->findAndGetOFString(DCM_StudyID, studyID_);
|
response->findAndGetOFString(DCM_StudyDescription, studyDescription_);
|
||||||
response->findAndGetOFString(DCM_RequestingPhysician, requestingPhysician_);
|
|
||||||
response->findAndGetOFString(DCM_SeriesInstanceUID, seriesUid_);
|
|
||||||
response->findAndGetOFString(DCM_Modality, modality_);
|
response->findAndGetOFString(DCM_Modality, modality_);
|
||||||
|
response->findAndGetOFString(DCM_SeriesInstanceUID, seriesUid_);
|
||||||
response->findAndGetOFString(DCM_SeriesNumber, seriesNumber_);
|
response->findAndGetOFString(DCM_SeriesNumber, seriesNumber_);
|
||||||
response->findAndGetOFString(DCM_NumberOfStudyRelatedInstances, instanceNumber_);
|
response->findAndGetOFString(DCM_NumberOfStudyRelatedInstances, instanceNumber_);
|
||||||
|
|
||||||
@@ -257,8 +256,8 @@ void QueryWorker::onFoundResult(int index, DcmDataset *response)
|
|||||||
study.patientBirthDate = QString::fromStdString(patientBirthDate_);
|
study.patientBirthDate = QString::fromStdString(patientBirthDate_);
|
||||||
study.patientSex = QString::fromStdString(patientSex_);
|
study.patientSex = QString::fromStdString(patientSex_);
|
||||||
study.studyInstanceUID = QString::fromStdString(studyInstanceUID_);
|
study.studyInstanceUID = QString::fromStdString(studyInstanceUID_);
|
||||||
study.studyID = QString::fromStdString(studyID_);
|
study.studyDescription = QString::fromStdString(studyDescription_);
|
||||||
study.requestingPhysician = QString::fromStdString(requestingPhysician_);
|
study.modality = QString::fromStdString(modality_);
|
||||||
study.relatedInstanceNumber = QString::fromStdString(instanceNumber_);
|
study.relatedInstanceNumber = QString::fromStdString(instanceNumber_);
|
||||||
|
|
||||||
emit sendStudyItemFound(study);
|
emit sendStudyItemFound(study);
|
||||||
@@ -268,7 +267,7 @@ void QueryWorker::onFoundResult(int index, DcmDataset *response)
|
|||||||
PACSSeriesInfo series;
|
PACSSeriesInfo series;
|
||||||
series.patientName = QString::fromStdString(patientName_);
|
series.patientName = QString::fromStdString(patientName_);
|
||||||
series.studyInstanceUID = QString::fromStdString(studyInstanceUID_);
|
series.studyInstanceUID = QString::fromStdString(studyInstanceUID_);
|
||||||
series.studyID = QString::fromStdString(studyID_);
|
series.studyID = QString::fromStdString(studyDescription_);
|
||||||
series.seriesUID = QString::fromStdString(seriesUid_);
|
series.seriesUID = QString::fromStdString(seriesUid_);
|
||||||
series.modality = QString::fromStdString(modality_);
|
series.modality = QString::fromStdString(modality_);
|
||||||
series.seriesNumber = QString::fromStdString(seriesNumber_);
|
series.seriesNumber = QString::fromStdString(seriesNumber_);
|
||||||
|
|||||||
@@ -221,20 +221,14 @@ void ImportWidget::initFilterDicom()
|
|||||||
m_pDicomComboBox->addItem(tr("Patient ID"));
|
m_pDicomComboBox->addItem(tr("Patient ID"));
|
||||||
m_pDicomComboBox->addItem(tr("Accession number"));
|
m_pDicomComboBox->addItem(tr("Accession number"));
|
||||||
m_pDicomComboBox->addItem(tr("Device name"));
|
m_pDicomComboBox->addItem(tr("Device name"));
|
||||||
//m_pDicomComboBox->addItem("Study description");
|
|
||||||
//m_pDicomComboBox->addItem("Referring physician");
|
|
||||||
//m_pDicomComboBox->addItem("Performing physician");
|
|
||||||
//m_pDicomComboBox->addItem("Reading physician");
|
|
||||||
//m_pDicomComboBox->addItem("Institution name");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void ImportWidget::initStudyHeader()
|
void ImportWidget::initStudyHeader()
|
||||||
{
|
{
|
||||||
m_lStudyHeaders.clear();
|
m_lStudyHeaders.clear();
|
||||||
m_lStudyHeaders << tr("Study date") << tr("Patient name") << tr("Date of birth") << tr("Patient ID")
|
m_lStudyHeaders << tr("Study date") << tr("Patient name") << tr("Date of birth") << tr("Patient ID")
|
||||||
<< tr("Modality") << tr("Study ID") << tr("Study Instance Uid") << tr("Accession number")
|
<< tr("Study Description") << tr("Accession number")
|
||||||
<< tr("Referring physician") << tr("Performing physician") << tr("Reading physician") << tr("Institution name")
|
<< tr("Images") << tr("Source")<< tr("Study Instance Uid") ;
|
||||||
<< tr("Images") << tr("Source");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void ImportWidget::initStudy()
|
void ImportWidget::initStudy()
|
||||||
@@ -510,93 +504,25 @@ void ImportWidget::updateStudyView()
|
|||||||
QStandardItem* name = new QStandardItem(itr->patientName); name->setEditable(false);
|
QStandardItem* name = new QStandardItem(itr->patientName); name->setEditable(false);
|
||||||
QStandardItem* birth = new QStandardItem(itr->patientBirthDate); birth->setEditable(false);
|
QStandardItem* birth = new QStandardItem(itr->patientBirthDate); birth->setEditable(false);
|
||||||
QStandardItem* id = new QStandardItem(itr->patientID); id->setEditable(false);
|
QStandardItem* id = new QStandardItem(itr->patientID); id->setEditable(false);
|
||||||
QStandardItem* modality = new QStandardItem(""); modality->setEditable(false);
|
// QStandardItem* modality = new QStandardItem(m_pModalityComboBox->currentText()); modality->setEditable(false);
|
||||||
QStandardItem* studyID = new QStandardItem(itr->studyID); studyID->setEditable(false);
|
QStandardItem* studyDescription = new QStandardItem(itr->studyDescription); studyDescription->setEditable(false);
|
||||||
QStandardItem* accNo = new QStandardItem(itr->accessionNumber); accNo->setEditable(false);
|
QStandardItem* accNo = new QStandardItem(itr->accessionNumber); accNo->setEditable(false);
|
||||||
QStandardItem* uid = new QStandardItem(itr->studyInstanceUID); uid->setEditable(false);
|
QStandardItem* uid = new QStandardItem(itr->studyInstanceUID); uid->setEditable(false);
|
||||||
QStandardItem* referPhy = new QStandardItem(""); referPhy->setEditable(false);
|
|
||||||
QStandardItem* performPhy = new QStandardItem(""); performPhy->setEditable(false);
|
|
||||||
QStandardItem* readingPhysician = new QStandardItem(itr->requestingPhysician); readingPhysician->setEditable(false);
|
|
||||||
QStandardItem* inst = new QStandardItem(""); inst->setEditable(false);
|
|
||||||
QStandardItem* image = new QStandardItem(itr->relatedInstanceNumber); image->setEditable(false);
|
QStandardItem* image = new QStandardItem(itr->relatedInstanceNumber); image->setEditable(false);
|
||||||
QStandardItem* source = new QStandardItem(m_pPacsComboBox->currentText()); source->setEditable(false);
|
QStandardItem* source = new QStandardItem(m_pPacsComboBox->currentText()); source->setEditable(false);
|
||||||
|
|
||||||
QList<QStandardItem*> list;
|
QList<QStandardItem*> list;
|
||||||
list << date << name << birth << id << modality << studyID << uid << accNo << referPhy
|
list << date << name << birth << id << studyDescription << accNo
|
||||||
<< performPhy << readingPhysician << inst << image << source;
|
<< image << source<< uid ;
|
||||||
m_pStudyModel->insertRow(iRowIdx, list);
|
m_pStudyModel->insertRow(iRowIdx, list);
|
||||||
++iRowIdx;
|
++iRowIdx;
|
||||||
}
|
}
|
||||||
|
|
||||||
//for each (PACSStudyInfo var in m_studyInfo)
|
|
||||||
//{
|
|
||||||
// QString n = var.studyDate;
|
|
||||||
// QStandardItem* date = new QStandardItem(var.studyDate); date->setEditable(false);
|
|
||||||
// QStandardItem* name = new QStandardItem(var.patientName); name->setEditable(false);
|
|
||||||
// QStandardItem* birth = new QStandardItem(var.patientBirthDate); birth->setEditable(false);
|
|
||||||
// QStandardItem* id = new QStandardItem(var.patientID); id->setEditable(false);
|
|
||||||
// QStandardItem* modality = new QStandardItem(""); modality->setEditable(false);
|
|
||||||
// QStandardItem* description = new QStandardItem(""); description->setEditable(false);
|
|
||||||
// QStandardItem* accNo = new QStandardItem(var.accessionNumber); accNo->setEditable(false);
|
|
||||||
// QStandardItem* examId = new QStandardItem(""); examId->setEditable(false);
|
|
||||||
// QStandardItem* referPhy = new QStandardItem(""); referPhy->setEditable(false);
|
|
||||||
// QStandardItem* performPhy = new QStandardItem(""); performPhy->setEditable(false);
|
|
||||||
// QStandardItem* readingPhysician = new QStandardItem(var.requestingPhysician); readingPhysician->setEditable(false);
|
|
||||||
// QStandardItem* inst = new QStandardItem(""); inst->setEditable(false);
|
|
||||||
// QStandardItem* image = new QStandardItem(""); image->setEditable(false);
|
|
||||||
// QStandardItem* source = new QStandardItem(m_pPacsComboBox->currentText()); source->setEditable(false);
|
|
||||||
// QStandardItem* uid = new QStandardItem(var.studyInstanceUID); uid->setEditable(false);
|
|
||||||
// QList<QStandardItem*> list;
|
|
||||||
// list << date << name << birth << id << modality << description << accNo << examId << referPhy
|
|
||||||
// << performPhy << readingPhysician << inst << image << source << uid;
|
|
||||||
// m_pStudyModel->insertRow(iRowIdx, list);
|
|
||||||
// ++iRowIdx;
|
|
||||||
//}
|
|
||||||
// m_pStudyResult->setModel(m_pStudyModel);
|
|
||||||
// m_pStudyResult->setColumnHidden(14, true);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void ImportWidget::onStudySelected(const QModelIndex ¤t)
|
void ImportWidget::onStudySelected(const QModelIndex ¤t)
|
||||||
{
|
{
|
||||||
// int row = current.row();
|
|
||||||
// if (row < 0)
|
|
||||||
// return;
|
|
||||||
|
|
||||||
// if (mQueryWorkerThread == nullptr)
|
|
||||||
// {
|
|
||||||
// mQueryWorkerThread = new QThread;
|
|
||||||
// }
|
|
||||||
// else
|
|
||||||
// {
|
|
||||||
// if (!mQueryWorkerThread->isFinished())
|
|
||||||
// {
|
|
||||||
// mQueryWorkerThread->exit();
|
|
||||||
// mQueryWorkerThread->wait();
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
|
|
||||||
// if (mQueryWorker == nullptr)
|
|
||||||
// {
|
|
||||||
// std::string peerIP, peerTitle, ourTitle;
|
|
||||||
// unsigned long peerPort = 0, ourPort = 0;
|
|
||||||
// getNetParams(peerIP, peerPort, peerTitle, ourPort, ourTitle);
|
|
||||||
// if (peerIP.empty() || peerTitle.empty() || ourTitle.empty() || peerPort == 0 || ourPort == 0)
|
|
||||||
// {
|
|
||||||
// return;
|
|
||||||
// }
|
|
||||||
|
|
||||||
// mQueryWorker = new QueryWorker(QString::fromStdString(peerIP), peerPort, QString::fromStdString(peerTitle), QString::fromStdString(ourTitle));
|
|
||||||
// QObject::connect(mQueryWorker, SIGNAL(sendFindDone(int)), this, SLOT(onQueryDone(int)), Qt::QueuedConnection);
|
|
||||||
// QObject::connect(mQueryWorker, SIGNAL(sendStudyItemFound(PACSStudyInfo)), this, SLOT(onStudyFoundResult(PACSStudyInfo)), Qt::QueuedConnection);
|
|
||||||
// QObject::connect(mQueryWorker, SIGNAL(sendSeriesItemFound(PACSSeriesInfo)), this, SLOT(onSeriesFoundResult(PACSSeriesInfo)), Qt::QueuedConnection);
|
|
||||||
// }
|
|
||||||
// mQueryWorker->moveToThread(mQueryWorkerThread);
|
|
||||||
// mQueryWorkerThread->start();
|
|
||||||
|
|
||||||
// m_seriesInfo.clear();
|
|
||||||
// std::string studyInstanceUID = m_pStudyModel->index(row, 14).data().toString().toStdString();
|
|
||||||
// QMetaObject::invokeMethod(mQueryWorker, "queryBySeriesUID", Qt::QueuedConnection, Q_ARG(QString, QString::fromStdString(studyInstanceUID)));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -685,17 +611,8 @@ void ImportWidget::executeCGet(const QModelIndex ¤t)
|
|||||||
mGetWorkerThread->wait();
|
mGetWorkerThread->wait();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// std::string seriesNumber = m_pSeriesModel->index(row, 1).data().toString().toStdString();
|
|
||||||
// std::string studyInstanceUID = m_pSeriesModel->index(row, 4).data().toString().toStdString();
|
|
||||||
// std::string studyID = m_pSeriesModel->index(row, 5).data().toString().toStdString();
|
|
||||||
// std::string seriesUID = m_pSeriesModel->index(row, 6).data().toString().toStdString();
|
|
||||||
// std::string patientName = m_pSeriesModel->index(row, 7).data().toString().toStdString();
|
|
||||||
std::string outDirectory = DicomViewerHelper::applicationPath().toStdString();
|
std::string outDirectory = DicomViewerHelper::applicationPath().toStdString();
|
||||||
outDirectory += "/";
|
outDirectory += "/";
|
||||||
// outDirectory += studyInstanceUID;
|
|
||||||
// outDirectory += "/";
|
|
||||||
// outDirectory += seriesUID;
|
|
||||||
|
|
||||||
bool mkRet = false;
|
bool mkRet = false;
|
||||||
QDir d(QString::fromStdString(outDirectory));
|
QDir d(QString::fromStdString(outDirectory));
|
||||||
@@ -718,10 +635,6 @@ void ImportWidget::executeCGet(const QModelIndex ¤t)
|
|||||||
mGetWorker->setOutputDirectory(QString::fromStdString(outDirectory));
|
mGetWorker->setOutputDirectory(QString::fromStdString(outDirectory));
|
||||||
mGetWorker->moveToThread(mGetWorkerThread);
|
mGetWorker->moveToThread(mGetWorkerThread);
|
||||||
mGetWorkerThread->start();
|
mGetWorkerThread->start();
|
||||||
|
|
||||||
// std::string seriesInstanceUID = m_pSeriesModel->index(row, 6).data().toString().toStdString();
|
|
||||||
// std::string dicomType = m_pSeriesModel->index(row, 2).data().toString().toStdString();
|
|
||||||
// QMetaObject::invokeMethod(mGetWorker, "moveBySeriesUID", Qt::QueuedConnection, Q_ARG(QString, QString::fromStdString(studyInstanceUID)), Q_ARG(QString, QString::fromStdString(seriesInstanceUID)), Q_ARG(QString, QString::fromStdString(dicomType)));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -736,7 +649,7 @@ void ImportWidget::moveDone(int code, QString dir)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
QMessageBox::warning(this, "error", "Download dicom failed");
|
QMessageBox::warning(this, tr("error"), tr("Download dicom failed"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -41,8 +41,10 @@
|
|||||||
<translation>检索协议</translation>
|
<translation>检索协议</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../src/PACS/Widget/pacsconfiguration.cpp" line="148"/>
|
<location filename="../src/PACS/Widget/pacsconfiguration.cpp" line="147"/>
|
||||||
<location filename="../src/PACS/Widget/pacsconfiguration.cpp" line="223"/>
|
<source>Test connection</source>
|
||||||
|
<translation>连接测试</translation>
|
||||||
|
</message>
|
||||||
<source>IP address</source>
|
<source>IP address</source>
|
||||||
<translation>IP地址</translation>
|
<translation>IP地址</translation>
|
||||||
</message>
|
</message>
|
||||||
@@ -116,22 +118,22 @@
|
|||||||
<message>
|
<message>
|
||||||
<location filename="../src/PACS/Dialog/ConnectionTestDialog.cpp" line="9"/>
|
<location filename="../src/PACS/Dialog/ConnectionTestDialog.cpp" line="9"/>
|
||||||
<source>Connection Testing</source>
|
<source>Connection Testing</source>
|
||||||
<translation>"连接测试"</translation>
|
<translation>连接测试</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../src/PACS/Dialog/ConnectionTestDialog.cpp" line="9"/>
|
<location filename="../src/PACS/Dialog/ConnectionTestDialog.cpp" line="9"/>
|
||||||
<source>Connecting......</source>
|
<source>Connecting......</source>
|
||||||
<translation>"连接中......"</translation>
|
<translation>连接中......</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../src/PACS/Dialog/ConnectionTestDialog.cpp" line="32"/>
|
<location filename="../src/PACS/Dialog/ConnectionTestDialog.cpp" line="32"/>
|
||||||
<source>Success!</source>
|
<source>Success!</source>
|
||||||
<translation >"连接成功!"</translation>
|
<translation>连接成功!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../src/PACS/Dialog/ConnectionTestDialog.cpp" line="35"/>
|
<location filename="../src/PACS/Dialog/ConnectionTestDialog.cpp" line="35"/>
|
||||||
<source>Fail!</source>
|
<source>Fail!</source>
|
||||||
<translation>"连接失败!"</translation>
|
<translation>连接失败!</translation>
|
||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
@@ -862,8 +864,9 @@ Avg:%5, SD:%6</source>
|
|||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<source>Study description</source>
|
<location filename="../src/PACS/Widget/importwidget.cpp" line="230"/>
|
||||||
<translation type="vanished">检查描述</translation>
|
<source>Study Description</source>
|
||||||
|
<translation>检查描述</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../src/PACS/Widget/importwidget.cpp" line="222"/>
|
<location filename="../src/PACS/Widget/importwidget.cpp" line="222"/>
|
||||||
@@ -929,6 +932,16 @@ Avg:%5, SD:%6</source>
|
|||||||
<source>Custom date range</source>
|
<source>Custom date range</source>
|
||||||
<translation>自定义时间段</translation>
|
<translation>自定义时间段</translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../src/PACS/Widget/importwidget.cpp" line="652"/>
|
||||||
|
<source>error</source>
|
||||||
|
<translation>错误</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../src/PACS/Widget/importwidget.cpp" line="652"/>
|
||||||
|
<source>Download dicom failed</source>
|
||||||
|
<translation>下载DICOM文件失败</translation>
|
||||||
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<source>Exam ID</source>
|
<source>Exam ID</source>
|
||||||
<translation type="vanished">检查编码</translation>
|
<translation type="vanished">检查编码</translation>
|
||||||
|
|||||||
Reference in New Issue
Block a user