fix:bug修复

master
blak-kong 2 years ago
parent 0459a45ab4
commit 0e2d775ebe

@ -0,0 +1,53 @@
import Taro from "@tarojs/taro";
import { Component, PropsWithChildren } from "react";
import "./app.less";
// // html4
// import "@tarojs/taro/html.css";
// // html5
// import "@tarojs/taro/html5.css";
import { Provider } from "react-redux";
import store from "./store";
import "./iconfont/iconfont.css";
import "taro-ui/rn/style/components/icon.scss";
import { go } from "./utils/traoAPI";
class App extends Component {
// 可以使用所有的 React 生命周期方法
componentDidMount() {}
// 对应 onLaunch
onLaunch(options) {
// console.log("onLaunch", options);
if (options.scene == 1007 || options.scene == 1008) {
return;
}
// go("/pages/iotCarePlan/iotCarePlan");
// go("/pages/instrument_clickin_upload/index");
// go("/pages/instrument/intro");
// Taro.switchTab({
// url: "/pages/user/user",
// });
go("/pages/index/index");
}
onError(error) {
console.log("error 错误捕获", error);
}
// 对应 onShow
componentDidShow() {}
// 对应 onHide
componentDidHide() {}
// this.props.children 是将要会渲染的页面
render() {
// return this.props.children
return <Provider store={store} children={this.props.children}></Provider>;
}
}
export default App;

