From 64e67ad1066c76527422291ace4d24bfa75239f1 Mon Sep 17 00:00:00 2001 From: wangxiaoshuang <825034831@qq.com> Date: Thu, 22 May 2025 13:54:27 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=80=E8=87=B4=E6=80=A7=E6=A0=B8=E6=9F=A5?= =?UTF-8?q?=E5=9B=9E=E5=A4=8D=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/consistencyCheckForm.vue | 4 +- .../components/crcSendMessageNew.vue | 166 +++++++----------- 2 files changed, 68 insertions(+), 102 deletions(-) diff --git a/src/views/trials/trials-panel/visit/consistency-check/components/consistencyCheckForm.vue b/src/views/trials/trials-panel/visit/consistency-check/components/consistencyCheckForm.vue index bd1ab57c..eede1052 100644 --- a/src/views/trials/trials-panel/visit/consistency-check/components/consistencyCheckForm.vue +++ b/src/views/trials/trials-panel/visit/consistency-check/components/consistencyCheckForm.vue @@ -81,10 +81,10 @@ > {{ $t('trials:consistencyCheck:button:sendMessage') }} - +
-
+
{{ $t('trials:consistencyCheck:title:message20') }}
- {{ $t('trials:consistencyCheck:title:add') }} + {{ $t('trials:consistencyCheck:title:add') + }}
- + - + - + - + - + - + - + - + {{ $t('trials:consistencyCheck:title:message10') }} @@ -107,42 +72,24 @@
- + {{ $t('trials:consistencyCheck:button:sendMessage') }}
- +
- + - - + +
@@ -197,7 +144,7 @@ export default { }, mounted() { this.crcMessageInfo.ParamInfoList.forEach(v => { - this.msgList.push({ ...v, IsJoin: true, Ischeck: false }) + this.msgList.push({ ...v, IsJoin: true, IsCheck: false, Id: this.getGuid(String(Date.now())) }) }) this.compareStudy() }, @@ -217,7 +164,9 @@ export default { this.studyVisible = false this.typeInfo = { StudyDate: null, - Modality: null + Modality: null, + IsJoin: false, + IsCheck: true } }, handleSave() { @@ -225,7 +174,7 @@ export default { this.$alert(this.$t('trials:consistencyCheck:title:title2'))// '请选择检查日期和检查类型' return } - this.msgList.push({ ...this.typeInfo }) + this.msgList.push({ ...this.typeInfo, Id: this.getGuid(String(Date.now())) }) this.compareStudy() this.studyVisible = false this.typeInfo = { @@ -248,14 +197,20 @@ export default { this.compareStudy() }) }, - handleReply() { - if (this.msgList.length === 0) { - // '请录入真实的检查情况' - this.$alert(this.$t('trials:consistencyCheck:title:title4')) - return - } - this.$refs.revenusForm.validate((valid) => { + async handleReply() { + try { + if (this.msgList.length === 0) { + // '请录入真实的检查情况' + this.$alert(this.$t('trials:consistencyCheck:title:title4')) + return + } + let valid = await this.$refs.revenusForm.validate() if (!valid) return + let confirm = true + if (this.msgList.every(item => !item.IsCheck)) { + confirm = await this.$confirm(this.$t('trials:consistencyCheck:title:confirm')) + } + if (!confirm) return false var TalkContent = '' // '经核实,该受试者当前访视的实际影像检查如下:
' TalkContent += `${this.$t('trials:consistencyCheck:title:title5')}
` @@ -263,17 +218,25 @@ export default { // `${i + 1}.${v.StudyDate}的${v.Modality}影像检查
` let msg = this.$t('trials:consistencyCheck:title:title6').replace('yyyy', v.StudyDate) msg = msg.replace('xxx', v.Modality) - TalkContent += `${i + 1}. ${msg}
` + let message = `${i + 1}. ${msg}` + let index = this.IRCList.findIndex(item => item.Id === v.Id) + if (!!~index) { + let data = this.IRCList[index] + message += `(${data.IsJoin && !data.IsCheck ? this.$t('trials:consistencyCheck:title:title8') : this.$t('trials:consistencyCheck:title:title9')})
` + } else { + message += `(${this.$t('trials:consistencyCheck:title:title12')})
` + } + TalkContent += message }) if (this.isLackOf) { - TalkContent += '
' - // 'IRC与实际情况不一致影像检查如下:
' - TalkContent += `${this.$t('trials:consistencyCheck:title:title7')}
` - this.IRCList.forEach((v, i) => { - let msg = this.$t('trials:consistencyCheck:title:title6').replace('yyyy', v.StudyDate) - msg = msg.replace('xxx', v.Modality) - TalkContent += `${i + 1}.${msg}(${v.IsJoin && !v.IsCheck ? this.$t('trials:consistencyCheck:title:title8') : this.$t('trials:consistencyCheck:title:title9')})
` - }) + // TalkContent += '
' + // // 'IRC与实际情况不一致影像检查如下:
' + // TalkContent += `${this.$t('trials:consistencyCheck:title:title7')}
` + // this.IRCList.forEach((v, i) => { + // let msg = this.$t('trials:consistencyCheck:title:title6').replace('yyyy', v.StudyDate) + // msg = msg.replace('xxx', v.Modality) + // TalkContent += `${i + 1}.${msg}(${v.IsJoin && !v.IsCheck ? this.$t('trials:consistencyCheck:title:title8') : this.$t('trials:consistencyCheck:title:title9')})
` + // }) if (this.form.reason.length > 0) { TalkContent += '
' // 'IRC与实际情况影像检查不一致的原因为:
' @@ -289,18 +252,21 @@ export default { } console.log(TalkContent) this.$emit('sendMessage', TalkContent, this.closeLoading) - }) + } catch (err) { + console.log(err) + } } } }