修复打印预览里面 币种 默认不显示情况

This commit is contained in:
浅念
2025-10-24 16:00:14 +08:00
parent a70ad7a65c
commit 37e75014d0
2 changed files with 24 additions and 18 deletions
+21 -15
View File
@@ -185,20 +185,26 @@
}
})
})
loadCurrencyOptions()
// 设置默认币种
if (props.defaultCurrency) {
selectedCurrency.value = props.defaultCurrency
} else {
selectedCurrency.value = 'USD'
}
// 监听 visible 变化,加载币种选项
watch(
() => props.visible,
(newVisible) => {
if (newVisible) {
loadCurrencyOptions()
// 设置默认币种
if (props.defaultCurrency) {
selectedCurrency.value = props.defaultCurrency
} else {
selectedCurrency.value = 'USD'
}
}
}
)
// watch(
// () => props.visible,
// (newVisible) => {
// if (newVisible) {
// loadCurrencyOptions()
// // 设置默认币种
// if (props.defaultCurrency) {
// selectedCurrency.value = props.defaultCurrency
// } else {
// selectedCurrency.value = 'USD'
// }
// }
// }
// )
</script>
+3 -3
View File
@@ -29,14 +29,14 @@
>
<template #default>
<ElTableColumn label="编号" prop="id" width="100px" />
<el-table-column prop="id" label="内容">
<el-table-column prop="id" label="内容" min-width="300px">
<template #default="scope">
<span v-html="scope.row.content" style="white-space: pre-line"></span>
</template>
</el-table-column>
<ElTableColumn label="发布时间" prop="update_time" />
<ElTableColumn label="发布时间" prop="update_time" width="180px" />
<ElTableColumn label="备注" prop="remark" />
<ElTableColumn fixed="right" label="操作" width="200px">
<ElTableColumn fixed="right" label="操作" width="120px">
<template #default="scope">
<ElRow>
<el-button