@ -952,7 +952,7 @@ class ConnectionBluetoot extends Component<any, any> {
// 超时未返回版本号
if (isGetVersionTimer) clearTimeout(isGetVersionTimer);
console.log("超时未返回版本号 this.pairingChange", this.state);
// this.pairingChange(this.state);
this.pairingChange(this.state);
} else {
this.sendGetVersion();
}
@ -1022,7 +1022,7 @@ class ConnectionBluetoot extends Component<any, any> {
};
render() {
let { name, isConnection, connectionSuccess, error } = this.state;
let { isConnection, connectionSuccess, error } = this.state;
let { deviceInfo, isDisconnect } = this.props;
return (
<Block>
@ -1037,7 +1037,6 @@ class ConnectionBluetoot extends Component<any, any> {
error={error}
title="面罩模式启动中"
/>
<View>{name}</View>
</Block>
);
}

@ -36,7 +36,12 @@ export default class Navbar extends Component<any, any> {
}
back = () => {
back();
//判断是否自定义跳转
if (!this.props.isCustomBack) {
back();
} else {
this.props.customBack();
}
};
setStatusBar() {
@ -44,7 +49,8 @@ export default class Navbar extends Component<any, any> {
success: (res) => {
const statusBarHeight = res.statusBarHeight || 0;
// 获取微信胶囊的位置信息 width,height,top,right,left,bottom
const custom = Taro.getMenuButtonBoundingClientRect();
// const custom = Taro.getMenuButtonBoundingClientRect();
const custom = { height: 60, top: 20 };
// 导航栏高度(标题栏高度) = 胶囊高度 + (顶部距离 - 状态栏高度) * 2
const navigationBarHeight =
custom.height + (custom.top - statusBarHeight) * 2;

Binary file not shown.

Before

Width:  |  Height:  |  Size: 80 KiB

After

Width:  |  Height:  |  Size: 22 KiB

@ -97,6 +97,10 @@ export default class Index extends Component<any, any> {
async initData() {}
GoIndex = () => {
Taro.switchTab({ url: "/pages/index/index" });
};
render() {
let { name, statistics, recordList, recordData } = this.state;
return (
@ -221,7 +225,7 @@ export default class Index extends Component<any, any> {
<View className="footer flex aitems">
<View className="btn"></View>
<View className="text flex aitems">
<View></View>
<View onClick={this.GoIndex}></View>
<Image
src={require("../../img/right.png")}
mode="aspectFill"

@ -60,7 +60,7 @@ import commandMap from "@/utils/commandMap";
import InstrumentTypeEnum from "@/components/bluetoot/InstrumentTypeEnum";
import OtaDeviceTypeEnum from "@/components/bluetoot/OtaDeviceTypeEnum";
const log = require("@/utils/log");
// const log = require("@/utils/log");
class Index extends Component<any, any> {
// pageCtx = Taro.getCurrentInstance().page;
@ -447,8 +447,6 @@ class Index extends Component<any, any> {
}
}
closeBinding = () => {
Taro.removeStorageSync("isScan"); // 扫码弹窗显示完后,不需要再判断是否扫码
Taro.removeStorageSync("serial"); // 扫码弹窗显示完后,删除缓存的扫码序列号
this.setState({ isVisibleBinding: false });
};
confirmBinding = () => {
@ -500,6 +498,9 @@ class Index extends Component<any, any> {
// 获取失败和绑定失败一个弹窗
this.setState({ isBindingError: true });
}
Taro.removeStorageSync("isScan"); // 扫码弹窗显示完后,不需要再判断是否扫码
Taro.removeStorageSync("serial"); // 扫码弹窗显示完后,删除缓存的扫码序列号
}
};
@ -564,16 +565,12 @@ class Index extends Component<any, any> {
console.log("exchangeBinding", data);
Taro.hideLoading();
this.closeBinding();
if (data.code === 200) {
} else {
this.closeBinding();
this.setState({ isBindingError: true });
if (data.code !== 200) {
//todo
}
};
// 仪器绑定失败弹窗
onBindErrorClose = () => {
Taro.removeStorageSync("isScan"); // 扫码弹窗显示完后,不需要再判断是否扫码
Taro.removeStorageSync("serial"); // 扫码弹窗显示完后,删除缓存的扫码序列号
this.setState({ isBindingError: false });
};
onBindErrorConfirm = () => {
@ -581,8 +578,6 @@ class Index extends Component<any, any> {
go("/pages/consultant/consultant");
};
onBeforeBindClose = () => {
Taro.removeStorageSync("isScan"); // 扫码弹窗显示完后,不需要再判断是否扫码
Taro.removeStorageSync("serial"); // 扫码弹窗显示完后,删除缓存的扫码序列号
this.setState({ isBeforeBinding: false });
};
onBeforeBindConfirm = () => {
@ -714,6 +709,7 @@ class Index extends Component<any, any> {
);
this.setState({
isShowVersionUpgrading: false,
isShowVersionUpgradFinish: true, // 升级介绍
versionUpgradFinishNodes: nodes,
});
};
@ -887,7 +883,7 @@ class Index extends Component<any, any> {
upgradeFun={this.upgradeFun}
/>
)}
<PopupConfirm
<PopupAlert
isLarge
isClose
isShow={isShowUpdateVersionTip}
@ -899,7 +895,6 @@ class Index extends Component<any, any> {
</Block>
}
textAlgin="center"
cancelButtonText="取消"
confirmButtonText="确定"
close={this.cancelUpdateVersionTip}
confirm={this.confirmUpdateVersionTip}
@ -1081,3 +1076,4 @@ const mapDispatchToProps = (dispatch) => ({
},
});
export default connect(mapStateToProps, mapDispatchToProps)(Index);
// instrumentId

@ -18,7 +18,7 @@ import {
} from "@tarojs/components";
import { InstrumentInfo } from "@/utils/Interface";
import { go, back, msg, setStorageSync, getStorageSync } from "@/utils/traoAPI";
import { go, msg, setStorageSync, getStorageSync } from "@/utils/traoAPI";
import { getImgInfo, contraction } from "@/utils/compressImage";
@ -63,15 +63,27 @@ export default class Instrument extends Component<any, any> {
fromUrl: "",
};
}
$instance = Taro.getCurrentInstance();
isOnly: boolean = false;
currentDevice: any = null;
id: any = "";
async onLoad() {
this.unbindingInstrumentInfoList();
}
async onLoad() {}
componentDidMount() {}
componentWillUnmount() {}
componentDidShow() {}
componentDidShow() {
let params: any = this.$instance.router?.params;
if (params?.isOnly && params?.id) {
if (params?.isOnly === "true") {
this.isOnly = true;
this.id = params?.id;
}
}
console.log("params", params);
this.unbindingInstrumentInfoList();
}
componentDidHide() {}
@ -85,18 +97,6 @@ export default class Instrument extends Component<any, any> {
this.setState({ channelInfo });
};
// onScanCode() {
// Taro.scanCode({
// scanType: ["qrCode"],
// success: (res) => {
// let { channelInfo } = this.state;
// channelInfo.serialCode = res.result;
// this.setState({ channelInfo });
// },
// });
// }
onTipShow = () => {
this.setState({ tipShow: true });
};
@ -140,88 +140,6 @@ export default class Instrument extends Component<any, any> {
});
};
// getBindCodeInfo = async () => {
// const { bindCode, instrumentList, channelInfo } = this.state;
// // // 1.查询资料
// // try {
// // const { data } = await InstrumentCodeCheck({
// // code: bindCode,
// // });
// // const bindCodeInfo = { ...data.data.bindCodeInfo };
// // // 2.判断是否是选中的仪器, 如果不是, 直接弹出scanErrorPopup
// // if (channelInfo.id != bindCodeInfo.instrument_id) {
// // this.setState({
// // bindPopup: "scanErrorPopup",
// // });
// // return;
// // }
// // const match = instrumentList.find((item) => {
// // if (item.id == bindCodeInfo.instrument_id && item.serial) {
// // // 找到同一个仪器
// // bindCodeInfo.hadBindSame = true;
// // if (item.serial == bindCodeInfo.antifakeCode) {
// // // 找到同一个序列号
// // bindCodeInfo.hadBindSameCode = true;
// // } else {
// // bindCodeInfo.hadBindSameCode = false;
// // }
// // return item;
// // }
// // if (item.id == bindCodeInfo.instrument_id) {
// // const { channelInfo } = this.state;
// // if (channelInfo.id === item.id) return;
// // this.setState({
// // channelInfo: item,
// // isVideo: isVideo(item.bind_intro_video),
// // });
// // }
// // });
// // if (match) {
// // bindCodeInfo.hadBind = true;
// // } else {
// // bindCodeInfo.hadBindSame = false;
// // }
// // this.setState({
// // bindCodeInfo,
// // });
// // this.judgeBindCode();
// // } catch (e) {
// // this.judgeBindCode();
// // }
// };
// judgeBindCode = () => {
// const { bindCode, bindCodeInfo } = this.state;
// const opts: any = {};
// if (bindCode && !bindCodeInfo) {
// // 有仪器码, 但是没有找到信息时
// opts.bindPopup = "noFoundPopup";
// } else if (bindCode && bindCodeInfo && bindCodeInfo.isLabelCode) {
// opts.bindPopup = "labelPopup";
// } else if (
// bindCode &&
// bindCodeInfo.hadBindSame &&
// bindCodeInfo.hadBindSameCode
// ) {
// // 有仪器码, 如果有登录, 判断是绑定了同样的仪器和仪器的序列号是一致 -- 不弹弹窗, 回到首页
// opts.bindCode = ""; // 重置bindCode
// opts.bindPopup = ""; // 隐藏bindPopup
// } else if (
// bindCode &&
// bindCodeInfo.hadBindSame &&
// !bindCodeInfo.hadBindSameCode
// ) {
// // 有仪器码, 如果有登录, 判断是绑定了同样的仪器, 但仪器的序列号不一致 -- 判断换绑
// opts.bindPopup = "switchBindCodePopup";
// } else if (bindCode && !bindCodeInfo.hadBindSame) {
// // 有仪器码, 如果有登录, 判断不是绑定了同样的仪器 -- 绑定
// opts.bindPopup = "toBindPopup";
// }
// if (Object.keys(opts).length) {
// this.setState(opts);
// }
// };
onCustomerTap = () => {
this.onCancelBind2Tap();
go("/pages/consultant/consultant");
@ -271,10 +189,6 @@ export default class Instrument extends Component<any, any> {
});
}
public back = () => {
back();
};
closeDev = () => {
// go("/pages/user/user");
let isInstrumentJump = Taro.getStorageSync("isInstrumentJump");
@ -297,13 +211,23 @@ export default class Instrument extends Component<any, any> {
let { data } = await InstrumentInfo.unbindingInstrumentInfoList();
if (data.code === 200) {
if (data.data.length) {
let item = data.data[0];
item.serialCode = "";
this.setState({
equipmentList: data.data,
channelInfo: item,
isVideo: this.isVideo(item.banner),
});
if (!this.isOnly) {
let item = data.data[0];
item.serialCode = "";
this.setState({
equipmentList: data.data,
channelInfo: item,
isVideo: this.isVideo(item.banner),
});
} else {
let item = data.data.find((item) => String(item.id) === this.id);
item.serialCode = "";
this.setState({
equipmentList: [item],
channelInfo: item,
isVideo: this.isVideo(item.banner),
});
}
}
}
};
@ -385,6 +309,10 @@ export default class Instrument extends Component<any, any> {
this.setState({ isBindingCheckError: false });
};
customBack = () => {
Taro.switchTab({ url: "/pages/index/index" });
};
render() {
let {
isBindingError,
@ -406,7 +334,12 @@ export default class Instrument extends Component<any, any> {
close={this.closeDev}
confirm={this.closeDev}
/> */}
<Navbar titleSlot="仪器绑定" isBack={true} />
<Navbar
titleSlot="仪器绑定"
isBack
isCustomBack
customBack={this.customBack}
/>
<PopupAlert
isShow={isBindingError}
title="提示"

@ -41,7 +41,7 @@ class Intro extends Component<any, any> {
// this.getInstrumentInfo(params.id);
// }
let strObj = getStorageSync("instrument_item");
let strObj = getStorageSync("instrument_detail");
if (strObj) {
let instrument = JSON.parse(strObj);
this.getInstrumentInfo(instrument.id);
@ -88,7 +88,7 @@ class Intro extends Component<any, any> {
// setStorageSync("introduceId", info.id);
// }
const url = "/pages/index/index";
Taro.switchTab({
Taro.switchTab({
url,
});
}

@ -70,16 +70,16 @@ export default class InstrumentClickInUpload extends Component<any, any> {
async onLoad() {
this.initData();
}
componentDidMount() { }
componentDidMount() {}
componentWillUnmount() { }
componentWillUnmount() {}
componentDidShow() {
let videoContext = Taro.createVideoContext("myVideo");
this.setState({ videoContext });
}
componentDidHide() { }
componentDidHide() {}
async initData() {
let objStr = getStorageSync("instrument_detail");
@ -127,7 +127,7 @@ export default class InstrumentClickInUpload extends Component<any, any> {
// 获取仪器模式列表
modeInfoList = async (id) => {
let res = await InstrumentInfo.modeInfoList({
instrumentId: "84",
instrumentId: id,
});
if (res.data.code === 200) {
if (res.data.data.length) {
@ -242,15 +242,15 @@ export default class InstrumentClickInUpload extends Component<any, any> {
});
};
videoBindTimeUpdate = async () => { };
videoBindTimeUpdate = async () => {};
videoEnded = async () => { };
videoEnded = async () => {};
videoPause = async () => { };
videoPause = async () => {};
videoPlay = async () => { };
videoPlay = async () => {};
videoLoadedMetaData = async () => { };
videoLoadedMetaData = async () => {};
handleTextareaInput = async (e) => {
let { punchInInfo } = this.state;

@ -45,13 +45,13 @@ export default class InstrumentManage extends Component<any, any> {
async onLoad() {
this.initData();
}
componentDidMount() { }
componentDidMount() {}
componentWillUnmount() { }
componentWillUnmount() {}
componentDidShow() { }
componentDidShow() {}
componentDidHide() { }
componentDidHide() {}
async initData() {
this.bindingInstrumentList();
@ -93,7 +93,7 @@ export default class InstrumentManage extends Component<any, any> {
}
goBind(item) {
let bindid = item.id;
go("/pages/instrument/instrument?id=" + bindid);
go("/pages/instrument/instrument?isOnly=true&id=" + bindid); // 只显示当前仪器内容
}
goBindInfo(item) {
@ -127,100 +127,63 @@ export default class InstrumentManage extends Component<any, any> {
<Block>
<Navbar titleSlot="设备管理" background="#fff" isBack={true} />
<View className="instrument_box">
{bindList.length > 0 &&
{bindList.length > 0 && (
<Block>
<View className="title"></View>
<View className="scroll">
<Swiper
className="bind_list"
current={current}
duration={800}
indicatorDots={false}
indicatorColor="#999"
indicatorActiveColor="#333"
previousMargin="32rpx"
nextMargin="32rpx"
>
{bindList.map((item: any, index: number) => {
return (
<SwiperItem key={index}>
<View className="wrapper" key={"bind_" + index}>
<View className="cover" onClick={this.goIntro}>
<Image
className="Image"
src={item.banner}
mode="aspectFill"
></Image>
<View className="bind_status"></View>
<View className="intro">
<View className="tips" onClick={this.goIntro}>
</View>
<View className="right">
<Image
src={require("../../img/index/right.png")}
mode="widthFix"
style="height: 20rpx;"
/>
</View>
</View>
</View>
<View className="bind_cont">
<View className="title">{item.name}</View>
<View
className="bindinfo"
onClick={this.goBindInfo.bind(this, item)}
>
</View>
</View>
</View>
</SwiperItem>
);
})}
</Swiper>
{/* <ScrollView scroll-x="true" className="bind_list">
{bindList.map((item, index) => {
if (item.status === 0) {
{bindList.length > 0 && (
<Swiper
className="bind_list"
current={current}
duration={800}
indicatorDots={false}
indicatorColor="#999"
indicatorActiveColor="#333"
previousMargin="32rpx"
nextMargin="32rpx"
>
{bindList.map((item: any, index: number) => {
return (
<View className="wrapper" key={"bind_" + index}>
<View className="cover" onClick={this.goIntro}>
<Image
className="Image"
src={item.banner}
mode="aspectFill"
></Image>
<View className="bind_status"></View>
<View className="intro">
<View className="tips" onClick={this.goIntro}>
</View>
<View className="right">
<Image
src={require("../../img/index/right.png")}
mode="widthFix"
style="height: 20rpx;"
/>
<SwiperItem key={index}>
<View className="wrapper" key={"bind_" + index}>
<View className="cover" onClick={this.goIntro}>
<Image
className="Image"
src={item.banner}
mode="aspectFill"
></Image>
<View className="bind_status"></View>
<View className="intro">
<View className="tips" onClick={this.goIntro}>
</View>
<View className="right">
<Image
src={require("../../img/index/right.png")}
mode="widthFix"
style="height: 20rpx;"
/>
</View>
</View>
</View>
</View>
<View className="bind_cont">
<View className="title">{item.name}</View>
<View
className="bindinfo"
onClick={this.goBindInfo.bind(this, item)}
>
<View className="bind_cont">
<View className="title">{item.name}</View>
<View
className="bindinfo"
onClick={this.goBindInfo.bind(this, item)}
>
</View>
</View>
</View>
</View>
</SwiperItem>
);
}
})}
</ScrollView> */}
})}
</Swiper>
)}
</View>
</Block>
}
)}
<View className="title"></View>
<View className="scroll">
<ScrollView scroll-x="true" className="un_bind_list">

@ -91,15 +91,7 @@ function Index({
<View className="v2 battery_icon"></View>
</Block>
)}
{Electricity === 1 && (
<Block>
<View className="v1 battery_icon"></View>
<View className="v2 battery_icon"></View>
<View className="v2 battery_icon"></View>
<View className="v2 battery_icon"></View>
</Block>
)}
{Electricity === 0 && (
{Electricity <= 1 && (
<Block>
<View className="v3 battery_icon"></View>
<View className="v2 battery_icon"></View>

@ -380,9 +380,7 @@ class IotCarePlan extends Component<any, any> {
let { isStandStatus, isShowNurse } = this.state;
// 舱体模式无法对应的时候,置灰开始按钮
let isCabinMode = isStandStatus
? data.isCabinMode === 1
: data.isCabinMode === 0;
let isCabinMode = data.isCabinMode === 1;
if (isStandStatus === isCabinMode) {
this.setState({ isCanClick: true }); // 是否舱体一致时,可以点击
} else {
@ -425,7 +423,7 @@ class IotCarePlan extends Component<any, any> {
this.onStartNurse();
setTimeout(() => {
this.onNursingTap();
}, 500);
}, 1000);
}
};
/** 设备运行中切换模式 */
@ -544,10 +542,8 @@ class IotCarePlan extends Component<any, any> {
// }
let { isStandStatus, ActiveModeItem } = this.state;
let isCabinMode = isStandStatus
? ActiveModeItem.isCabinMode === 1
: ActiveModeItem.isCabinMode === 0;
if (isStandStatus && isCabinMode) {
let isCabinMode = ActiveModeItem.isCabinMode === 1;
if (isStandStatus === isCabinMode) {
this.stepNext();
return;
}
@ -613,12 +609,13 @@ class IotCarePlan extends Component<any, any> {
if (jsonStatus.connectMessage?.connectType == "CONNECTED") {
this.setState({
isStandStatus: true,
isCanClick: this.state.isCabinMode === 1,
isCanClick: this.state.ActiveModeItem?.isCabinMode === 1,
});
} else {
console.log("舱体支架断开连接");
this.setState({
isStandStatus: false,
isCanClick: this.state.isCabinMode !== 1,
isCanClick: this.state.ActiveModeItem?.isCabinMode !== 1,
});
}
break;
@ -637,8 +634,8 @@ class IotCarePlan extends Component<any, any> {
this.setState({
isStandStatus: isStandDevice,
isCanClick: isStandDevice
? this.state.isCabinMode === 1
: this.state.isCabinMode !== 1,
? this.state.ActiveModeItem?.isCabinMode === 1
: this.state.ActiveModeItem?.isCabinMode !== 1,
});
// 连上面罩后, 获取仪器记录, 与缓存信息对比
@ -1048,8 +1045,6 @@ class IotCarePlan extends Component<any, any> {
let totalSeconds = minSecToS(ActiveModeItem.modeTimeStr);
let currentSeconds = minSecToS(currentTime);
let checkTime = totalSeconds - currentSeconds;
console.log("设备已运行多少秒", checkTime);
console.log("ModeStepTimeArray", ModeStepTimeArray);
this.elapsedTime = checkTime;
if (currentSeconds >= 1) {
// 小程序显示倒计时
@ -1062,8 +1057,8 @@ class IotCarePlan extends Component<any, any> {
// 模式多个步骤节点切换
// 已运行时间达到下一节点时,切换
if (checkTime > ModeStepTimeArray[ModeStepIndex]) {
// 已运行时间达到下一节点,步骤切换时更新
if (ModeStepIndex < length) {
// 已运行时间达到下一节点,且存在下一节点,步骤切换时更新
if (ModeStepIndex < length - 1) {
let index = ModeStepIndex + 1; // 提前步骤+1
let currentServiceData = {
startSource: "",
@ -1123,20 +1118,12 @@ class IotCarePlan extends Component<any, any> {
}
}
// // 工作状态,开始组合模式
// if (
// this.state.ActiveModeItem.combineData.length &&
// this.workStatus == MODE_WORKING_ENUM.WORKING
// ) {
// this.startCombinationMode();
// }
const sendParams = {
...deviceCommandSamples.pause,
workMode: ActiveModeItem.modeType, // 使用模式
workStatus: newWorkStatus,
};
console.log("准备发送自定义指令", ActiveModeItem, sendParams);
console.log("准备发送自定义或工作指令", ActiveModeItem, sendParams);
const pauseArrayBuffer = deviceToolKitInstance.toBleCommand(
sendParams as any
);
@ -1188,11 +1175,6 @@ class IotCarePlan extends Component<any, any> {
);
console.log(ActiveModeItem);
console.log("isStandStatus:" + isStandStatus);
console.log(
this.workStatus !== MODE_WORKING_ENUM.WORKING &&
this.workStatus !== MODE_WORKING_ENUM.STANDBY &&
this.workStatus !== MODE_WORKING_ENUM.PAUSE
);
if (facialMaskConnectStatus != 1) {
console.log("facialMaskConnectStatus 开始处", facialMaskConnectStatus);
@ -1222,7 +1204,11 @@ class IotCarePlan extends Component<any, any> {
this.showCountdownFun(downNum, () => {}); // 倒计时弹窗
// 开始执行护理
this.workStatus = MODE_WORKING_ENUM.WORKING; // 不管当前什么状态,直接设为工作状态
this.handleWorkStatus(true, MODE_WORKING_ENUM.WORKING);
this.setState({
isStopNurse: false,
});
}
// 结束护理
@ -1472,16 +1458,16 @@ class IotCarePlan extends Component<any, any> {
console.log("PostNursingLogClock", res);
if (res.data.code === 200) {
if (!isJump) {
if (isJump) {
this.setState({
isShowNursingSuccess: true,
});
}
if (isJump) {
setTimeout(() => {
this.setState({
isShowNursingSuccess: false,
});
this.goFaceReport();
}, 1000);
}, 2000);
}
}
};
@ -1674,6 +1660,8 @@ class IotCarePlan extends Component<any, any> {
/** 完成护理提交:跳转护理报告页 */
goFaceReport = () => {
// 跳转前置空定时器,防止重复提交
if (currentTimeTimer) clearInterval(currentTimeTimer);
go("/pages/face_report/face_report?id=" + this.state.currentDevice.id);
};
@ -1960,3 +1948,5 @@ const mapDispatchToProps = (dispatch) => ({
// },
});
export default connect(mapStateToProps, mapDispatchToProps)(IotCarePlan);
// isCharging

@ -77,10 +77,13 @@ page {
.infobox1 .info2 {
border-radius: 20rpx;
height: 200rpx;
margin: 40rpx 28rpx 0;
display: flex;
justify-content: space-between;
margin: 40rpx 28rpx 0 28rpx;
}
.infobox1 .info3 {
margin: 22rpx 30rpx 0;
margin: 0 30rpx;
margin-top: 22rpx;
font-size: 24rpx;
font-weight: 400;
color: #999999;
@ -98,8 +101,10 @@ page {
display: flex;
flex-direction: column;
justify-content: space-between;
align-items: flex-start;
padding: 36rpx 0 26rpx 36rpx;
box-sizing: border-box;
margin-top: 0;
}
.infobox1 .info2 .block .bg_img {
@ -166,6 +171,7 @@ page {
width: 25%;
flex-direction: column;
position: relative;
margin-top: 0;
.img image {
width: 40rpx;
height: 40rpx;

@ -267,12 +267,12 @@ class User extends Component<any, any> {
)}
</View>
</View>
<View className="info2 flex aitems sa">
<View className="info2">
<View
style="margin-top:0"
className="block"
data-url="/pages/instrument_manage/index?isback=1"
onClick={this.goUrlNoRegister}
// onClick={this.devOpen}
>
<Image
className="bg_img"
@ -289,6 +289,7 @@ class User extends Component<any, any> {
<View className="txt"></View>
</View>
<View
style="margin-top:0"
className="block"
onClick={this.goUrlNoRegister}
data-url="/pages/integral_list/integral_list"
@ -308,10 +309,52 @@ class User extends Component<any, any> {
</View>
</View>
<View className="num">{userInfo.credit}</View>
{/* <View className="txt"></View> */}
<View className="txt"></View>
</View>
</View>
{/* <View className="info2 flex aitems sa">
<View
className="block"
data-url="/pages/instrument_manage/index?isback=1"
onClick={this.goUrlNoRegister}
>
<Image
className="bg_img"
src={require("../../img/device_bg.png")}
mode="aspectFill"
></Image>
<View className="tip flex aitems">
<View className="tip1"></View>
<View className="right">
<Image src="/img/my_right.png" mode="aspectFill" />
</View>
</View>
<View className="num">{userInfo.devicesNum}</View>
<View className="txt"></View>
</View>
<View
className="block"
onClick={this.goUrlNoRegister}
data-url="/pages/integral_list/integral_list"
>
<Image
className="bg_img"
src={require("../../img/point_bg.png")}
mode="aspectFill"
></Image>
<View className="tip flex aitems">
<View className="tip1"></View>
<View className="right">
<Image
src={require("../../img/my_right.png")}
mode="aspectFill"
/>
</View>
</View>
<View className="num">{userInfo.credit}</View>
<View className="txt"></View>
</View>
</View> */}
<View className="info3">
{lastDay} : {userInfo.expireCredit}
</View>
@ -358,7 +401,7 @@ class User extends Component<any, any> {
<View className="tip1"></View>
</View>
</View>
<View className="title2"></View>
<View className="title2"></View>
<View className="info flex aitems">
<View
className="block flex aitems"
@ -389,6 +432,7 @@ class User extends Component<any, any> {
</View>
<View className="tip1"></View>
</View>
<View className="block flex aitems">{/* 样式留空 */}</View>
{/* <View
className="block flex aitems"
data-url="/pages/privacyPolicy/privacyPolicy"

@ -1,7 +1,8 @@
import Taro from "@tarojs/taro";
// var logger = Taro.getRealtimeLogManager ? Taro.getRealtimeLogManager() : null;
var logger = Taro.getRealtimeLogManager();
// var logger = Taro.getRealtimeLogManager();
var logger = console;
const log = {
debug() {

Loading…
Cancel
Save