<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <link rel="stylesheet" href="../bootstrap/css/bootstrap.css">
    <link rel="stylesheet" href="../bootstrap/css/bootstrap-datetimepicker.css">
    <link rel="stylesheet" href="../bootstrap/css/bootstrap-select.css">
    <link rel="stylesheet" href="../bootstrap/css/bootstrap-treeview.css">
    <link rel="stylesheet" href="../bootstrap/css/bootstrap-switch.min.css">
    <link rel="stylesheet" href="../css/sbts.css">
    <link rel="stylesheet" href="../css/photoviewer.css">
    <!--<link rel="stylesheet" href="../css/viewer.min.css">-->
    <title>设备推送</title>
</head>
<body>
<div id="page-sy">
    <div class="right-nav">
        <div class="tab-content content-sjfx">
            <div role="tabpanel" class="tab-pane active" id="sjcx">
                <div class="div-left">
                    <div id="sjcx_s" class="div-right">
                        <div class="div-right-top">
                            <span class="pub-span">设备编号：</span>
                            <input type="text" class="form-control input-pub" v-text="">
                            <span class="pub-span" style="margin-left: 10px;">推送状态</span>
                            <select class="form-control selectpicker" v-model="clzt_select" v-on:change="getChange_tszt()">
                                <option value="9">待推送</option>
                                <option value="0">推送成功</option>
                                <option value="1">推送失败</option>
                            </select>
                            <button type="button" class="btn btn-sm pub-btn" style="margin-left: 30px;" @click="getChange()">查询</button>
                            <button type="button" class="btn btn-sm pub-btn" style="margin-left: 30px;" @click="tss()">推送</button>
                        </div>
                        <div style="height:calc(100% - 130px);margin-top: 20px;" class="tables">
                            <table class="table table-td" style="text-align: center;">
                                <thead>
                                <tr style="background-color: rgb(228, 228, 228);">
                                    <td style="width:40px;">
                                        <input type="checkbox" @click="qx_s($event)" style="width: 17px;height: 17px;margin-top: 4px;">
                                    </td>
                                    <td>设备编号</td>
                                    <td style="width: 400px;">通道名称</td>
                                    <td>通道编号</td>
                                    <td>辖区名称</td>
                                    <td>行政编号</td>
                                    <td>设备状态</td>
                                    <td>推送次数</td>
                                    <td>推送描述</td>
                                    <td>推送状态</td>

                                    <td>设备检测类型</td>
                                    <td>所在地类型</td>
                                </tr>
                                </thead>
                                <tbody class="div-pub-gt">
                                <tr v-for="(item,index) in data_table_wfpz">
                                    <td style="width: 40px;">
                                        <input type="checkbox" name="loginName" class="loginName" :value="item.xh" style="width: 17px;height: 17px;margin-top: 4px;">
                                    </td>
                                    <td v-text="item.sbbh"></td>
                                    <td v-text="item.tdmc" style="width: 400px;"></td>
                                    <td v-text="item.tdbh"></td>
                                    <td v-text="item.xztreename"></td>
                                    <td v-text="item.xzbh"></td>
                                    <td v-text="item.devicetype=='1'?'不在线':'在线'"></td>
                                    <td v-text="item.pushcount==null?'0':item.pushcount"></td>
                                    <td v-text="item.pushdesc==null?'':item.pushdesc"></td>
                                    <td v-text="item.pushstatus==null||item.pushstatus=='9'?'待推送':item.pushstatus=='0'?'推送成功':'推送失败'"></td>
                                    <td></td>
                                    <td></td>
                                </tr>
                                </tbody>
                            </table>
                        </div>
                        <div class="div-right-buttom">
                            <div style="line-height: 64px;float: left;font-weight: 900;">
                                <span>共</span><span style="color: red;" v-text="count"></span><span>条</span>
                            </div>
                            <ul id="fy4" style="float: right;"></ul>
                            <div style="float: right;margin-top: 21px;margin-right: 30px;width: 111px;line-height: 36px;font-weight: 900;">
                                <span style="float: left;width: 34px;">每页</span>
                                <select class="form-control selectpicker" v-model="fy_select" style="width: 50px;padding: 0px 3px;float: left;"v-on:change="getChange()">
                                    <option>10</option>
                                    <option>20</option>
                                    <option>30</option>
                                    <option>40</option>
                                    <option>50</option>
                                </select>
                                <span style="float: left;margin-left: 8px;">条</span>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>

