feat: Add new worklist error handle logic
This commit is contained in:
@@ -18,10 +18,27 @@ void GetWorkListAction::run()
|
|||||||
{
|
{
|
||||||
if (!mQueryData.isEmpty())
|
if (!mQueryData.isEmpty())
|
||||||
{
|
{
|
||||||
QList<PatientInformationPointer> patients = WorkListManager::getPatientFromWorkList(mQueryData.mAccessionNum, mQueryData.mPatientId);
|
QList<PatientInformationPointer> patients;
|
||||||
if(patients.isEmpty())
|
int result = WorkListManager::getPatientFromWorkList(mQueryData.mAccessionNum, mQueryData.mPatientId,patients);
|
||||||
|
if(result == Success && patients.isEmpty())
|
||||||
{
|
{
|
||||||
emit actionCompleted(ActionResult(Failed,tr("WorkList Search Failed")));
|
emit actionCompleted(ActionResult(Failed,tr("No reference record find!")));
|
||||||
|
}
|
||||||
|
else if(result == InitNetWorkError)
|
||||||
|
{
|
||||||
|
emit actionCompleted(ActionResult(Failed,tr("Worklist network init error!")));
|
||||||
|
}
|
||||||
|
else if(result == ConnectError)
|
||||||
|
{
|
||||||
|
emit actionCompleted(ActionResult(Failed,tr("Worklist connect error!")));
|
||||||
|
}
|
||||||
|
else if(result == ResponseError)
|
||||||
|
{
|
||||||
|
emit actionCompleted(ActionResult(Failed,tr("Worklist response find failed!")));
|
||||||
|
}
|
||||||
|
else if(result == ContextError)
|
||||||
|
{
|
||||||
|
emit actionCompleted(ActionResult(Failed,tr("Worklist query context error!")));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user