Merge branch 'main' of https://gitea.frp.extimaging.com/XCKJ/irc_web
continuous-integration/drone/push Build is passing Details

uat_us
DESKTOP-6C3NK6N\WXS 2024-09-09 15:48:06 +08:00
commit cbee69b4c0
6 changed files with 42 additions and 30 deletions

View File

@ -200,4 +200,4 @@ export function getTaskUploadedDicomStudyList(param) {
method: 'post', method: 'post',
data: param data: param
}) })
} }

View File

@ -6,7 +6,7 @@
<div class="sidePanelThumbs"> <div class="sidePanelThumbs">
<el-tabs v-model="activeName" type="border-card" @tab-click="handleTabClick"> <el-tabs v-model="activeName" type="border-card" @tab-click="handleTabClick">
<el-tab-pane :label="$t('trials:dicom-show:currentVisit')" name="current-study"> <el-tab-pane :label="$t('trials:dicom-show:currentVisit')" name="current-study">
<div class="text-desc" style="background:rgb(55 55 55);" v-if="visitInfo"> <div v-if="visitInfo" class="text-desc" style="background:rgb(55 55 55);">
{{ visitInfo }} {{ visitInfo }}
</div> </div>
<div class="viewerSidethumbs ps" style="position: relative;"> <div class="viewerSidethumbs ps" style="position: relative;">
@ -261,6 +261,7 @@ import * as cornerstoneWADOImageLoader from 'cornerstone-wado-image-loader'
import dicomViewer from '@/components/Dicom/DicomViewer' import dicomViewer from '@/components/Dicom/DicomViewer'
import { getVisitStudyList, getAllRelationStudyList, getSeriesList } from '@/api/reading' import { getVisitStudyList, getAllRelationStudyList, getSeriesList } from '@/api/reading'
import { setSeriesStatus } from '@/api/trials' import { setSeriesStatus } from '@/api/trials'
import { getTaskUploadedDicomStudyList } from '@/api/reading'
import requestPoolManager from '@/utils/request-pool' import requestPoolManager from '@/utils/request-pool'
import store from '@/store' import store from '@/store'
import { changeURLStatic } from '@/utils/history.js' import { changeURLStatic } from '@/utils/history.js'
@ -301,7 +302,8 @@ export default {
relationActiveName: [], relationActiveName: [],
showSeriesList: [], showSeriesList: [],
currentLoadIns: [], currentLoadIns: [],
isFromCRCUpload: false isFromCRCUpload: false,
visitTaskId: null
} }
}, },
mounted() { mounted() {
@ -318,6 +320,7 @@ export default {
this.isReading = this.$router.currentRoute.query.isReading ? this.$router.currentRoute.query.isReading * 1 : 0 this.isReading = this.$router.currentRoute.query.isReading ? this.$router.currentRoute.query.isReading * 1 : 0
this.showDelete = parseInt(this.$router.currentRoute.query.showDelete) this.showDelete = parseInt(this.$router.currentRoute.query.showDelete)
this.isFromCRCUpload = !!this.$router.currentRoute.query.isFromCRCUpload this.isFromCRCUpload = !!this.$router.currentRoute.query.isFromCRCUpload
this.visitTaskId = this.$router.currentRoute.query.visitTaskId
// cornerstone.events.addEventListener('cornerstoneimageloaded', this.cornerstoneImageLoaded) // cornerstone.events.addEventListener('cornerstoneimageloaded', this.cornerstoneImageLoaded)
this.getStudiesInfo() this.getStudiesInfo()
cornerstone.events.addEventListener('cornerstoneimageloadprogress', this.cornerstoneimageloadprogress) cornerstone.events.addEventListener('cornerstoneimageloadprogress', this.cornerstoneimageloadprogress)
@ -338,7 +341,12 @@ export default {
async getStudiesInfo() { async getStudiesInfo() {
this.studyList = [] this.studyList = []
try { try {
const res = await getVisitStudyList(this.trialId, this.subjectVisitId, this.isReading) let res = null
if (this.visitTaskId) {
res = await getTaskUploadedDicomStudyList({ visitTaskId: this.visitTaskId })
} else {
res = await getVisitStudyList(this.trialId, this.subjectVisitId, this.isReading)
}
if (res.IsSuccess) { if (res.IsSuccess) {
res.Result.forEach((study, studyIndex) => { res.Result.forEach((study, studyIndex) => {
const data = {} const data = {}

View File

@ -328,6 +328,7 @@ export default {
}, },
limitBlur(qId, valueType) { limitBlur(qId, valueType) {
const value = this.questionForm[qId] const value = this.questionForm[qId]
if (isNaN(parseInt(value))) return
if (valueType === 0) { if (valueType === 0) {
this.$set(this.questionForm, qId, parseInt(value)) this.$set(this.questionForm, qId, parseInt(value))
} else if (valueType === 3) { } else if (valueType === 3) {

View File

@ -549,6 +549,7 @@ export default {
}, },
limitBlur(qId, valueType) { limitBlur(qId, valueType) {
const value = this.questionForm[qId] const value = this.questionForm[qId]
if (isNaN(parseInt(value))) return
if (valueType === 0) { if (valueType === 0) {
this.$set(this.questionForm, qId, parseInt(value)) this.$set(this.questionForm, qId, parseInt(value))
} else if (valueType === 3) { } else if (valueType === 3) {
@ -557,7 +558,7 @@ export default {
this.$set(this.questionForm, qId, parseFloat(value).toFixed(this.digitPlaces)) this.$set(this.questionForm, qId, parseFloat(value).toFixed(this.digitPlaces))
} }
}, },
numberToFixed(v, unit){ numberToFixed(v, unit) {
return isNaN(parseFloat(v)) ? null : `${parseFloat(v).toFixed(this.digitPlaces)}${unit}` return isNaN(parseFloat(v)) ? null : `${parseFloat(v).toFixed(this.digitPlaces)}${unit}`
}, },
async handleSave(index) { async handleSave(index) {

View File

@ -349,6 +349,7 @@ export default {
}, },
limitBlur(qId, valueType) { limitBlur(qId, valueType) {
const value = this.questionForm[qId] const value = this.questionForm[qId]
if (isNaN(parseInt(value))) return
if (valueType === 0) { if (valueType === 0) {
this.$set(this.questionForm, qId, parseInt(value)) this.$set(this.questionForm, qId, parseInt(value))
} else if (valueType === 3) { } else if (valueType === 3) {

View File

@ -182,7 +182,7 @@
</div> </div>
</template> </template>
<script> <script>
import { saveTaskQuestion } from '@/api/trials' // import { saveTaskQuestion } from '@/api/trials'
import { resetReadingTask } from '@/api/reading' import { resetReadingTask } from '@/api/reading'
import DicomEvent from './../DicomEvent' import DicomEvent from './../DicomEvent'
import store from '@/store' import store from '@/store'
@ -561,6 +561,7 @@ export default {
}, },
limitBlur(qId, valueType) { limitBlur(qId, valueType) {
const value = this.questionForm[qId] const value = this.questionForm[qId]
if (isNaN(parseInt(value))) return
if (valueType === 0) { if (valueType === 0) {
this.$set(this.questionForm, qId, parseInt(value)) this.$set(this.questionForm, qId, parseInt(value))
} else if (valueType === 3) { } else if (valueType === 3) {
@ -569,33 +570,33 @@ export default {
this.$set(this.questionForm, qId, parseFloat(value).toFixed(this.digitPlaces)) this.$set(this.questionForm, qId, parseFloat(value).toFixed(this.digitPlaces))
} }
}, },
numberToFixed(v, unit){ numberToFixed(v, unit) {
return isNaN(parseFloat(v)) ? null : `${parseFloat(v).toFixed(this.digitPlaces)}${unit}` return isNaN(parseFloat(v)) ? null : `${parseFloat(v).toFixed(this.digitPlaces)}${unit}`
}, },
async handleSave(index) { async handleSave(index) {
const refName = `questions${index}` // const refName = `questions${index}`
const valid = await this.$refs[refName][0].validate() // const valid = await this.$refs[refName][0].validate()
if (!valid) return // if (!valid) return
const loading = this.$loading({ fullscreen: true }) // const loading = this.$loading({ fullscreen: true })
var answers = [] // var answers = []
for (const k in this.questionForm) { // for (const k in this.questionForm) {
answers.push({ id: k, answer: this.questionForm[k] }) // answers.push({ id: k, answer: this.questionForm[k] })
} // }
var params = { // var params = {
visitTaskId: this.visitTaskId, // visitTaskId: this.visitTaskId,
answers: answers // answers: answers
} // }
try { // try {
// await saveTaskQuestion(8, params) // await saveTaskQuestion(8, params)
this.$message.success(this.$t('common:message:savedSuccessfully')) // this.$message.success(this.$t('common:message:savedSuccessfully'))
loading.close() // loading.close()
DicomEvent.$emit('getReportInfo', true) // DicomEvent.$emit('getReportInfo', true)
this.refreshQuestions() // this.refreshQuestions()
this.formChanged = false // this.formChanged = false
} catch (e) { // } catch (e) {
console.log(e) // console.log(e)
loading.close() // loading.close()
} // }
}, },
async close(questionsObj) { async close(questionsObj) {
if (questionsObj) { if (questionsObj) {