diff --git a/src/components/visitSelect/index.vue b/src/components/visitSelect/index.vue new file mode 100644 index 0000000..91540f5 --- /dev/null +++ b/src/components/visitSelect/index.vue @@ -0,0 +1,71 @@ + + + \ No newline at end of file diff --git a/src/views/trials/trials-inspection/components/add-trials-list.vue b/src/views/trials/trials-inspection/components/add-trials-list.vue index a2c8132..478c5d0 100644 --- a/src/views/trials/trials-inspection/components/add-trials-list.vue +++ b/src/views/trials/trials-inspection/components/add-trials-list.vue @@ -208,7 +208,7 @@ export default { this.status = "visit"; this.$emit("getList"); this.$nextTick(() => { - this.$refs.confirmVisit.getList(); + this.$refs.confirmVisit.getList(true); this.$refs.confirmVisit.getSubjectVisitSelectList(); }); } diff --git a/src/views/trials/trials-inspection/components/confirm-visit-list.vue b/src/views/trials/trials-inspection/components/confirm-visit-list.vue index f33c7ce..9588d3c 100644 --- a/src/views/trials/trials-inspection/components/confirm-visit-list.vue +++ b/src/views/trials/trials-inspection/components/confirm-visit-list.vue @@ -78,6 +78,7 @@ :label="$t('trials:uploadDicomList:table:pId')" show-overflow-tooltip min-width="140" + sortable="custom" > + + @@ -136,9 +142,8 @@ export default { appendToBody: true, }, btnLoading: false, - submitMessage: {}, + submitMessage: { SubjectId: null }, selectPatient: [], - tableSelectData: [], subjectIdList: [], rules: { SubjectId: [ @@ -151,6 +156,17 @@ export default { }, }; }, + computed: { + bindPatientTip() { + if (!this.submitMessage.SubjectId) return false; + let PatientList = this.subjectIdList.map((item) => { + if (item.SubjectId === this.submitMessage.SubjectId) { + return item.PatientList; + } + })[0]; + if (PatientList.length <= 0) return false; + }, + }, created() { this.researchProgramNo = this.$route.query.researchProgramNo; this.getTrialSubejctSelectList(this.$route.query.trialId); @@ -200,14 +216,11 @@ export default { this.$refs.confirmVisit.getList(); this.$refs.confirmVisit.getSubjectVisitSelectList(); }); - // this.$emit("update:visible", false); } } catch (err) { this.btnLoading = false; console.log(err); } - // this.$emit("update:visible", false); - // this.$emit("handleOpenDialog", {}, "confirm"); }, // 获取受试者列表 async getTrialSubejctSelectList(id) { @@ -223,58 +236,14 @@ export default { console.log(err); } }, - // 获取列表 - async getList() { - let data = {}; - Object.keys(this.searchData).forEach((key) => { - data[key] = this.searchData[key]; - }); - if (this.dateValue[0] && this.dateValue[1]) { - data.EarliestStudyTime = this.dateValue[0].toISOString(); - data.LatestStudyTime = this.dateValue[1].toISOString(); - } else { - data.EarliestStudyTime = null; - data.LatestStudyTime = null; + // 打开患者弹框 + openPatientList() { + if (!this.submitMessage.SubjectId) { + return this.$message.warning( + this.$t("trials:inscept:rules:selectOrInputSubject") + ); } - try { - this.loading = true; - let res = await getPatientInitList(data); - this.loading = false; - if (res.IsSuccess) { - this.list = res.Result.CurrentPageData; - this.total = res.Result.TotalCount; - } - } catch (err) { - this.loading = false; - console.log(err); - } - }, - // 查询 - handleSearch() { - this.getList(); - }, - // 重置 - handleReset() { - this.reset(); - this.getList(); - }, - // 初始化 - reset() { - this.searchData = defaultSearchData(); - this.dateValue = []; - this.$refs.addSubjectList.clearSort(); - }, - // 表格选择 - handleSelectChange(selection) { - this.tableSelectData = selection; - }, - // 排序 - handleSortByColumn() { - this.searchData.SortField = sort.prop; - if (sort.order === "ascending") this.searchData.Asc = true; - if (sort.order === "descending") this.searchData.Asc = false; - if (!sort.order) this.searchData.SortField = null; - this.getList(); + this.patient_model.visible = true; }, }, }; diff --git a/src/views/trials/trials-panel/subject/subject-list/components/patient-list.vue b/src/views/trials/trials-panel/subject/subject-list/components/patient-list.vue index 6912040..c0968bc 100644 --- a/src/views/trials/trials-panel/subject/subject-list/components/patient-list.vue +++ b/src/views/trials/trials-panel/subject/subject-list/components/patient-list.vue @@ -107,12 +107,13 @@ show-overflow-tooltip min-width="140" > - + + + + + { + return {}; + }, + }, }, data() { return { @@ -203,6 +230,7 @@ export default { data[key] = this.searchData[key]; }); data.TrialId = this.$route.query.trialId; + data.SubjectId = this.submitMessage.SubjectId; try { this.loading = true; let res = await getPatientInitList(data); diff --git a/src/views/trials/trials-panel/trial-summary/trial-information/index.vue b/src/views/trials/trials-panel/trial-summary/trial-information/index.vue index 4f12593..007d6ec 100644 --- a/src/views/trials/trials-panel/trial-summary/trial-information/index.vue +++ b/src/views/trials/trials-panel/trial-summary/trial-information/index.vue @@ -91,7 +91,7 @@