109 lines
6.2 KiB
Plaintext
109 lines
6.2 KiB
Plaintext
<template>
|
|
<div />
|
|
</template>
|
|
<script>
|
|
import { getNextTask, getReadingTool } from '@/api/trials'
|
|
import store from '@/store'
|
|
import { changeURLStatic } from '@/utils/history.js'
|
|
export default {
|
|
name: 'ReadPage',
|
|
data() {
|
|
return {
|
|
trialId: '',
|
|
subjectCode: '',
|
|
subjectId: '',
|
|
visitTaskId: '',
|
|
readingCategory: 2,
|
|
taskBlindName: '',
|
|
isReadingShowSubjectInfo: false,
|
|
isReadingShowPreviousResults: false,
|
|
TrialReadingCriterionId: null,
|
|
isExistsClinicalData: false,
|
|
tabName: '',
|
|
isExistsNoDicomFile: false
|
|
}
|
|
},
|
|
mounted() {
|
|
if (this.$router.currentRoute.query.TokenKey) {
|
|
store.dispatch('user/setToken', this.$router.currentRoute.query.TokenKey)
|
|
changeURLStatic('TokenKey', '')
|
|
}
|
|
this.tabName = this.$router.currentRoute.query.tabName ? this.$router.currentRoute.query.tabName : 'read'
|
|
this.trialId = this.$router.currentRoute.query.trialId
|
|
this.subjectCode = this.$router.currentRoute.query.subjectCode
|
|
this.subjectId = this.$router.currentRoute.query.subjectId ? this.$router.currentRoute.query.subjectId : ''
|
|
this.visitTaskId = this.$router.currentRoute.query.visitTaskId ? this.$router.currentRoute.query.visitTaskId : ''
|
|
// this.TrialReadingCriterionId = this.$router.currentRoute.query.trialReadingCriterionId
|
|
this.TrialReadingCriterionId = localStorage.getItem('TrialReadingCriterionId')
|
|
// this.isReadingShowPreviousResults = this.$router.currentRoute.query.isReadingShowPreviousResults
|
|
this.getTaskInfo()
|
|
},
|
|
methods: {
|
|
getTaskInfo() {
|
|
const loading = this.$loading({ fullscreen: true })
|
|
var param = {
|
|
subjectId: this.subjectId,
|
|
trialId: this.trialId,
|
|
visistTaskId: this.visitTaskId,
|
|
subjectCode: this.subjectCode,
|
|
TrialReadingCriterionId: this.TrialReadingCriterionId
|
|
}
|
|
getNextTask(param).then(async res => {
|
|
this.readingCategory = res.Result.ReadingCategory
|
|
this.subjectId = res.Result.SubjectId
|
|
this.visitTaskId = res.Result.VisitTaskId
|
|
this.subjectCode = res.Result.SubjectCode
|
|
this.taskBlindName = res.Result.TaskBlindName
|
|
this.isReadingShowSubjectInfo = res.Result.IsReadingShowSubjectInfo
|
|
this.isExistsClinicalData = res.Result.IsExistsClinicalData
|
|
if (this.$router.currentRoute.query.isReadingShowPreviousResults !== undefined && this.$router.currentRoute.query.isReadingShowPreviousResults !== null) {
|
|
this.isReadingShowPreviousResults = this.$router.currentRoute.query.isReadingShowPreviousResults
|
|
} else {
|
|
this.isReadingShowPreviousResults = res.Result.IsReadingShowPreviousResults
|
|
}
|
|
this.isExistsNoDicomFile = res.Result.IsExistsNoDicomFile
|
|
|
|
loading.close()
|
|
if (res.Result.ReadingCategory === 1) {
|
|
// 访视阅片
|
|
this.getCriterionConfig()
|
|
} else if (res.Result.ReadingCategory === 2) {
|
|
// 全局阅片
|
|
this.$router.push({
|
|
path: `/globalReview?trialId=${this.trialId}&subjectCode=${this.subjectCode}&subjectId=${this.subjectId}&visitTaskId=${this.visitTaskId}&readingCategory=${this.readingCategory}&taskBlindName=${this.taskBlindName}&isReadingShowSubjectInfo=${this.isReadingShowSubjectInfo}&isReadingShowPreviousResults=${this.isReadingShowPreviousResults}`
|
|
})
|
|
} else if (res.Result.ReadingCategory === 4) {
|
|
// 裁判阅片
|
|
this.$router.push({
|
|
path: `/adReview?trialId=${this.trialId}&subjectCode=${this.subjectCode}&subjectId=${this.subjectId}&visitTaskId=${this.visitTaskId}&readingCategory=${this.readingCategory}&taskBlindName=${this.taskBlindName}&isReadingShowSubjectInfo=${this.isReadingShowSubjectInfo}&isReadingShowPreviousResults=${this.isReadingShowPreviousResults}`
|
|
})
|
|
} else if (res.Result.ReadingCategory === 5) {
|
|
// 肿瘤学阅片
|
|
this.$router.push({
|
|
path: `/oncologyReview?trialId=${this.trialId}&subjectCode=${this.subjectCode}&subjectId=${this.subjectId}&visitTaskId=${this.visitTaskId}&readingCategory=${this.readingCategory}&taskBlindName=${this.taskBlindName}&isReadingShowSubjectInfo=${this.isReadingShowSubjectInfo}&isReadingShowPreviousResults=${this.isReadingShowPreviousResults}`
|
|
})
|
|
}
|
|
}).catch(() => { loading.close() })
|
|
},
|
|
getCriterionConfig() {
|
|
const loading = this.$loading({ fullscreen: true })
|
|
getReadingTool({ visitTaskId: this.visitTaskId }).then(res => {
|
|
loading.close()
|
|
if (res.Result.ReadingTool === 0) {
|
|
window.location.href = `/readingDicoms?TrialReadingCriterionId=${res.Result.TrialReadingCriterionId}&CriterionType=${res.Result.CriterionType}&trialId=${this.trialId}&subjectCode=${this.subjectCode}&subjectId=${this.subjectId}&visitTaskId=${this.visitTaskId}&readingCategory=${this.readingCategory}&taskBlindName=${this.taskBlindName}&isReadingShowSubjectInfo=${this.isReadingShowSubjectInfo}&isReadingShowPreviousResults=${this.isReadingShowPreviousResults}&tabName=${this.tabName}&isExistsClinicalData=${this.isExistsClinicalData}&isExistsNoDicomFile=${this.isExistsNoDicomFile}`
|
|
// this.$router.push({
|
|
// path: `/readingDicoms?TrialReadingCriterionId=${res.Result.TrialReadingCriterionId}&CriterionType=${res.Result.CriterionType}&trialId=${this.trialId}&subjectCode=${this.subjectCode}&subjectId=${this.subjectId}&visitTaskId=${this.visitTaskId}&readingCategory=${this.readingCategory}&taskBlindName=${this.taskBlindName}&isReadingShowSubjectInfo=${this.isReadingShowSubjectInfo}&isReadingShowPreviousResults=${this.isReadingShowPreviousResults}&tabName=${this.tabName}&isExistsClinicalData=${this.isExistsClinicalData}`
|
|
// })
|
|
} else {
|
|
// if (res.Result.ReadingTool === 1)
|
|
this.$router.push({
|
|
path: `/noneDicomReading?trialId=${this.trialId}&subjectCode=${this.subjectCode}&subjectId=${this.subjectId}&visitTaskId=${this.visitTaskId}&readingCategory=${this.readingCategory}&taskBlindName=${this.taskBlindName}&isReadingShowSubjectInfo=${this.isReadingShowSubjectInfo}&isReadingShowPreviousResults=${this.isReadingShowPreviousResults}&isExistsClinicalData=${this.isExistsClinicalData}`
|
|
})
|
|
}
|
|
}).catch(() => { loading.close() })
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
|