<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=0"/>
    <meta name="apple-mobile-web-app-capable" content="yes"/>
    <meta name="apple-mobile-web-app-status-bar-style" content="black"/>
    <meta name="format-detection" content="telephone=no"/>
    <title></title>
    <link rel="stylesheet" type="text/css" href="../../lib/css/bootstrap.min.css">
    <link rel="stylesheet" type="text/css" href="./device.css">
    <style type="text/css">
        [v-cloak]{
            display: none;
        }
    </style>
    <script type="text/javascript" src="../../lib/js/p.js"></script>
    <script type="text/javascript" src="../../lib/js/UIOT.js"></script>
</head>
<body ontouchstart="">
    <div id="app" v-cloak>
        <div class="header">
            <v-touch tag="span" class="header-left icon" v-on:tap="onMyInfoTap()">&#xe66f;</v-touch>
            <p>{{ $t('title.device') }}</p>
        </div>
        <div class="content"> 
            <div class="topCpnt">
                <div class="doorbellBg active">
                    <div class="doorbellCircle">
                        <div class="doorbell">
                            <p></p>
                        </div>
                    </div>
                    <div class="doorbellTip" v-bind:class="[{active: doorbellRingingFlag}]"><span>{{ ringingTime }}</span>{{ $t('device.doorLockRinging') }}</div>
                </div>
                <p class="batteryState"><span v-html="batteryState"></span>{{ batteryPercent }}%</p>
            </div>
            <div class="deviceHandle">
                <p class="title">{{ $t('device.newMsgDoorlock') }}</p>
                <u-marquee ref="umarquee" :init-param="componentsConfig.marquee.initParam" :active="activeFlag"></u-marquee>
                <div class="switchGroup">
                    <div class="guoupRow">
                        <!-- 开门记录 -->
                        <div class="col-xs-6 opendoorRecord">
                            <u-switch :value="valueOpendoorRecord" :init-param="componentsConfig.opendoorRecordSwitch.initParam" v-on:u-switch-tap="onOpendoorRecordTap"></u-switch>
                        </div>
                        <!-- 安全报警 -->
                        <div class="col-xs-6 securityAlarm">
                            <u-switch :value="valueSecurityAlarm" :init-param="componentsConfig.securityAlarmSwitch.initParam" v-on:u-switch-tap="onSecurityAlarmTap"></u-switch>
                        </div>
                    </div>
                    <div class="guoupRow">
                        <!-- 门锁用户 -->
                        <div class="col-xs-6 doorlockUser">
                            <u-switch :value="valueDoorlockUser" :init-param="componentsConfig.doorlockUserSwitch.initParam" v-on:u-switch-tap="onDoorlockUserTap"></u-switch>
                        </div>
                        <!-- 劫持报警 -->
                        <div class="col-xs-6 hijackAlarm">
                            <u-switch :value="valueHijackAlarm" :init-param="componentsConfig.hijackAlarmSwitch.initParam" v-on:u-switch-tap="onHijackAlarmTap"></u-switch>
                        </div>
                    </div>
                    <div class="guoupRow">                        
                        <!-- 远程开门 -->
                        <div class="col-xs-6 remoteOpendoor" :class="[{newMsg: remoteOpendoorFlag}]">
                            <u-switch :value="valueRemoteOpendoor" :init-param="componentsConfig.remoteOpendoorSwitch.initParam" v-on:u-switch-tap="onRemoteOpendoorTap"></u-switch>
                        </div>
                        <!-- 门锁管理 -->
                        <div class="col-xs-6 doorlockManage">
                            <u-switch :value="valueDoorlockManage" :init-param="componentsConfig.doorlockManageSwitch.initParam" v-on:u-switch-tap="onDoorlockManageTap"></u-switch>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <transition name="fade">
            <div class="followServiceNumber-dialog" v-show="followShowFlag">
                <div class="followServiceNumber-dialog-box">
                    <ul class="">
                        <li>{{ $t('device.followTitle') }}</li>
                        <li v-html="$t('device.followCont1')"></li>
                        <li v-html="$t('device.followCont2')"></li>
                        <li>
                            <p></p>
                        </li>
                    </ul>
                    <u-button :init-param="componentsConfig.saveQRcodeButton.initParam" v-on:u-button-tap="onSaveQRcodeButtonTap"></u-button>
                    <v-touch tag="p" v-on:tap="onLaterFollowTap">{{ $t('device.laterFollow') }}</v-touch>
                </div>
            </div>
        </transition> 
        <u-dialog ref="udialog" :init-param="componentsConfig.dialog.initParam"></u-dialog>
        <u-loading ref="uloading" :init-param="componentsConfig.loading.initParam"></u-loading>
    </div>

    <script type="text/javascript" src="./index.js" defer async></script>
    
</body>
</html>