<!--事件推送弹出框-->
<div class="modal fade" id="myModal_ts" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
    <div class="modal-dialog" role="document" style="width: 1300px;">
        <div class="modal-content" style="color: #e6eaef;width: 1300px;">
            <div class="modal-header" style="background-color: rgb(48, 53, 72);">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
                        aria-hidden="true" style="color: white;">&times;</span></button>
                <h6 class="modal-title">设备推送信息
                </h6>
            </div>
            <div class="modal-body tables" style="height: 650px">
                <button type="button" class="btn btn-sm pub-btn" style="margin-left: 0px;margin-top: 0px;" @click="ts_ok()">开始推送
                </button>
                <table class="table table-td" style="text-align: center;color: dimgrey;margin-top: 10px;">
                    <thead>
                    <tr style="background-color: rgb(228, 228, 228);">
                        <td style="width:40px;"></td>
                        <td>设备编号</td>
                        <td style="width: 10px;">通道编号</td>
                        <td style="width: 400px;">通道名称</td>
                        <!--<td>辖区名称</td>-->
                        <td>推送描述</td>
                        <td>推送状态</td>
                        <td style="width: 170px;">操作</td>
                    </tr>
                    </thead>
                    <tbody class="div-pub-gt" style="height: calc(100% - 30px);">
                    <tr v-for="(item,index) in data_table_ts">
                        <td v-text="index+1" style="width:40px;"></td>
                        <td v-text="item.sbbh" ></td>
                        <td v-text="item.tdbh"  style="width:10px;"></td>
                        <td v-text="item.tdmc" style="width: 200px;"></td>
                        <!--<td v-text="item.xztreename"></td>-->
                        <td v-text="item.pushdesc==null?'':item.pushdesc"></td>
                        <td v-text="item.pushstatus==null||item.pushstatus=='9'?'待推送':item.pushstatus=='0'?'推送成功':'推送失败'"></td>
                        <td style="width: 170px;">
                            <!--<button type="button" class="btn btn-sm pub-btn pubs_1"-->
                                    <!--@click="xq(item)">详情-->
                            <!--</button>-->
                            <button type="button" class="btn btn-sm pub-btn pubs_1"
                                    @click="ts_s(item)" :style="{'background-color':item.pushstatus!=1?'#cccccc':'#368ff3','pointer-events':item.pushstatus!=1?'none':''}">推送
                            </button>
                            <button type="button" class="btn btn-sm pub-btn pubs_1"
                                    @click="deletes(item,index)">删除
                            </button>
                        </td>
                    </tr>
                    </tbody>
                </table>
            </div>
            <div class="modal-footer" style="border-top:none;">
                <button type="button" class="btn btn-sm" data-dismiss="modal" style="color: #2f2f2f;">关闭</button>
            </div>
        </div>
    </div>
</div>

</body>
<script src="../js/jquery-3.1.1.min.js"></script>
<!--<script src="../js/viewer.min.js"></script>-->
<script src="../js/util/photoviewer.js"></script>
<script src="../bootstrap/js/bootstrap.js"></script>
<script src="../bootstrap/js/bootstrap-paginator.js"></script>
<script src="../bootstrap/js/bootstrap-treeview.js"></script>
<script src="../bootstrap/js/bootstrap-select.js"></script>
<script src="../bootstrap/js/bootstrap-switch.min.js"></script>
<!--<script src="../bootstrap/js/bootstrap-datetimepicker.js"></script>-->
<!--<script src="../bootstrap/js/bootstrap-datetimepicker.zh-CN.js"></script>-->
<script src="../js/laydate/laydate.js"></script>
<script src="../js/vue.js"></script>
<script src="../js/util/http_util.js"></script>
<script src="../js/tsgl/sbts.js"></script>
</html>