完善录音时长功能

This commit is contained in:
zhonghua.li
2026-02-07 19:51:03 +08:00
parent 33950f41fd
commit 3944fa6969
52 changed files with 2013 additions and 886 deletions

View File

@@ -50,6 +50,12 @@
<script>
export default {
name: 'QualityCoveragePopup',
props: {
openTrigger: {
type: Number,
default: 0
}
},
data() {
return {
coverageRate: '87.5',
@@ -63,12 +69,34 @@ export default {
]
}
},
watch: {
openTrigger(newVal) {
// 当触发器变化时,自动打开弹窗
if (newVal > 0) {
this.$nextTick(() => {
this.open();
});
}
}
},
methods: {
open() {
this.$refs.popup.open()
// 安全地访问 refs如果组件还未准备好则重试
if (this.$refs && this.$refs.popup) {
this.$refs.popup.open();
} else {
// 如果 refs 还未准备好,延迟重试
setTimeout(() => {
if (this.$refs && this.$refs.popup) {
this.$refs.popup.open();
}
}, 100);
}
},
close() {
this.$refs.popup.close()
if (this.$refs && this.$refs.popup) {
this.$refs.popup.close();
}
},
onPopupChange(e) {
if (!e.show) {