|
@@ -2,7 +2,6 @@ import { Post } from "../../../../lib/request/method";
|
|
|
import { fromHealthReportSymptom } from "../../../../utils/util";
|
|
import { fromHealthReportSymptom } from "../../../../utils/util";
|
|
|
Page({
|
|
Page({
|
|
|
onLoad(options) {
|
|
onLoad(options) {
|
|
|
- // console.log("options", options);
|
|
|
|
|
if (options.id) {
|
|
if (options.id) {
|
|
|
wx.setStorageSync("careId", Number(options.id));
|
|
wx.setStorageSync("careId", Number(options.id));
|
|
|
this.getCareDetail(Number(options.id));
|
|
this.getCareDetail(Number(options.id));
|
|
@@ -21,7 +20,6 @@ Page({
|
|
|
healthReports: [],
|
|
healthReports: [],
|
|
|
statusText: "未知状态",
|
|
statusText: "未知状态",
|
|
|
loading: true,
|
|
loading: true,
|
|
|
- isShow: false,
|
|
|
|
|
isShowDelivery: false,
|
|
isShowDelivery: false,
|
|
|
},
|
|
},
|
|
|
onCardRecord(e: any) {
|
|
onCardRecord(e: any) {
|
|
@@ -64,7 +62,6 @@ Page({
|
|
|
statusText,
|
|
statusText,
|
|
|
});
|
|
});
|
|
|
let isShowDelivery = false;
|
|
let isShowDelivery = false;
|
|
|
- console.log(res.items, "服务包详情数据");
|
|
|
|
|
if (res.items.length > 0) {
|
|
if (res.items.length > 0) {
|
|
|
isShowDelivery = res.items.some((item: any) => {
|
|
isShowDelivery = res.items.some((item: any) => {
|
|
|
return item.conditioningProgramDetail?.isDelivery === "Y";
|
|
return item.conditioningProgramDetail?.isDelivery === "Y";
|
|
@@ -102,20 +99,13 @@ Page({
|
|
|
careDetail: {},
|
|
careDetail: {},
|
|
|
});
|
|
});
|
|
|
}
|
|
}
|
|
|
- if (JSON.stringify(this.data.careDetail) !== "{}") {
|
|
|
|
|
- this.setData({
|
|
|
|
|
- isShow: true,
|
|
|
|
|
- });
|
|
|
|
|
- } else {
|
|
|
|
|
- this.setData({
|
|
|
|
|
- isShow: false,
|
|
|
|
|
- });
|
|
|
|
|
- }
|
|
|
|
|
- } catch (error) {
|
|
|
|
|
- console.log(error);
|
|
|
|
|
|
|
+ } catch (error: any) {
|
|
|
|
|
+ wx.showToast({
|
|
|
|
|
+ title: error.message,
|
|
|
|
|
+ icon: "none",
|
|
|
|
|
+ });
|
|
|
wx.hideLoading();
|
|
wx.hideLoading();
|
|
|
this.setData({
|
|
this.setData({
|
|
|
- isShow: false,
|
|
|
|
|
loading: false,
|
|
loading: false,
|
|
|
});
|
|
});
|
|
|
}
|
|
}
|