40 lines
879 B
Vue
Raw Normal View History

2026-01-28 13:38:05 +08:00
<template>
<evaluation-message
v-if="payload.description === 'PATIENT_RATE_MESSAGE'"
:doctorInfo="doctorInfo"
:extension="extension"
@popupStatusChange="handlePopupStatusChange"
/>
</template>
<script setup>
import { computed } from 'vue';
import evaluationMessage from './evaluation.vue';
const props = defineProps({
message: {
type: Object
},
doctorInfo:{
type: Object,
default: () => ({})
}
});
const emit = defineEmits(['popupStatusChange']);
const payload = computed(() => {
return props.message && props.message.payload ? props.message.payload : {};
})
const extension = computed(() => {
try {
return JSON.parse(payload.value.extension)
} catch (e) {
return {}
}
})
// 处理弹窗状态变化,传递给父组件
const handlePopupStatusChange = (isOpen) => {
emit('popupStatusChange', isOpen);
}
</script>