1
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
7dd02e84aa
commit
4e1911223d
|
|
@ -289,7 +289,7 @@ export default {
|
|||
sRoiDistanceId: '',
|
||||
rowSaveLoadingMap: {},
|
||||
dialogSaveLoading: false,
|
||||
openWindow: null
|
||||
childWindows: []
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
|
|
@ -329,11 +329,13 @@ export default {
|
|||
DicomEvent.$on('refreshQuestions', _ => {
|
||||
this.refreshQuestions()
|
||||
})
|
||||
window.addEventListener('beforeunload', this.closeAllChildWindows)
|
||||
},
|
||||
beforeDestroy() {
|
||||
DicomEvent.$off('setCollapseActive')
|
||||
DicomEvent.$off('getUnSaveTarget')
|
||||
DicomEvent.$off('refreshQuestions')
|
||||
window.removeEventListener('beforeunload', this.closeAllChildWindows)
|
||||
},
|
||||
methods: {
|
||||
handleReadingChart(e) {
|
||||
|
|
@ -745,14 +747,22 @@ export default {
|
|||
this.addOrEdit.lesionType = row.LesionType
|
||||
},
|
||||
handleView(item) {
|
||||
if (this.openWindow) {
|
||||
this.openWindow.close()
|
||||
}
|
||||
localStorage.setItem('taskBlindName', this.taskBlindName)
|
||||
localStorage.setItem('isReadingShowSubjectInfo', this.isReadingShowSubjectInfo)
|
||||
let token = getToken()
|
||||
let routeData = this.$router.resolve({ path: `/ecrfList?trialId=${this.$route.query.trialId}&visitTaskId=${this.visitTaskId}&questionId=${item.Id}&TokenKey=${token}` })
|
||||
this.openWindow = window.open(routeData.href, "_blank")
|
||||
const win = window.open(routeData.href, '_blank')
|
||||
if (win) {
|
||||
this.childWindows.push(win)
|
||||
}
|
||||
},
|
||||
closeAllChildWindows() {
|
||||
this.childWindows.forEach(win => {
|
||||
if (win && !win.closed) {
|
||||
win.close()
|
||||
}
|
||||
})
|
||||
this.childWindows = []
|
||||
},
|
||||
async saveFormData() {
|
||||
if (this.dialogSaveLoading) return
|
||||
|
|
|
|||
|
|
@ -290,7 +290,7 @@ export default {
|
|||
sRoiDistanceId: '',
|
||||
rowSaveLoadingMap: {},
|
||||
dialogSaveLoading: false,
|
||||
openWindow: null
|
||||
childWindows: []
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
|
|
@ -330,11 +330,13 @@ export default {
|
|||
DicomEvent.$on('refreshQuestions', _ => {
|
||||
this.refreshQuestions()
|
||||
})
|
||||
window.addEventListener('beforeunload', this.closeAllChildWindows)
|
||||
},
|
||||
beforeDestroy() {
|
||||
DicomEvent.$off('setCollapseActive')
|
||||
DicomEvent.$off('getUnSaveTarget')
|
||||
DicomEvent.$off('refreshQuestions')
|
||||
window.removeEventListener('beforeunload', this.closeAllChildWindows)
|
||||
},
|
||||
methods: {
|
||||
handleReadingChart(e) {
|
||||
|
|
@ -768,7 +770,18 @@ export default {
|
|||
localStorage.setItem('isReadingShowSubjectInfo', this.isReadingShowSubjectInfo)
|
||||
let token = getToken()
|
||||
let routeData = this.$router.resolve({ path: `/ecrfList?trialId=${this.$route.query.trialId}&visitTaskId=${this.visitTaskId}&questionId=${item.Id}&TokenKey=${token}` })
|
||||
this.openWindow = window.open(routeData.href, "_blank")
|
||||
const win = window.open(routeData.href, '_blank')
|
||||
if (win) {
|
||||
this.childWindows.push(win)
|
||||
}
|
||||
},
|
||||
closeAllChildWindows() {
|
||||
this.childWindows.forEach(win => {
|
||||
if (win && !win.closed) {
|
||||
win.close()
|
||||
}
|
||||
})
|
||||
this.childWindows = []
|
||||
},
|
||||
async saveFormData() {
|
||||
if (this.dialogSaveLoading) return
|
||||
|
|
|
|||
Loading…
Reference in New Issue