uat_us
caiyiling 2024-04-16 14:20:51 +08:00
commit 6d4ae0a616
2 changed files with 397 additions and 221 deletions

View File

@ -3,7 +3,10 @@
<div class="functions" style="text-align: right"> <div class="functions" style="text-align: right">
<!-- 删除 --> <!-- 删除 -->
<el-button <el-button
v-if="(data.SubmitState*1 < 2 || (data.SubmitState === 2 && data.IsQCConfirmedReupload))" v-if="
data.SubmitState * 1 < 2 ||
(data.SubmitState === 2 && data.IsQCConfirmedReupload)
"
v-hasPermi="['trials:trials-panel:visit:crc-upload:delete']" v-hasPermi="['trials:trials-panel:visit:crc-upload:delete']"
:disabled="deleteArr.length === 0" :disabled="deleteArr.length === 0"
type="primary" type="primary"
@ -11,7 +14,7 @@
icon="el-icon-delete" icon="el-icon-delete"
@click="handleBatchDelete" @click="handleBatchDelete"
> >
{{ $t('trials:uploadedDicoms:action:delete') }} {{ $t("trials:uploadedDicoms:action:delete") }}
</el-button> </el-button>
<!-- 预览 --> <!-- 预览 -->
<el-button <el-button
@ -21,7 +24,7 @@
icon="el-icon-view" icon="el-icon-view"
@click="handlePreviewAllFiles" @click="handlePreviewAllFiles"
> >
{{ $t('trials:uploadedDicoms:action:preview') }} {{ $t("trials:uploadedDicoms:action:preview") }}
</el-button> </el-button>
</div> </div>
<el-table <el-table
@ -87,7 +90,7 @@
show-overflow-tooltip show-overflow-tooltip
> >
<template slot-scope="scope"> <template slot-scope="scope">
{{ moment(scope.row.StudyTime).format('YYYY-MM-DD') }} {{ moment(scope.row.StudyTime).format("YYYY-MM-DD") }}
</template> </template>
</el-table-column> </el-table-column>
<!-- 上传时间 --> <!-- 上传时间 -->
@ -97,7 +100,11 @@
min-width="80" min-width="80"
show-overflow-tooltip show-overflow-tooltip
/> />
<el-table-column :label="$t('common:action:action')" min-width="100" fixed="right"> <el-table-column
:label="$t('common:action:action')"
min-width="100"
fixed="right"
>
<template slot-scope="scope"> <template slot-scope="scope">
<!-- 预览 --> <!-- 预览 -->
<el-button <el-button
@ -107,10 +114,25 @@
circle circle
@click="handleViewStudy(scope.row)" @click="handleViewStudy(scope.row)"
/> />
<!-- 预览PET-CT数据 -->
<el-button
icon="el-icon-folder"
:title="$t('trials:audit:tab:clinicalData')"
v-if="
['PT、CT', 'CT、PT', 'PET-CT'].includes(scope.row.Modalities) &&
relationInfo.IsHaveStudyClinicalData
"
circle
:disabled="scope.row.IsDeleted"
@click="handlePreviewClinicalData(scope.row)"
/>
<!-- 编辑 --> <!-- 编辑 -->
<el-button <el-button
icon="el-icon-edit-outline" icon="el-icon-edit-outline"
v-if=" (data.SubmitState*1 < 2 || (data.SubmitState === 2 && data.IsQCConfirmedReupload))" v-if="
data.SubmitState * 1 < 2 ||
(data.SubmitState === 2 && data.IsQCConfirmedReupload)
"
v-hasPermi="['trials:trials-panel:visit:crc-upload:edit']" v-hasPermi="['trials:trials-panel:visit:crc-upload:edit']"
title="编辑" title="编辑"
circle circle
@ -119,7 +141,10 @@
/> />
<!-- 删除 --> <!-- 删除 -->
<el-button <el-button
v-if=" (data.SubmitState*1 < 2 || (data.SubmitState === 2 && data.IsQCConfirmedReupload))" v-if="
data.SubmitState * 1 < 2 ||
(data.SubmitState === 2 && data.IsQCConfirmedReupload)
"
v-hasPermi="['trials:trials-panel:visit:crc-upload:delete']" v-hasPermi="['trials:trials-panel:visit:crc-upload:delete']"
icon="el-icon-delete" icon="el-icon-delete"
:title="$t('trials:uploadedDicoms:action:delete')" :title="$t('trials:uploadedDicoms:action:delete')"
@ -138,14 +163,24 @@
custom-class="base-dialog-wrapper" custom-class="base-dialog-wrapper"
width="600px" width="600px"
> >
<div style="padding:10px;border: 1px solid #e0e0e0;max-height:650px;overflow-y: auto;"> <div
style="
padding: 10px;
border: 1px solid #e0e0e0;
max-height: 650px;
overflow-y: auto;
"
>
<el-form ref="studyForm" :model="studyForm" label-width="100px"> <el-form ref="studyForm" :model="studyForm" label-width="100px">
<!-- 检查编号 --> <!-- 检查编号 -->
<el-form-item :label="$t('trials:audit:table:studyId')"> <el-form-item :label="$t('trials:audit:table:studyId')">
<el-input v-model="studyForm.StudyCode" disabled /> <el-input v-model="studyForm.StudyCode" disabled />
</el-form-item> </el-form-item>
<!-- 检查类型 --> <!-- 检查类型 -->
<el-form-item v-if="studyForm.IsDicomData" :label="$t('trials:audit:table:modality')"> <el-form-item
v-if="studyForm.IsDicomData"
:label="$t('trials:audit:table:modality')"
>
<el-input v-model="studyForm.Modalities" disabled /> <el-input v-model="studyForm.Modalities" disabled />
</el-form-item> </el-form-item>
<!-- 检查类型 --> <!-- 检查类型 -->
@ -154,11 +189,21 @@
:label="$t('trials:audit:table:modality')" :label="$t('trials:audit:table:modality')"
prop="Modalities" prop="Modalities"
:rules="[ :rules="[
{ required: true, message: $t('common:ruleMessage:specify'), trigger: 'blur' } {
required: true,
message: $t('common:ruleMessage:specify'),
trigger: 'blur',
},
]" ]"
> >
<el-radio-group v-model="studyForm.Modalities"> <el-radio-group v-model="studyForm.Modalities">
<el-radio v-for="m in trialModalitys" v-show="m !== ''" :key="m" :label="m" style="margin-bottom: 15px;" /> <el-radio
v-for="m in trialModalitys"
v-show="m !== ''"
:key="m"
:label="m"
style="margin-bottom: 15px"
/>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
<!-- 检查部位 --> <!-- 检查部位 -->
@ -166,11 +211,20 @@
:label="$t('trials:audit:table:bodyPart')" :label="$t('trials:audit:table:bodyPart')"
prop="BodyPartForEdit" prop="BodyPartForEdit"
:rules="[ :rules="[
{ required: true, message: $t('common:ruleMessage:specify'), trigger: 'blur' } {
required: true,
message: $t('common:ruleMessage:specify'),
trigger: 'blur',
},
]" ]"
> >
<el-checkbox-group v-model="studyForm.BodyPartForEdit"> <el-checkbox-group v-model="studyForm.BodyPartForEdit">
<el-checkbox v-for="bodyPart in trialBodyPartTypes" :key="bodyPart" :label="bodyPart">{{$fd('Bodypart',bodyPart)}}</el-checkbox> <el-checkbox
v-for="bodyPart in trialBodyPartTypes"
:key="bodyPart"
:label="bodyPart"
>{{ $fd("Bodypart", bodyPart) }}</el-checkbox
>
</el-checkbox-group> </el-checkbox-group>
</el-form-item> </el-form-item>
<!-- 序列数量 --> <!-- 序列数量 -->
@ -178,7 +232,10 @@
<el-input v-model="studyForm.SeriesCount" disabled /> <el-input v-model="studyForm.SeriesCount" disabled />
</el-form-item> </el-form-item>
<!-- 图像数量 --> <!-- 图像数量 -->
<el-form-item v-if="studyForm.InstanceCount" :label="$t('trials:audit:table:instanceCount')"> <el-form-item
v-if="studyForm.InstanceCount"
:label="$t('trials:audit:table:instanceCount')"
>
<el-input v-model="studyForm.InstanceCount" disabled /> <el-input v-model="studyForm.InstanceCount" disabled />
</el-form-item> </el-form-item>
<!-- 检查日期 --> <!-- 检查日期 -->
@ -189,40 +246,77 @@
type="date" type="date"
value-format="yyyy-MM-dd" value-format="yyyy-MM-dd"
format="yyyy-MM-dd" format="yyyy-MM-dd"
style="width:100%;" style="width: 100%"
/> />
</el-form-item> </el-form-item>
</el-form> </el-form>
</div> </div>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button :disabled="btnLoading" size="small" type="primary" @click="editStudyInfoVisible = false"> <el-button
{{ $t('common:button:cancel') }} :disabled="btnLoading"
size="small"
type="primary"
@click="editStudyInfoVisible = false"
>
{{ $t("common:button:cancel") }}
</el-button> </el-button>
<el-button :loading="btnLoading" size="small" type="primary" @click="handleUpdateStudyInfo"> <el-button
{{ $t('common:button:save') }} :loading="btnLoading"
size="small"
type="primary"
@click="handleUpdateStudyInfo"
>
{{ $t("common:button:save") }}
</el-button> </el-button>
</div> </div>
</el-dialog> </el-dialog>
<!--pet-ct临床数据上传-->
<el-dialog
v-if="petVisible"
:show-close="true"
:visible.sync="petVisible"
append-to-body
>
<uploadPetClinicalData
:subject-visit-id="data.Id"
:data="data"
:studyData="rowData"
:allow-add-or-edit="false"
/>
</el-dialog>
</div> </div>
</template> </template>
<script> <script>
import { getSubjectVisitUploadedStudyList, deleteStudyList, updateModality } from '@/api/trials' import {
import moment from 'moment' getSubjectVisitUploadedStudyList,
import { getToken } from '@/utils/auth' deleteStudyList,
updateModality,
} from "@/api/trials";
import moment from "moment";
import { getToken } from "@/utils/auth";
import uploadPetClinicalData from "./uploadPetClinicalData.vue";
export default { export default {
name: 'StudyInfo', name: "StudyInfo",
components: { uploadPetClinicalData },
props: { props: {
data: { data: {
type: Object, type: Object,
default() { default() {
return {} return {};
} },
} },
}, },
data() { data() {
return { return {
editStudyInfoVisible: false, editStudyInfoVisible: false,
studyForm: { StudyCode: '', IsDicomData: true, Modalities: '', BodyPartForEdit: [], SeriesCount: null, StudyTime: '' }, studyForm: {
StudyCode: "",
IsDicomData: true,
Modalities: "",
BodyPartForEdit: [],
SeriesCount: null,
StudyTime: "",
},
deleteArr: [], deleteArr: [],
studyLoading: false, studyLoading: false,
studyList: [], studyList: [],
@ -231,163 +325,192 @@ export default {
relationInfo: null, relationInfo: null,
trialBodyPartTypes: [], trialBodyPartTypes: [],
trialModalitys: [], trialModalitys: [],
btnLoading: false btnLoading: false,
}
// pet-ctlinc
petVisible: false,
rowData: {},
};
}, },
mounted() { mounted() {
this.getStudyInfo() this.getStudyInfo();
}, },
methods: { methods: {
//
handlePreviewClinicalData(row) {
this.rowData = row;
this.petVisible = true;
},
// //
handleEditStudy(row) { handleEditStudy(row) {
this.editStudyInfoVisible = true this.editStudyInfoVisible = true;
this.studyForm = { ...row } this.studyForm = { ...row };
var bodyPart = [] var bodyPart = [];
if (this.studyForm.BodyPartForEdit.indexOf('|') !== -1) { if (this.studyForm.BodyPartForEdit.indexOf("|") !== -1) {
bodyPart = this.studyForm.BodyPartForEdit.split('|') bodyPart = this.studyForm.BodyPartForEdit.split("|");
} else if (this.studyForm.BodyPartForEdit !== '') { } else if (this.studyForm.BodyPartForEdit !== "") {
bodyPart.push(this.studyForm.BodyPartForEdit) bodyPart.push(this.studyForm.BodyPartForEdit);
} }
this.studyForm.BodyPartForEdit = bodyPart this.studyForm.BodyPartForEdit = bodyPart;
}, },
// / // /
handleUpdateStudyInfo() { handleUpdateStudyInfo() {
this.$refs['studyForm'].validate((valid) => { this.$refs["studyForm"].validate((valid) => {
if (!valid) return if (!valid) return;
this.btnLoading = true this.btnLoading = true;
this.studyForm.BodyPart = this.studyForm.BodyPartForEdit.join('|') this.studyForm.BodyPart = this.studyForm.BodyPartForEdit.join("|");
this.studyForm.Modality = this.studyForm.Modalities this.studyForm.Modality = this.studyForm.Modalities;
var params = { var params = {
id: this.studyForm.StudyId, id: this.studyForm.StudyId,
subjectVisitId: this.data.Id, subjectVisitId: this.data.Id,
type: 1, type: 1,
modality: this.studyForm.Modality, modality: this.studyForm.Modality,
bodyPart: this.studyForm.BodyPart bodyPart: this.studyForm.BodyPart,
} };
updateModality(this.data.TrialId, params).then(res => { updateModality(this.data.TrialId, params)
this.btnLoading = false .then((res) => {
this.btnLoading = false;
if (res.IsSuccess) { if (res.IsSuccess) {
this.getStudyInfo() this.getStudyInfo();
this.$message.success(this.$t('common:message:savedSuccessfully')) this.$message.success(
this.editStudyInfoVisible = false this.$t("common:message:savedSuccessfully")
);
this.editStudyInfoVisible = false;
} }
}).catch(() => { this.btnLoading = false })
}) })
.catch(() => {
this.btnLoading = false;
});
});
}, },
getStudyInfo() { getStudyInfo() {
this.studyLoading = true this.studyLoading = true;
getSubjectVisitUploadedStudyList(this.data.Id).then(res => { getSubjectVisitUploadedStudyList(this.data.Id)
this.studyList = res.Result .then((res) => {
this.studyLoading = false this.studyList = res.Result;
this.relationInfo = res.OtherInfo this.studyLoading = false;
console.log(this.relationInfo) this.relationInfo = res.OtherInfo;
this.trialBodyPartTypes = console.log(this.relationInfo);
this.relationInfo.BodyPartTypes ? this.relationInfo.BodyPartTypes.split('|') : [] this.trialBodyPartTypes = this.relationInfo.BodyPartTypes
this.trialModalitys = ? this.relationInfo.BodyPartTypes.split("|")
this.relationInfo.Modalitys ? this.relationInfo.Modalitys.split('|') : [] : [];
console.log(this.trialBodyPartTypes) this.trialModalitys = this.relationInfo.Modalitys
console.log(this.trialModalitys) ? this.relationInfo.Modalitys.split("|")
}).catch(() => { this.studyLoading = false }) : [];
console.log(this.trialBodyPartTypes);
console.log(this.trialModalitys);
})
.catch(() => {
this.studyLoading = false;
});
}, },
// //
handleBatchDelete() { handleBatchDelete() {
this.$confirm(this.$t('trials:uploadedDicoms:message:deleteMes'), { this.$confirm(this.$t("trials:uploadedDicoms:message:deleteMes"), {
type: 'warning', type: "warning",
distinguishCancelAndClose: true distinguishCancelAndClose: true,
}) })
.then(() => { .then(() => {
this.studyLoading = true this.studyLoading = true;
deleteStudyList(this.trialId, this.data.Id, this.deleteArr) deleteStudyList(this.trialId, this.data.Id, this.deleteArr)
.then(res => { .then((res) => {
if (res.IsSuccess) { if (res.IsSuccess) {
this.getStudyInfo() this.getStudyInfo();
this.$emit('getList') this.$emit("getList");
this.$message.success(this.$t('trials:uploadedDicoms:message:deleteSuccessfully')) this.$message.success(
this.$t("trials:uploadedDicoms:message:deleteSuccessfully")
);
} }
}).catch(() => {
this.studyLoading = true
}) })
}).catch(() => {}) .catch(() => {
this.studyLoading = true;
});
})
.catch(() => {});
}, },
// //
handlePreviewAllFiles() { handlePreviewAllFiles() {
var tokenKey = getToken() var tokenKey = getToken();
const routeData = this.$router.resolve({ const routeData = this.$router.resolve({
path: `/showvisitdicoms?trialId=${this.data.TrialId}&visitInfo=${this.data.VisitName}(${this.data.VisitNum})&subjectVisitId=${this.data.Id}&TokenKey=${tokenKey}` path: `/showvisitdicoms?trialId=${this.data.TrialId}&visitInfo=${this.data.VisitName}(${this.data.VisitNum})&subjectVisitId=${this.data.Id}&TokenKey=${tokenKey}`,
}) });
var newWindow = window.open(routeData.href, '_blank') var newWindow = window.open(routeData.href, "_blank");
this.$emit('setOpenWindow',newWindow) this.$emit("setOpenWindow", newWindow);
}, },
// //
handleViewStudy(row) { handleViewStudy(row) {
var token = getToken() var token = getToken();
const routeData = this.$router.resolve({ const routeData = this.$router.resolve({
path: `/showdicom?studyId=${row.StudyId}&TokenKey=${token}&type=Study` path: `/showdicom?studyId=${row.StudyId}&TokenKey=${token}&type=Study`,
}) });
var newWindow =window.open(routeData.href, '_blank') var newWindow = window.open(routeData.href, "_blank");
this.$emit('setOpenWindow',newWindow) this.$emit("setOpenWindow", newWindow);
}, },
// //
handleDeleteStudy(row) { handleDeleteStudy(row) {
this.$confirm(this.$t('trials:uploadedDicoms:message:deleteMes'), { this.$confirm(this.$t("trials:uploadedDicoms:message:deleteMes"), {
type: 'warning', type: "warning",
distinguishCancelAndClose: true distinguishCancelAndClose: true,
}) })
.then(() => { .then(() => {
this.studyLoading = true this.studyLoading = true;
deleteStudyList(this.trialId, this.data.Id, [row.StudyId]) deleteStudyList(this.trialId, this.data.Id, [row.StudyId])
.then(res => { .then((res) => {
if (res.IsSuccess) { if (res.IsSuccess) {
this.getStudyInfo() this.getStudyInfo();
this.$emit('getList') this.$emit("getList");
this.$message.success(this.$t('trials:uploadedDicoms:message:deleteSuccessfully')) this.$message.success(
this.$t("trials:uploadedDicoms:message:deleteSuccessfully")
);
} }
}).catch(() => {
this.studyLoading = true
}) })
}).catch(() => {}) .catch(() => {
this.studyLoading = true;
});
})
.catch(() => {});
}, },
getBodyPart(bodyPart) { getBodyPart(bodyPart) {
if (!bodyPart) return '' if (!bodyPart) return "";
var separator = ',' var separator = ",";
if (bodyPart.indexOf('|') > -1) { if (bodyPart.indexOf("|") > -1) {
separator = '|' separator = "|";
} else if (bodyPart.indexOf(',') > -1) { } else if (bodyPart.indexOf(",") > -1) {
separator = ',' separator = ",";
} else if (bodyPart.indexOf('') > -1) { } else if (bodyPart.indexOf("") > -1) {
separator = '' separator = "";
} }
var arr = bodyPart.split(separator) var arr = bodyPart.split(separator);
var newArr = arr.map(i => { var newArr = arr.map((i) => {
return this.$fd('Bodypart', i.trim()) return this.$fd("Bodypart", i.trim());
}) });
return newArr.join(' | ') return newArr.join(" | ");
}, },
// //
handleSelectionChange(val) { handleSelectionChange(val) {
this.deleteArr = [] this.deleteArr = [];
val.forEach(item => { val.forEach((item) => {
this.deleteArr.push(item.StudyId) this.deleteArr.push(item.StudyId);
}) });
}, },
// //
hasDeleted(row) { hasDeleted(row) {
if (row.IsDeleted) { if (row.IsDeleted) {
return false return false;
} else { } else {
return true return true;
} }
}, },
// //
tableRowClassName({ row, rowIndex }) { tableRowClassName({ row, rowIndex }) {
if (row.IsDeleted) { if (row.IsDeleted) {
return 'delete-row' return "delete-row";
} else { } else {
return '' return "";
}
}
}
} }
},
},
};
</script> </script>
<style lang="scss"> <style lang="scss">
.study-info { .study-info {

View File

@ -9,7 +9,7 @@
icon="el-icon-view" icon="el-icon-view"
@click="handlePreviewAllFiles" @click="handlePreviewAllFiles"
> >
{{ $t('trials:audit:action:preview') }} {{ $t("trials:audit:action:preview") }}
</el-button> </el-button>
</div> </div>
<el-table <el-table
@ -88,7 +88,7 @@
show-overflow-tooltip show-overflow-tooltip
> >
<template slot-scope="scope"> <template slot-scope="scope">
{{ moment(scope.row.StudyTime).format('YYYY-MM-DD') }} {{ moment(scope.row.StudyTime).format("YYYY-MM-DD") }}
</template> </template>
</el-table-column> </el-table-column>
<!-- 上传时间 --> <!-- 上传时间 -->
@ -98,7 +98,11 @@
min-width="80" min-width="80"
show-overflow-tooltip show-overflow-tooltip
/> />
<el-table-column :label="$t('common:action:action')" min-width="100" fixed="right"> <el-table-column
:label="$t('common:action:action')"
min-width="100"
fixed="right"
>
<template slot-scope="scope"> <template slot-scope="scope">
<!-- 预览 --> <!-- 预览 -->
<el-button <el-button
@ -108,123 +112,172 @@
circle circle
@click="handleViewStudy(scope.row)" @click="handleViewStudy(scope.row)"
/> />
<!-- 预览PET-CT数据 -->
<el-button
icon="el-icon-folder"
:title="$t('trials:audit:tab:clinicalData')"
v-if="
['PT、CT', 'CT、PT', 'PET-CT'].includes(scope.row.Modalities) &&
relationInfo.IsHaveStudyClinicalData
"
circle
:disabled="scope.row.IsDeleted"
@click="handlePreviewClinicalData(scope.row)"
/>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<!--pet-ct临床数据预览-->
<el-dialog
v-if="petVisible"
:show-close="true"
:visible.sync="petVisible"
append-to-body
>
<uploadPetClinicalData
:subject-visit-id="data.Id"
:data="data"
:studyData="rowData"
:allow-add-or-edit="false"
/>
</el-dialog>
</div> </div>
</template> </template>
<script> <script>
import { getSubjectVisitUploadedStudyList, deleteStudyList } from '@/api/trials' import {
import { getToken } from '@/utils/auth' getSubjectVisitUploadedStudyList,
import moment from 'moment' deleteStudyList,
} from "@/api/trials";
import { getToken } from "@/utils/auth";
import uploadPetClinicalData from "@/views/trials/trials-panel/visit/crc-upload/components/uploadPetClinicalData.vue";
import moment from "moment";
export default { export default {
name: 'StudyInfo', name: "StudyInfo",
components: { uploadPetClinicalData },
props: { props: {
data: { data: {
type: Object, type: Object,
default() { default() {
return {} return {};
} },
} },
}, },
data() { data() {
return { return {
userTypeEnumInt: zzSessionStorage.getItem('userTypeEnumInt') * 1, userTypeEnumInt: zzSessionStorage.getItem("userTypeEnumInt") * 1,
deleteArr: [], deleteArr: [],
studyLoading: false, studyLoading: false,
studyList: [], studyList: [],
trialId: this.$route.query.trialId, trialId: this.$route.query.trialId,
moment moment,
} // pet-ct
petVisible: false,
rowData: {},
relationInfo: {},
};
}, },
mounted() { mounted() {
this.getStudyInfo() this.getStudyInfo();
}, },
methods: { methods: {
//
handlePreviewClinicalData(row) {
this.rowData = row;
this.petVisible = true;
},
getStudyInfo() { getStudyInfo() {
this.studyLoading = true this.studyLoading = true;
getSubjectVisitUploadedStudyList(this.data.Id).then(res => { getSubjectVisitUploadedStudyList(this.data.Id)
this.studyList = res.Result .then((res) => {
this.studyLoading = false this.studyList = res.Result;
}).catch(() => { this.studyLoading = false }) this.relationInfo = res.OtherInfo;
this.studyLoading = false;
})
.catch(() => {
this.studyLoading = false;
});
}, },
// //
handleBatchDelete() { handleBatchDelete() {
this.$confirm(this.$t('trials:qcCheck:message:delete'), { this.$confirm(this.$t("trials:qcCheck:message:delete"), {
type: 'warning', type: "warning",
distinguishCancelAndClose: true distinguishCancelAndClose: true,
}) })
.then(() => { .then(() => {
this.studyLoading = true this.studyLoading = true;
deleteStudyList(this.trialId, this.data.Id, this.deleteArr) deleteStudyList(this.trialId, this.data.Id, this.deleteArr)
.then(res => { .then((res) => {
if (res.IsSuccess) { if (res.IsSuccess) {
this.getStudyInfo() this.getStudyInfo();
this.$emit('getList') this.$emit("getList");
this.$message.success(this.$t('trials:qcCheck:message:deletedSuccessfully')) this.$message.success(
this.$t("trials:qcCheck:message:deletedSuccessfully")
);
} }
}).catch(() => {
this.studyLoading = true
}) })
}).catch(() => {}) .catch(() => {
this.studyLoading = true;
});
})
.catch(() => {});
}, },
// //
handlePreviewAllFiles() { handlePreviewAllFiles() {
var token = getToken() var token = getToken();
const routeData = this.$router.resolve({ const routeData = this.$router.resolve({
path: `/showvisitdicoms?trialId=${this.data.TrialId}&visitInfo=${this.data.VisitName}(${this.data.VisitNum})&subjectVisitId=${this.data.Id}&TokenKey=${token}` path: `/showvisitdicoms?trialId=${this.data.TrialId}&visitInfo=${this.data.VisitName}(${this.data.VisitNum})&subjectVisitId=${this.data.Id}&TokenKey=${token}`,
}) });
window.open(routeData.href, '_blank') window.open(routeData.href, "_blank");
}, },
// //
handleViewStudy(row) { handleViewStudy(row) {
var token = getToken() var token = getToken();
const routeData = this.$router.resolve({ const routeData = this.$router.resolve({
path: `/showdicom?studyId=${row.StudyId}&TokenKey=${token}&type=Study` path: `/showdicom?studyId=${row.StudyId}&TokenKey=${token}&type=Study`,
}) });
window.open(routeData.href, '_blank') window.open(routeData.href, "_blank");
}, },
getBodyPart(bodyPart) { getBodyPart(bodyPart) {
if (!bodyPart) return '' if (!bodyPart) return "";
var separator = ',' var separator = ",";
if (bodyPart.indexOf('|') > -1) { if (bodyPart.indexOf("|") > -1) {
separator = '|' separator = "|";
} else if (bodyPart.indexOf(',') > -1) { } else if (bodyPart.indexOf(",") > -1) {
separator = ',' separator = ",";
} else if (bodyPart.indexOf('') > -1) { } else if (bodyPart.indexOf("") > -1) {
separator = '' separator = "";
} }
var arr = bodyPart.split(separator) var arr = bodyPart.split(separator);
var newArr = arr.map(i => { var newArr = arr.map((i) => {
return this.$fd('Bodypart', i.trim()) return this.$fd("Bodypart", i.trim());
}) });
return newArr.join(' | ') return newArr.join(" | ");
}, },
// //
handleSelectionChange(val) { handleSelectionChange(val) {
this.deleteArr = [] this.deleteArr = [];
val.forEach(item => { val.forEach((item) => {
this.deleteArr.push(item.StudyId) this.deleteArr.push(item.StudyId);
}) });
}, },
// //
hasDeleted(row) { hasDeleted(row) {
if (row.IsDeleted) { if (row.IsDeleted) {
return false return false;
} else { } else {
return true return true;
} }
}, },
// //
tableRowClassName({ row, rowIndex }) { tableRowClassName({ row, rowIndex }) {
if (row.IsDeleted) { if (row.IsDeleted) {
return 'delete-row' return "delete-row";
} else { } else {
return '' return "";
}
}
}
} }
},
},
};
</script> </script>
<style lang="scss"> <style lang="scss">
.study-info { .study-info {