|
本帖最后由 Mr.ZhouHeng 于 2019-5-10 18:19 编辑
本模块Dmeo补充模块缺陷,
可以根据key失效期 自动更新key
可以切换直播地址跟监控地址
- <!DOCTYPE html>
- <html>
- <head>
- <meta charset="utf-8">
- <meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0" />
- <meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
- <title>视频frm</title>
- <link rel="stylesheet" type="text/css" href="../../../css/api.css" />
- <link rel="stylesheet" type="text/css" href="../../../css/public.css" />
- <style>
- html,
- body {
- width: 100%;
- /*height: 100%;*/
- background: rgba(8, 7, 23, 1)
- }
- .magnetic {
- width: 100%;
- position: relative;
- padding: .4rem .4rem .61rem .4rem;
- background: linear-gradient(-180deg, rgba(66, 71, 86, 1), rgba(8, 7, 23, 1));
- /*background: -webkit-linear-gradient(90deg, #0C0B1B, #383C4A);*/
- }
- .video {
- height: 7.33rem;
- line-height: 7.33rem;
- text-align: center;
- background: rgba(238, 238, 238, 1);
- border-radius: 5px;
- }
- .video-botom {
- margin-top: 1.2rem;
- margin-bottom: .53rem;
- position: relative;
- }
- .videoleft {
- width: 1.97rem;
- height: 1.97rem;
- position: relative;
- margin-left: .53rem;
- margin-right: .53rem;
- background: url(../../../image/icon/iconvideobtn.png);
- background-position: center center;
- background-size: 1.97rem 1.97rem;
- background-repeat: no-repeat;
- }
- .item {
- height: .8rem;
- width: .8rem;
- position: absolute;
- }
- .top {
- top: 0px;
- left: 50%;
- margin-left: -.4rem;
- }
- .left {
- top: 50%;
- left: 0;
- margin-top: -.4rem;
- }
- .right {
- top: 50%;
- right: 0;
- margin-top: -.4rem;
- }
- .bottom {
- bottom: 0;
- left: 50%;
- margin-left: -.4rem;
- }
- .title {
- margin-top: 11.33rem;
- padding: 0 1.33rem;
- font-size: .32rem;
- line-height: 180%;
- color: #fff;
- font-weight: 400;
- color: rgba(238, 238, 238, 1);
- }
- .bottom {
- font-size: 1rem;
- line-height: 180%;
- text-align: center;
- }
- </style>
- </head>
- <body>
- <div class="title">
- <div id="realtime" class="bottom" tapmode onclick="fnRealtime();">打开实时监控</div>
- <div id="playback" class="bottom" tapmode onclick="fnPlayback();">打开回放</div>
- </div>
- </body>
- <script type="text/javascript" src="../../../script/api.js"></script>
- <script type="text/javascript">
- var hikvision, eUrl, eRealtime, ePlayback;
- apiready = function() {
- hikvision = api.require('hikvision');
- eUrl = api.pageParam.url;
- eRealtime = $api.byId('realtime');
- ePlayback = $api.byId('playback');
- eRealtime.style.display = "none";
- ePlayback.style.display = "block";
- var timestamp = (new Date()).getTime();
- console.warn(timestamp);
- if (!$api.getStorage('eAccessTokens')) {
- fnAccessToken();
- } else {
- if ($api.getStorage('eAccessTokens').expireTime <= timestamp) {
- fnAccessToken();
- } else {
- fninitVue();
- }
- }
- };
复制代码
老样子重点代码自己付点云币自己下载
注意css我用rem 缺少主要css 建议你们自己最后用px!!
|
本帖子中包含更多资源,您需要 登录 才可以下载或查看,没有帐号?立即注册
X
|