修复视频问题

master
rongweikang 2 years ago
parent 404e01cc1a
commit e01aad14ac

@ -407,9 +407,9 @@ class IotCarePlanFR200 extends Component<any, any> {
this.getInstrumentClockSummary(); this.getInstrumentClockSummary();
this.getInstrumentClockDetail(); this.getInstrumentClockDetail();
} }
componentDidMount() {} componentDidMount() { }
componentWillUnmount() {} componentWillUnmount() { }
componentDidShow() { componentDidShow() {
console.log("页面显示了"); console.log("页面显示了");
@ -1922,7 +1922,6 @@ class IotCarePlanFR200 extends Component<any, any> {
} }
/** 更新WL200护理历史运行时间 */ /** 更新WL200护理历史运行时间 */
updateFR200NursingHistory = (data: any = null, jsonStatus: any = null) => { updateFR200NursingHistory = (data: any = null, jsonStatus: any = null) => {
console.log(11111111);
this.FR200NursingHistory = Taro.getStorageSync("FR200NursingHistory"); this.FR200NursingHistory = Taro.getStorageSync("FR200NursingHistory");
@ -1936,6 +1935,7 @@ class IotCarePlanFR200 extends Component<any, any> {
// 设置正确封面 // 设置正确封面
if (!data) { if (!data) {
if (jsonStatus) { if (jsonStatus) {
this.setState({ Electricity: jsonStatus.battery, currentGear: jsonStatus.gear })
let { timeArr } = this.state; let { timeArr } = this.state;
let newTime = this.formatTime( let newTime = this.formatTime(
jsonStatus.totalWorkingMinutes, jsonStatus.totalWorkingMinutes,
@ -1948,10 +1948,12 @@ class IotCarePlanFR200 extends Component<any, any> {
} }
}); });
if (flag) { if (flag) {
return; this.switchVideoPause()
return
} }
timeArr.push(newTime); this.switchVideoPlay()
this.setState({ timeArr }); timeArr.push(newTime)
this.setState({ timeArr })
// 缓存每秒数据 // 缓存每秒数据
if (!params.dataArray) params.dataArray = []; if (!params.dataArray) params.dataArray = [];
params.dataArray.push(jsonStatus); params.dataArray.push(jsonStatus);
@ -2293,11 +2295,11 @@ class IotCarePlanFR200 extends Component<any, any> {
let report = true; let report = true;
go( go(
"/recoding/pages/face_report_one/face_report_one?id=" + "/recoding/pages/face_report_one/face_report_one?id=" +
ids + ids +
"&report=" + "&report=" +
report + report +
"&obj=" + "&obj=" +
JSON.stringify(obj) JSON.stringify(obj)
); );
} else if ("moistureTest" === nursingData.workMode) { } else if ("moistureTest" === nursingData.workMode) {
console.log("水分测试"); console.log("水分测试");
@ -2308,11 +2310,11 @@ class IotCarePlanFR200 extends Component<any, any> {
go( go(
"/recoding/pages/face_report/face_report?id=" + "/recoding/pages/face_report/face_report?id=" +
deviceid + deviceid +
"&recordId=" + "&recordId=" +
currentDevice + currentDevice +
"&report=" + "&report=" +
report report
); );
} }
}; };
@ -2651,9 +2653,9 @@ class IotCarePlanFR200 extends Component<any, any> {
deviceInfo={currentDevice} deviceInfo={currentDevice}
close={this.connectionClose} close={this.connectionClose}
isDisconnect={!isConnectionBlutoot} isDisconnect={!isConnectionBlutoot}
offlineChange={() => {}} offlineChange={() => { }}
pairingChange={this.pairingChange} pairingChange={this.pairingChange}
upgradeFun={() => {}} upgradeFun={() => { }}
/> />
)} )}
@ -2675,7 +2677,8 @@ class IotCarePlanFR200 extends Component<any, any> {
className="video-or-image" className="video-or-image"
src={currentVideoSrc} src={currentVideoSrc}
loop loop
id="myVideo" id='myVideo'
controls={false}
muted={videoVoiceStatus} muted={videoVoiceStatus}
objectFit="cover" objectFit="cover"
showFullscreenBtn={false} showFullscreenBtn={false}
@ -2702,9 +2705,8 @@ class IotCarePlanFR200 extends Component<any, any> {
onClick={this.videoVoiceStatusChange.bind(this)} onClick={this.videoVoiceStatusChange.bind(this)}
> >
<Image <Image
src={require(`@/img/${ src={require(`@/img/${videoVoiceStatus ? "mute" : "play"
videoVoiceStatus ? "mute" : "play" }.png`)}
}.png`)}
mode="aspectFill" mode="aspectFill"
></Image> ></Image>
</View> </View>

@ -9,11 +9,13 @@
height: 160rpx; height: 160rpx;
background-color: #fff; background-color: #fff;
border-radius: 30rpx 0rpx 0rpx 30rpx; border-radius: 30rpx 0rpx 0rpx 30rpx;
box-shadow: 1rpx 2rpx 16rpx 2rpx rgba(97, 97, 97, 0.1); box-shadow: -60rpx 0 60rpx rgba(240,240,240,1);
text-align: center; text-align: center;
// align-items: center; // align-items: center;
z-index: 20; z-index: 20;
box-sizing: border-box; box-sizing: border-box;
.title { .title {
font-size: 26rpx; font-size: 26rpx;
text-align: center; text-align: center;

@ -1517,8 +1517,8 @@ class Index extends Component<any, any> {
<View className='index-infobox5'> <View className='index-infobox5'>
{instrumentList.length > 0 && ( {instrumentList.length > 0 && (
<Block> <Block>
<View className="nurse_plan_box flex aitems sb"> <View className='nurse_plan_box flex aitems sb'>
<View className="title"></View> <View className='title'></View>
<View <View
className='txt_box flex jcenter aitems' className='txt_box flex jcenter aitems'
@ -1646,8 +1646,8 @@ class Index extends Component<any, any> {
</Popup> </Popup>
<PopupWe <PopupWe
isShow={isModeLockWE} isShow={isModeLockWE}
title="电流定制" title='电流定制'
textAlgin="center" textAlgin='center'
isClose={false} isClose={false}
close={this.handlepopup} close={this.handlepopup}

Loading…
Cancel
Save