{"version":3,"sources":["webpack:///./src/router/views/StdReport.vue?5527","webpack:///./src/router/views/StdReport.vue","webpack:///./src/router/views/StdReport.vue?0973","webpack:///./src/router/views/StdReport.vue?c807","webpack:///./src/router/views/StdReport.vue?2773"],"names":["render","_vm","this","_h","$createElement","_c","_self","staticClass","attrs","report","templateSetName","isComplete","_e","isValid","nativeOn","$event","saveReport","openViewer","openReportPdf","isActionsOpen","staticStyle","isOwner","template","pendingChanges","_v","root","on","preventDefault","downloadReport","claims","isCommunityUser","permissions","sendEmail","openEmailReportDlg","deleteReport","staticRenderFns","_eventBus$type","eventBus","type","REPORT_COMPLETED","REFRESH_REPORT","IMAGE_CHANGE","REPORT_IMAGE_COMMENT","BackRouteName","nextReport","name","components","AstToolbar","ToolbarButton","ModalDrawer","SaveReport","filters","url","value","substring","toLowerCase","props","id","String","required","keywords","Array","viewOnOpen","Boolean","default","data","isSaving","isPageLoading","computed","Object","assign","mapState","state","auth","static","canDelete","deleteStudy","userId","ownerId","isReadOnly","statusClass","isSalesEntry","isLocked","groupConsultantId","statusIcon","activeTemplate","watch","loadReport","beforeRouteEnter","to","from","next","getReportDetail","params","_context","sent","abrupt","prev","t0","stop","_callee","beforeRouteUpdate","isLoadingAnotherReport","_context2","_callee2","beforeRouteLeave","forceNavigation","isConsultantUser","_context3","_callee3","created","$store","dispatch","refreshReport","onCommentUpdated","dbounce","Dbounce","bind","_context4","_callee4","beforeDestroy","off","clear","methods","mapActions","redirectToList","$router","push","reportId","_context5","refresh","_callee5","$el","querySelector","scrollTo","_context6","readOnly","highlightKeywords","onChangeCB","set","_callee6","showConfirm","result","_context7","reportService","deleteStandardReport","notificationType","message","_callee7","complete","arguments","length","undefined","_context8","getStandardReportData","saveStandardReport","broadcast","finish","_callee8","_context9","api","viewer","getStudy","ids","studyIds","then","r","studies","images","forEach","study","imageData","series","s","EmailItem","isFakeSeries","filter","i","some","x","imageId","openEmailStudyDlg","consultantReportId","catch","e","_callee9","openStudy","clinicCode","activeClinicCode","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C,EAAI,EAClDH,WAAYzL,KAAK2B,OAAO+J,iBACxBnI,GAAIvD,KAAKuD,MAGXvC,cAAa,WACZ,IAAAgL,EAAqDhM,KAAKO,OAAlDuH,EAAQkE,EAARlE,SAAUsD,EAAkBY,EAAlBZ,mBAAoB3K,EAAUuL,EAAVvL,WACtCO,eAAc8G,EAAUsD,EAAoB3K,OAI/C,SAAeiF,EAAgBnC,G,kKAEd,O,kBAAMuF,OAAcmD,kBAAkB1I,GAAG,OAA5C,OAAN2I,EAAMC,EAAAtG,KAAAsG,EAAArG,OAAA,SACLoG,GAAM,OAAAC,EAAApG,KAAA,EAAAoG,EAAAnG,GAAAmG,EAAA,YAEbC,eAAUD,EAAAnG,GAAIiD,SAAQ,yBAAAkD,EAAAlG,UAAAoG,EAAA,kBC5S6X,Q,wBCQjZC,EAAY,eACd,EACAxM,EACAmC,GACA,EACA,KACA,KACA,MAIa,aAAAqK,E,2CCnBf","file":"js/teleconsultationDetail.f30ed5326c19ea627d20.bundle.js","sourcesContent":["var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return (_vm.report)?_c('div',{staticClass:\"page-wrapper\",attrs:{\"id\":\"standard-report\",\"list-name\":_vm.report.templateSetName || 'Report'}},[_c('ast-toolbar',{staticClass:\"toolbar-header-secondary\"},[(!_vm.report.isComplete)?_c('toolbar-button',{attrs:{\"disabled\":!_vm.report.isValid,\"icon\":\"check-circle\",\"label\":\"Finalize\",\"title\":\"Finalize\"},nativeOn:{\"click\":function($event){return _vm.saveReport(true)}}}):_vm._e(),_c('toolbar-button',{attrs:{\"icon\":\"eye\",\"label\":\"Launch Viewer\",\"title\":\"Launch Viewer\"},nativeOn:{\"click\":function($event){return _vm.openViewer($event)}}}),_c('toolbar-button',{attrs:{\"icon\":\"file-text-o\",\"label\":\"PDF Report\",\"title\":\"PDF Report\"},nativeOn:{\"click\":function($event){return _vm.openReportPdf($event)}}}),_c('toolbar-button',{attrs:{\"icon\":\"dots-horizontal\",\"label\":\"Actions\",\"title\":\"Actions\"},nativeOn:{\"click\":function($event){_vm.isActionsOpen = true}}}),_c('span',{staticStyle:{\"flex-grow\":\"1\"}}),(!_vm.report.isComplete && _vm.isOwner)?_c('save-report',{attrs:{\"saving\":_vm.template.pendingChanges}}):_vm._e()],1),_c('div',{staticClass:\"list-scroll\"},[(_vm.report.isComplete)?_c('div',{staticStyle:{\"margin-bottom\":\"8px\"}},[_c('span',{staticClass:\"status is-success\"},[(_vm.statusIcon)?_c('svg-icon',{attrs:{\"icon\":\"check-circle\"}}):_vm._e(),_c('span',[_vm._v(\"Completed\")])],1)]):_vm._e(),_c('layout',{attrs:{\"id\":\"rootReportLayout\",\"layout\":_vm.template.root}})],1),(_vm.isActionsOpen)?_c('modal-drawer',{attrs:{\"title\":\"Actions\",\"from-right\":\"\"},on:{\"close\":function($event){_vm.isActionsOpen = false}}},[_c('div',{staticStyle:{\"padding\":\"1rem 1.25rem\",\"width\":\"280px\"}},[_c('ul',{staticClass:\"teleconsultation-actions unlist\"},[_c('li',[_c('button',{staticClass:\"btn btn-default\",on:{\"click\":function($event){$event.preventDefault();return _vm.downloadReport('download-dicom')}}},[_c('svg-icon',{attrs:{\"icon\":\"cloud-download\",\"fixed\":\"\"}}),_vm._v(\"\\n\\t\\t\\t\\t\\t\\tDownload DICOM Images\\n\\t\\t\\t\\t\\t\")],1)]),_c('li',[_c('button',{staticClass:\"btn btn-default\",on:{\"click\":function($event){$event.preventDefault();return _vm.downloadReport('download-jpeg')}}},[_c('svg-icon',{attrs:{\"icon\":\"cloud-download\",\"fixed\":\"\"}}),_vm._v(\"\\n\\t\\t\\t\\t\\t\\tDownload JPEG Images\\n\\t\\t\\t\\t\\t\")],1)]),(!_vm.claims.isCommunityUser && _vm.permissions.sendEmail)?_c('li',[_c('button',{staticClass:\"btn btn-default\",on:{\"click\":function($event){$event.preventDefault();return _vm.openEmailReportDlg()}}},[_c('svg-icon',{attrs:{\"icon\":\"email\",\"fixed\":\"\"}}),_vm._v(\"\\n\\t\\t\\t\\t\\t\\tSend to Email Address\\n\\t\\t\\t\\t\\t\")],1)]):_vm._e(),(_vm.canDelete)?_c('li',[_c('button',{staticClass:\"btn btn-danger\",on:{\"click\":function($event){$event.preventDefault();return _vm.deleteReport($event)}}},[_c('svg-icon',{attrs:{\"icon\":\"delete\",\"fixed\":\"\"}}),_vm._v(\"\\n\\t\\t\\t\\t\\t\\tDelete\\n\\t\\t\\t\\t\\t\")],1)]):_vm._e()])])]):_vm._e()],1):_vm._e()}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { mapState, mapActions } from 'vuex'\nimport api from '@services/api'\nimport { reportService } from '@services/reportService'\nimport ModalDrawer from '@components/ModalDrawer.vue'\nimport AstToolbar from '@components/Toolbar.vue'\nimport ToolbarButton from '@components/ToolbarButton.vue'\nimport { eventBus } from '@services/eventBus'\nimport { Dbounce } from '@utils/dbounce'\nimport { showAlert } from '../../dialogs/MessageDlg.vue'\nimport { ReportDetail } from '@reporting/classes'\nimport { openReportPdf } from '@dialogs/ReportPdf.vue'\nimport SaveReport from '@reporting/components/SaveReport.vue'\nimport { showConfirm } from '@dialogs/ConfirmDlg.vue'\nimport { highlightKeywords } from '@services/hilitor'\nimport { openEmailStudyDlg } from '@/dialogs/emailStudyDlg.vue'\nimport { EmailItem } from '@/components/EmailStudyForm.vue'\n\nconst { REPORT_COMPLETED, REFRESH_REPORT, IMAGE_CHANGE, REPORT_IMAGE_COMMENT } = eventBus.type\nconst BackRouteName = 'studies'\nlet nextReport: ReportDetail = null\n\nexport default {\n\tname: 'StandardReport',\n\tcomponents: {\n\t\tAstToolbar,\n\t\tToolbarButton,\n\t\tModalDrawer,\n\t\tSaveReport,\n\t},\n\tfilters: {\n\t\turl(value) {\n\t\t\tif (value.substring(0, 4).toLowerCase() !== 'http') {\n\t\t\t\tvalue = 'http://' + value\n\t\t\t}\n\t\t\treturn value\n\t\t},\n\t},\n\tprops: {\n\t\tid: {\n\t\t\ttype: String,\n\t\t\trequired: true,\n\t\t},\n\t\tkeywords: {\n\t\t\ttype: Array,\n\t\t\trequired: false,\n\t\t},\n\t\tviewOnOpen: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: false,\n\t\t},\n\t},\n\tdata() {\n\t\treturn {\n\t\t\treport: null,\n\t\t\tisActionsOpen: false,\n\t\t\tisSaving: false,\n\t\t\tisPageLoading: false,\n\t\t}\n\t},\n\tcomputed: {\n\t\t...mapState({\n\t\t\tclaims: (state: any) => state.auth.claims,\n\t\t\tpermissions: (state: any) => state.static.permissions,\n\t\t}),\n\t\tcanDelete() {\n\t\t\treturn (this.permissions.deleteStudy || this.isOwner) && !this.report.isComplete\n\t\t},\n\t\tisOwner() {\n\t\t\treturn this.claims.userId === this.report.ownerId\n\t\t},\n\t\tisReadOnly() {\n\t\t\treturn this.report && this.report.isComplete\n\t\t},\n\t\tstatusClass() {\n\t\t\tif (this.report.isComplete || this.report.isSalesEntry) return 'is-success'\n\t\t\tif (this.report.isLocked) return 'is-danger'\n\t\t\tif (this.report.groupConsultantId) return 'is-info'\n\t\t\treturn 'is-warning'\n\t\t},\n\t\tstatusIcon() {\n\t\t\tif (this.report.isComplete || this.report.isSalesEntry) return 'check-circle'\n\t\t\tif (this.report.isLocked) return 'lock'\n\t\t\treturn ''\n\t\t},\n\t\ttemplate() {\n\t\t\treturn this.report && this.report.activeTemplate\n\t\t},\n\t},\n\twatch: {\n\t\tid() {\n\t\t\tthis.loadReport()\n\t\t},\n\t},\n\tasync beforeRouteEnter(to, from, next) {\n\t\ttry {\n\t\t\tnextReport = await getReportDetail(to.params.id)\n\t\t\t// Cancel navigation if images are not ready or error\n\t\t\tif (!nextReport) return next(from.name ? false : BackRouteName)\n\t\t\tnext()\n\t\t} catch (err) {\n\t\t\tnext(from.name ? false : BackRouteName)\n\t\t}\n\t},\n\tasync beforeRouteUpdate(to, from, next) {\n\t\tconst isLoadingAnotherReport = to.params.id !== from.params.id\n\t\tif (!isLoadingAnotherReport) return next()\n\t\tthis.isPageLoading = true\n\t\tawait this.saveReport()\n\t\tnextReport = await getReportDetail(to.params.id)\n\t\tthis.isPageLoading = false\n\t\t// Cancel navigation if images are not ready or error\n\t\tif (!nextReport) return next(from.name ? false : BackRouteName)\n\t\tnext()\n\t},\n\tasync beforeRouteLeave(to, from, next) {\n\t\tif (this.forceNavigation || !this.claims.isConsultantUser) return next()\n\t\tawait this.saveReport()\n\t\tnext()\n\t},\n\tasync created() {\n\t\tthis.$store.dispatch('getOnBehalfOfList')\n\t\teventBus.on(REFRESH_REPORT, this.refreshReport)\n\t\teventBus.on(IMAGE_CHANGE, this.refreshReport)\n\t\teventBus.on(REPORT_IMAGE_COMMENT, this.onCommentUpdated)\n\t\tthis.dbounce = new Dbounce(3000, this.saveReport.bind(this))\n\t\tthis.loadReport()\n\t\tif (this.viewOnOpen) this.openViewer()\n\t},\n\tbeforeDestroy() {\n\t\teventBus.off(REFRESH_REPORT, this.refreshReport)\n\t\teventBus.off(IMAGE_CHANGE, this.refreshReport)\n\t\teventBus.off(REPORT_IMAGE_COMMENT, this.onCommentUpdated)\n\t\tthis.dbounce.clear()\n\t},\n\tmethods: {\n\t\t...mapActions(['openStudy']),\n\t\tredirectToList() {\n\t\t\tthis.forceNavigation = true\n\t\t\tthis.$router.push({ name: BackRouteName })\n\t\t},\n\t\t// Listen for events from other windows spawned from the main Omni window.\n\t\tonCommentUpdated(reportId) {\n\t\t\tif (reportId !== this.report.reportId) return\n\t\t\tthis.refreshReport()\n\t\t},\n\t\tasync refreshReport() {\n\t\t\tawait this.saveReport()\n\t\t\tconst report = await getReportDetail(this.id)\n\t\t\tif (!report) return this.redirectToList()\n\t\t\tthis.report.refresh(report)\n\t\t},\n\t\tasync loadReport() {\n\t\t\tif (this.$el) this.$el.querySelector('.list-scroll').scrollTo(0, 0)\n\n\t\t\tthis.isPageLoading = true\n\t\t\tthis.report = nextReport || (await getReportDetail(this.id))\n\t\t\tnextReport = null\n\t\t\tthis.isPageLoading = false\n\t\t\tif (!this.report) return\n\n\t\t\tif (this.template.root.readOnly) {\n\t\t\t\thighlightKeywords(this.keywords, '#rootReportLayout')\n\t\t\t}\n\t\t\tthis.template.onChangeCB = this.dbounce.set.bind(this.dbounce)\n\t\t\tthis.template.pendingChanges = false\n\t\t},\n\t\tasync deleteReport() {\n\t\t\tlet result = await showConfirm('Are you sure you want to delete this report?')\n\t\t\tif (!result) return\n\t\t\treportService.deleteStandardReport(this.id)\n\t\t\tthis.$store.dispatch('addNotification', {\n\t\t\t\tnotificationType: 'success',\n\t\t\t\tmessage: 'Report deleted!',\n\t\t\t})\n\t\t\tthis.redirectToList()\n\t\t},\n\t\tasync saveReport(complete = false) {\n\t\t\tif (!this.template) return\n\t\t\tif (!complete && (this.isReadOnly || !this.template.pendingChanges)) return\n\n\t\t\ttry {\n\t\t\t\tthis.isSaving = true\n\t\t\t\tlet data = this.report.getStandardReportData(complete)\n\t\t\t\tawait reportService.saveStandardReport(data)\n\t\t\t\tthis.template.pendingChanges = false\n\n\t\t\t\tif (complete) {\n\t\t\t\t\tthis.$store.dispatch('addNotification', {\n\t\t\t\t\t\tnotificationType: 'success',\n\t\t\t\t\t\tmessage: 'Report completed!',\n\t\t\t\t\t})\n\t\t\t\t\teventBus.broadcast(REPORT_COMPLETED, this.report.reportId)\n\t\t\t\t\tthis.redirectToList()\n\t\t\t\t}\n\t\t\t} finally {\n\t\t\t\tthis.isSaving = false\n\t\t\t}\n\t\t},\n\t\tasync openEmailReportDlg() {\n\t\t\tthis.isActionsOpen = false\n\t\t\tlet report: ReportDetail = this.report\n\t\t\tlet studies: IStudy[] = await api.viewer.getStudy({ ids: report.studyIds }, false).then(r => r.studies)\n\n\t\t\tlet images: EmailItem[] = []\n\t\t\tstudies.forEach(study => {\n\t\t\t\tstudy.imageData.series.forEach(s => {\n\t\t\t\t\timages.push(new EmailItem(s, s.images[0], !s.isFakeSeries))\n\t\t\t\t})\n\t\t\t})\n\n\t\t\timages = images.filter(i => report.images.some(x => x.id === i.imageId))\n\t\t\topenEmailStudyDlg(studies, images, [report.consultantReportId]).catch(e => {})\n\t\t},\n\t\topenViewer() {\n\t\t\tthis.openStudy({\n\t\t\t\tclinicCode: this.claims.activeClinicCode,\n\t\t\t\treportId: this.report.reportId,\n\t\t\t\tmodality: this.report.study.modality,\n\t\t\t})\n\t\t},\n\t\tdownloadReport(imageType) {\n\t\t\tthis.$api.file.downloadReport({\n\t\t\t\tdownloadType: imageType === 'download-jpeg' ? 0 : 1,\n\t\t\t\tclinicCode: this.claims.activeClinicCode,\n\t\t\t\tid: this.id,\n\t\t\t})\n\t\t},\n\t\topenReportPdf() {\n\t\t\tconst { reportId, consultantReportId, isComplete } = this.report\n\t\t\topenReportPdf(reportId, consultantReportId, isComplete)\n\t\t},\n\t},\n}\nasync function getReportDetail(id) {\n\ttry {\n\t\tconst detail = await reportService.getStandardReport(id)\n\t\treturn detail\n\t} catch (err) {\n\t\tshowAlert(err.message)\n\t}\n}\n","import mod from \"-!../../../node_modules/cache-loader/dist/cjs.js??ref--14-0!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/ts-loader/index.js??ref--14-3!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./StdReport.vue?vue&type=script&lang=ts\"; export default mod; export * from \"-!../../../node_modules/cache-loader/dist/cjs.js??ref--14-0!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/ts-loader/index.js??ref--14-3!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./StdReport.vue?vue&type=script&lang=ts\"","import { render, staticRenderFns } from \"./StdReport.vue?vue&type=template&id=4332e7f9\"\nimport script from \"./StdReport.vue?vue&type=script&lang=ts\"\nexport * from \"./StdReport.vue?vue&type=script&lang=ts\"\nimport style0 from \"./StdReport.vue?vue&type=style&index=0&id=4332e7f9&prod&lang=scss\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","export * from \"-!../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../../node_modules/css-loader/index.js??ref--8-oneOf-1-1!../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../../node_modules/sass-loader/lib/loader.js??ref--8-oneOf-1-3!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./StdReport.vue?vue&type=style&index=0&id=4332e7f9&prod&lang=scss\""],"sourceRoot":""}