|
|
@@ -28,6 +28,7 @@ import { useLocation } from "../../lib/use/use-location";
|
|
|
|
|
|
Page({
|
|
|
data: {
|
|
|
+ isShowComplete: false,
|
|
|
careList: [],
|
|
|
displayList: [] as {
|
|
|
id: number;
|
|
|
@@ -118,7 +119,7 @@ Page({
|
|
|
item.carouselMediaList.push({
|
|
|
type: "image",
|
|
|
src: item.photo,
|
|
|
- title: "商品图片",
|
|
|
+ // title: "商品图片",
|
|
|
});
|
|
|
}
|
|
|
|
|
|
@@ -127,7 +128,7 @@ Page({
|
|
|
item.carouselMediaList.push({
|
|
|
type: "image",
|
|
|
src: item.itemImgFirst,
|
|
|
- title: "操作图片",
|
|
|
+ // title: "操作图片",
|
|
|
});
|
|
|
}
|
|
|
|
|
|
@@ -136,8 +137,8 @@ Page({
|
|
|
item.carouselMediaList.push({
|
|
|
type: "video",
|
|
|
src: item.itemVideoFirst,
|
|
|
- poster: item.photo || item.itemImgFirst, // 使用photo或itemImgFirst作为视频封面
|
|
|
- title: "操作视频",
|
|
|
+ poster: item.photo || item.itemImgFirst,
|
|
|
+ // title: "操作视频",
|
|
|
});
|
|
|
}
|
|
|
|
|
|
@@ -145,13 +146,11 @@ Page({
|
|
|
if (item.carouselMediaList.length === 0) {
|
|
|
item._mediaLoaded = true;
|
|
|
} else {
|
|
|
- // 模拟加载过程,3秒后自动标记为已加载(防止一直显示加载状态)
|
|
|
setTimeout(() => {
|
|
|
if (!item._mediaLoaded) {
|
|
|
this.setData({
|
|
|
[`careList[${index}]._mediaLoaded`]: true,
|
|
|
});
|
|
|
- // 同时更新 displayList
|
|
|
const displayIndex = this.data.displayList.findIndex(
|
|
|
(displayItem: any) => displayItem.id === item.id
|
|
|
);
|
|
|
@@ -170,14 +169,11 @@ Page({
|
|
|
careList: res,
|
|
|
});
|
|
|
|
|
|
- // 然后更新 displayList,确保 carouselMediaList 的变化能被监听到
|
|
|
await this.updateDisplayList();
|
|
|
|
|
|
- // 强制触发一次 carouselMediaList 的更新,确保 observer 被调用
|
|
|
setTimeout(() => {
|
|
|
res.forEach((item: any, index: number) => {
|
|
|
if (item.carouselMediaList && item.carouselMediaList.length > 0) {
|
|
|
- // 通过 setData 重新设置 carouselMediaList,触发 observer
|
|
|
this.setData({
|
|
|
[`careList[${index}].carouselMediaList`]: [
|
|
|
...item.carouselMediaList,
|
|
|
@@ -455,6 +451,11 @@ Page({
|
|
|
this.setData({
|
|
|
statusList: arr2,
|
|
|
});
|
|
|
+ if(!data?.healthAnalysisReportId){
|
|
|
+ this.setData({
|
|
|
+ isShowComplete: true,
|
|
|
+ });
|
|
|
+ }
|
|
|
} catch (error) {
|
|
|
this.setData({
|
|
|
"healthReport.data": [],
|