测试横屏

master
blak-kong 2 years ago
parent e909ed328d
commit c76c055467

@ -124,7 +124,7 @@ class ConnectionBluetoot extends Component<any, any> {
// "FR200", // FR200
],
currentDeviceType: "", // 现在的设备类型: WE200 WL200
currentDeviceType: "", // 现在的设备类型: WE200 WL200 FR200当设备为WL200时它还可能是WE200
};
}

@ -110,26 +110,69 @@ export default class DeviceConnectPopup extends Component<any, any> {
<View
className={classnames("common-popup-title", "margin-samll")}
>
{data.bluetoothConnectingTitle}
{data.model === "WL200" && (
<Block>
{currentDeviceType !== "WE200"
? data.bluetoothConnectingTitle
: data.we200BluetoothConnectingTitle}
</Block>
)}
{data.model !== "WL200" && (
<Block>{data.bluetoothConnectingTitle}</Block>
)}
</View>
<View className="device-popup-content-box">
{!this.isImage(data.bluetoothConnecting) ? (
<Video
className="videos"
autoplay
loop
objectFit="cover"
enablePlayGesture
showFullscreenBtn={false}
playBtnPosition="center"
src={encodeURIComponent(data.bluetoothConnecting)}
/>
) : (
<Image
className="images"
src={data.bluetoothConnecting}
mode="aspectFill"
/>
{data.model === "WL200" && (
<Block>
{!this.isImage(data.bluetoothConnecting) ? (
<Video
className="videos"
autoplay
loop
objectFit="cover"
enablePlayGesture
showFullscreenBtn={false}
playBtnPosition="center"
src={
currentDeviceType !== "WE200"
? data.bluetoothConnecting
: data.we200BluetoothConnecting
}
/>
) : (
<Image
className="images"
src={
currentDeviceType !== "WE200"
? data.bluetoothConnecting
: data.we200BluetoothConnecting
}
mode="aspectFill"
/>
)}
</Block>
)}
{data.model !== "WL200" && (
<Block>
{!this.isImage(data.bluetoothConnecting) ? (
<Video
className="videos"
autoplay
loop
objectFit="cover"
enablePlayGesture
showFullscreenBtn={false}
playBtnPosition="center"
src={data.bluetoothConnecting}
/>
) : (
<Image
className="images"
src={data.bluetoothConnecting}
mode="aspectFill"
/>
)}
</Block>
)}
<View className="blue-device-tips">

@ -0,0 +1,5 @@
export default definePageConfig({
navigationBarTitleText: '首页',
enablePullDownRefresh: false,
enablePageMeta: true
})

@ -20,6 +20,7 @@ import {
Video,
Input,
Button,
PageMeta,
} from "@tarojs/components";
import { sendCommand } from "@/utils/bluetoothWXAPI";
@ -2354,198 +2355,208 @@ class IotCarePlanWE200 extends Component<any, any> {
return (
<Block>
<Navbar
titleSlot={title}
isBack
isCustomBack
customBack={this.customBack}
/>
{!isFullScreen && (
<View>
<View catchMove>
<PopupAlert
isShow={isModeLock}
zIndex={10020}
myClassName="level-up"
title="提示"
content="该模式即将上线,敬请期待"
confirmButtonText="我知道了"
textAlgin="center"
close={this.onModeLockClose}
confirm={this.onModeLockClose}
/>
<PopupInstrumentUploadTips
isShow={isFirstTipShow}
zIndex={10020}
myClassName="level-up"
title="打卡介绍"
data={nurseInfo}
close={this.onTipShowClose}
confirm={this.onTipShowClose}
/>
<PopupCountdown isShow={isShowCountdown} countdown={countdown} />
<PopupConfirm
isLarge
isClose
isShow={isEndCarePlan}
title="提示"
content="是否结束护理"
textAlgin="center"
cancelButtonText="取消"
confirmButtonText="确定"
close={this.cancelEndBtn}
confirm={this.confirmEndBtn}
/>
<PopupConfirm
isLarge
isClose
isShow={isSwitchActiveMode}
title="护理模式切换"
content={
<ModeListView
ModeID={ModeID}
activeModeID={activeModeID}
isPop
isShowNurse={isShowNurse}
ModeList={ModeList}
ModeType={ModeType}
onEmit={this.switchModeCurrentFun}
onEmitShowAll={this.openModeSwitch}
onModeLockOpen={this.onModeLockOpen}
/>
}
textAlgin="center"
cancelButtonText="取消"
confirmButtonText="确定"
close={this.cancelModeSwitchBtn}
confirm={this.confirmModeSwitchBtn}
/>
<Popup
show={isShowHistoryMsg}
className="custom-popup"
overlay={false}
>
<View className="sync-history-msg">...</View>
</Popup>
</View>
<PageMeta pageOrientation="landscape">
<Navbar
titleSlot={title}
isBack
isCustomBack
customBack={this.customBack}
/>
{!isFullScreen && (
<View>
<View className="iot-main">
<View className="banner-box">
<View>
<Video
className="video-or-image"
src={currentVideoSrc}
loop
id="myVideo"
objectFit="cover"
enablePlayGesture
showFullscreenBtn={false}
onLoadedMetaData={this.GetVideosTime}
<View catchMove>
<PopupAlert
isShow={isModeLock}
zIndex={10020}
myClassName="level-up"
title="提示"
content="该模式即将上线,敬请期待"
confirmButtonText="我知道了"
textAlgin="center"
close={this.onModeLockClose}
confirm={this.onModeLockClose}
/>
<PopupInstrumentUploadTips
isShow={isFirstTipShow}
zIndex={10020}
myClassName="level-up"
title="打卡介绍"
data={nurseInfo}
close={this.onTipShowClose}
confirm={this.onTipShowClose}
/>
<PopupCountdown
isShow={isShowCountdown}
countdown={countdown}
/>
<PopupConfirm
isLarge
isClose
isShow={isEndCarePlan}
title="提示"
content="是否结束护理"
textAlgin="center"
cancelButtonText="取消"
confirmButtonText="确定"
close={this.cancelEndBtn}
confirm={this.confirmEndBtn}
/>
<PopupConfirm
isLarge
isClose
isShow={isSwitchActiveMode}
title="护理模式切换"
content={
<ModeListView
ModeID={ModeID}
activeModeID={activeModeID}
isPop
isShowNurse={isShowNurse}
ModeList={ModeList}
ModeType={ModeType}
onEmit={this.switchModeCurrentFun}
onEmitShowAll={this.openModeSwitch}
onModeLockOpen={this.onModeLockOpen}
/>
{/* <button onClick={this.executePromises}>点击按钮</button> */}
{errorTips && (
<Block>
<View className="msg-tips">
<Image
className="msg-tips-img"
src={require("@/img/tips.png")}
/>
<View className="msg-tips-content">{errorTips}</View>
</View>
</Block>
)}
</View>
}
textAlgin="center"
cancelButtonText="取消"
confirmButtonText="确定"
close={this.cancelModeSwitchBtn}
confirm={this.confirmModeSwitchBtn}
/>
<Popup
show={isShowHistoryMsg}
className="custom-popup"
overlay={false}
>
<View className="sync-history-msg">...</View>
</Popup>
</View>
<View className="fr200-iot-device">
<View className="item">
<Text className="device-time">
<Text className="time">{currentTime}</Text>
</Text>
<View>
<View className="iot-main">
<View className="banner-box">
<View>
<Video
className="video-or-image"
src={currentVideoSrc}
loop
id="myVideo"
objectFit="cover"
enablePlayGesture
showFullscreenBtn={false}
onLoadedMetaData={this.GetVideosTime}
/>
{/* <button onClick={this.executePromises}>点击按钮</button> */}
{errorTips && (
<Block>
<View className="msg-tips">
<Image
className="msg-tips-img"
src={require("@/img/tips.png")}
/>
<View className="msg-tips-content">
{errorTips}
</View>
</View>
</Block>
)}
</View>
<View className="line" />
<View className="item">
<Text className="gear">{currentGear}</Text>
<View className="fr200-iot-device">
<View className="item">
<Text className="device-time">
<Text className="time">{currentTime}</Text>
</Text>
</View>
<View className="line" />
<View className="item">
<Text className="gear">{currentGear}</Text>
</View>
<View className="line" />
<ElectricityView
Electricity={Electricity}
DeviceConnectStatus={DeviceConnectStatus}
/>
</View>
<View className="line" />
<ElectricityView
Electricity={Electricity}
DeviceConnectStatus={DeviceConnectStatus}
</View>
{ModeList.length > 0 && (
<ModeListView
isPop={false}
isShowNurse={isShowNurse}
ModeList={ModeList}
ModeType={ModeType}
ModeID={ModeID}
activeModeID={activeModeID}
onEmit={this.modeCurrentFun}
onEmitShowAll={this.openModeSwitch}
onModeLockOpen={this.onModeLockOpen}
/>
)}
<button onClick={this.updata.bind(this)}>
{" "}
</button>
{/* <button onClick={this.updata.bind(this)}>添加数据 </button> */}
<View className={classnames({ show: showEcharts })}>
<Echarts
series={series}
full={this.full.bind(this)}
></Echarts>
<EchartsFullScean
series={series}
full={this.full}
></EchartsFullScean>
</View>
</View>
{ModeList.length > 0 && (
<ModeListView
isPop={false}
isShowNurse={isShowNurse}
ModeList={ModeList}
ModeType={ModeType}
ModeID={ModeID}
activeModeID={activeModeID}
onEmit={this.modeCurrentFun}
onEmitShowAll={this.openModeSwitch}
onModeLockOpen={this.onModeLockOpen}
/>
)}
<button onClick={this.updata.bind(this)}> </button>
{/* <button onClick={this.updata.bind(this)}>添加数据 </button> */}
<View className={classnames({ show: showEcharts })}>
<Echarts
series={series}
full={this.full.bind(this)}
></Echarts>
<EchartsFullScean
series={series}
full={this.full}
></EchartsFullScean>
{(ActiveModeItem.modeType === "maskPenetration" ||
ActiveModeItem.modeType === "essence") && (
<Gears
onEmitMinus={this.handleMinus}
onEmitAdd={this.handleAdd}
GearData={GearData}
></Gears>
)}
{ActiveModeItem.modeType === "moistureTest" && (
<WaterTest
isRuningTest={isRuningTest}
stepList={waterStepList}
stepIndex={waterStepIndex}
></WaterTest>
)}
</View>
{(ActiveModeItem.modeType === "maskPenetration" ||
ActiveModeItem.modeType === "essence") && (
<Gears
onEmitMinus={this.handleMinus}
onEmitAdd={this.handleAdd}
GearData={GearData}
></Gears>
)}
{ActiveModeItem.modeType === "moistureTest" && (
<WaterTest
isRuningTest={isRuningTest}
stepList={waterStepList}
stepIndex={waterStepIndex}
></WaterTest>
)}
<Footer
currentWorkModeType={currentWorkModeType}
isRuningTest={isRuningTest}
isStopNurse={isStopNurse}
onEmitStartNurse={this.onStartNurse}
onEmitSwitchChange={this.onSwitchChange}
onEmitEndPlan={this.onEndPlan}
onsuccess={this.onsuccess}
/>
</View>
</View>
)}
{isFullScreen && (
<View>
<button onClick={this.updata.bind(this)}> </button>
<Footer
currentWorkModeType={currentWorkModeType}
isRuningTest={isRuningTest}
isStopNurse={isStopNurse}
onEmitStartNurse={this.onStartNurse}
onEmitSwitchChange={this.onSwitchChange}
onEmitEndPlan={this.onEndPlan}
onsuccess={this.onsuccess}
/>
<EchartsFullScean
series={series}
full={this.full}
></EchartsFullScean>
</View>
</View>
)}
{isFullScreen && (
<View>
<button onClick={this.updata.bind(this)}> </button>
<EchartsFullScean
series={series}
full={this.full}
></EchartsFullScean>
</View>
)}
)}
</PageMeta>
<View></View>
</Block>
);
}

@ -1457,8 +1457,8 @@ class Index extends Component<any, any> {
<Popup show={show} className="custom-popup" overlay={false}>
<View className="popBox"></View>
</Popup>
{/* </PageMeta> */}
{/* <View
{/* </PageMeta>
<View
style="position:fixed;width:100vw;height:100vh"
onClick={this.goTest}
>

Loading…
Cancel
Save