Skip to content

Commit

Permalink
BAH-1240 | Removing check for response head. Oviyam sends a redirect …
Browse files Browse the repository at this point in the history
…URL which can be HTTP depending on setup, and in that case browser thrrows error for CORS (#377)

* BAH-1240 | Removing check for response, as Oviyam sends a redirect URL in some cases and they happen to be HTTP (if behind a reverse proxy), and browser without CORS header does not follow the URL

* Minor changes to message and relevant translation. also corrected URL for repo in package json
  • Loading branch information
angshu authored Sep 17, 2021
1 parent f44d351 commit 1bfc5e8
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -89,12 +89,7 @@ angular.module('bahmni.common.displaycontrol.pacsOrders')
messagingService.showMessage('info', "NO_PACS_STUDY_FOR_ORDER");
}
var url = bahmniOrder.pacsStudyUrl || bahmniOrder.pacsImageUrl;
spinner.forAjaxPromise($.ajax({type: 'HEAD', url: url, async: false}).then(
function () {
$window.open(url, "_blank");
}, function () {
messagingService.showMessage("info", $translate.instant("NO_IMAGE_YET_FOR_ORDER") + $scope.getLabel(bahmniOrder));
}));
$window.open(url, "_blank");
};

$scope.initialization = init();
Expand Down
2 changes: 1 addition & 1 deletion ui/app/i18n/clinical/locale_en.json
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,7 @@
"PROGRAM_PATIENT_STAGE": "Patient Stage",
"CLINICAL_CLASS": "Class",
"CLINICAL_CASTE": "Caste",
"NO_PACS_STUDY_FOR_ORDER": "Unable to identify study for order. Please verify PACS configuration",
"NO_PACS_STUDY_FOR_ORDER": "Unable to identify study for order. Searching with accession number.",
"RADIOLOGY_STUDY_FETCH_ERROR": "Unable to fetch radiology studies. Please verify PACS configuration",
"NO_IMAGE_YET_FOR_ORDER": "No image available yet for order",
"CLINICAL_CASTE": "Caste",
Expand Down
2 changes: 1 addition & 1 deletion ui/app/i18n/clinical/locale_es.json
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,7 @@
"CONSULTATION_PAD_EMPTY_MESSAGE": "El panel de consulta está vacío",
"MEDICATION_LABEL_START_DATE": "Fecha de inicio",
"DISCHARGE_DATE_LABEL": "Descarga Date",
"NO_PACS_STUDY_FOR_ORDER": "No se puede identificar el estudio por orden. Verifique la configuración de PACS",
"NO_PACS_STUDY_FOR_ORDER": "No se pudo identificar el estudio por orden. Buscando con número de acceso.",
"RADIOLOGY_STUDY_FETCH_ERROR": "No se pueden obtener estudios de radiología. Verifique la configuración de PACS",
"NO_IMAGE_YET_FOR_ORDER": "Aún no hay imagen disponible para ordenar"
}
2 changes: 1 addition & 1 deletion ui/app/i18n/clinical/locale_fr.json
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@
"CONSULTATION_PAD_EMPTY_MESSAGE": "Le bloc de consultation est vide",
"MEDICATION_LABEL_START_DATE": "Date de début",
"DISCHARGE_DATE_LABEL": "Décharge Date",
"NO_PACS_STUDY_FOR_ORDER": "Impossible d'identifier l'étude pour la commande. Veuillez vérifier la configuration du PACS",
"NO_PACS_STUDY_FOR_ORDER": "Impossible d'identifier l'étude pour la commande. Recherche avec numéro d'accession.",
"RADIOLOGY_STUDY_FETCH_ERROR": "Impossible d'aller chercher des études de radiologie. Veuillez vérifier la configuration du PACS",
"NO_IMAGE_YET_FOR_ORDER": "Pas encore d'image disponible pour la commande",
"DISCHARGE_DATE_LABEL": "Décharge Date",
Expand Down
2 changes: 1 addition & 1 deletion ui/app/i18n/clinical/locale_pt_BR.json
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@
"ADMISSION_DATE_LABEL": "Data de admissão",
"CONSULTATION_PAD_EMPTY_MESSAGE": "O painel de consulta está vazio",
"DISCHARGE_DATE_LABEL": "Descarga Date",
"NO_PACS_STUDY_FOR_ORDER": "Não é possível identificar o estudo para pedido. Verifique a configuração do PACS",
"NO_PACS_STUDY_FOR_ORDER": "Incapaz de identificar o estudo para pedido. Pesquisando com o número de acesso.",
"RADIOLOGY_STUDY_FETCH_ERROR": "Não é possível buscar estudos de radiologia. Verifique a configuração do PACS",
"NO_IMAGE_YET_FOR_ORDER": "Nenhuma imagem disponível ainda para pedido"
}
2 changes: 1 addition & 1 deletion ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@
},
"repository": {
"type": "git",
"url": "git://github.com/Bhamni/opd.git"
"url": "git://github.com/Bahmni/openmrs-module-bahmniapps.git"
},
"keywords": [
"Bahmni",
Expand Down

0 comments on commit 1bfc5e8

Please sign in to comment.