算法广场和能力广场容错处理pic为空
This commit is contained in:
parent
3e1b6b8a22
commit
e29e0f0526
|
@ -106,7 +106,8 @@ const algorithmCardPhoto = (item) => {
|
|||
if(item.pic && typeof item.pic == 'string') {
|
||||
_arr = JSON.parse(item.pic)
|
||||
}
|
||||
let _img = _arr[0] && _arr[0].img || ''
|
||||
let _img = _arr[0] && _arr[0].img || imgSrc.value;
|
||||
console.log('_img------------>', _img);
|
||||
return _img
|
||||
}
|
||||
//跳转详情页
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
</div>
|
||||
<div class="algorithm-class">
|
||||
<div v-for="(item, index) in dataList" :key="`algorithm-${index}`" class="algorithm-card">
|
||||
<a-image :src="item.pic" :width="525" :height="275" :fallback="imgSrc"
|
||||
<a-image :src="item.pic || imgSrc" :width="525" :height="275" :fallback="imgSrc"
|
||||
:preview="false"></a-image>
|
||||
|
||||
<a-tooltip>
|
||||
|
|
Loading…
Reference in New Issue