Commit aaedfb07 by zhuzhequan

fix:修复podcn图片显示问题

parent 0eabaffd
......@@ -403,7 +403,7 @@
</ElFormItem>
<ElFormItem>
<span>
<ElButton type="primary" @click="search" ref="searchBtnRef"
<ElButton ref="searchBtnRef" type="primary" @click="search"
>查询</ElButton
>
</span>
......@@ -5150,6 +5150,17 @@ watch(
(newData) => {
if (!newData?.length) return
newData.forEach((order) => {
const item = order as ProductList
if(item.imageAry){
if(item.imageAry.startsWith('http')){
item.imageAry = JSON.stringify(item.imageAry.split(',').map(e=>{
return {
url:e
}
}))
}
}
if(order.productList){
// 使用可选链和空值合并简化判断
order.productList?.forEach((product) => {
if (!product.previewImgs && product.imageAry) {
......@@ -5164,6 +5175,8 @@ watch(
}
}
})
}
})
},
{ deep: true, immediate: true }, // 添加immediate确保初始化时执行
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment