*
L
3 天以前 daa2cec25875276f3462e09d102f9d2fd52a96e1
src/main/webapp/views/index.html
@@ -5,6 +5,7 @@
    <title>环形穿梭车智能系统</title>
    <link rel="stylesheet" href="../static/css/element.css">
    <link rel="stylesheet" href="../static/css/indexHCDD.css">
    <link rel="stylesheet" href="../static/css/indexHCDDXKD.css">
    <link rel="stylesheet" href="../static/css/element-ui.css">
    <link rel="icon" href="../static/images/favicon.ico" type="image/x-icon">
    <script type="text/javascript" src="../static/js/jquery/jquery-3.3.1.min.js"></script>
@@ -20,6 +21,17 @@
        <div class="particles-container" id="particles-container"></div>
    </div>
    <div id="app">
        <!-- 新增的许可证横幅,放在 header 之后,app 之前 -->
        <div v-if="licenseDayI <= 30"
             :class="['license-banner', licenseDayI <= 0 ? 'expired' : licenseDayI <= 7 ? 'urgent' : 'warning']"
             style="z-index: 9999;">
            <div class="license-content">
                <i :class="licenseDayI <= 0 ? 'el-icon-error' : licenseDayI <= 7 ? 'el-icon-warning' : 'el-icon-info'"></i>
                <span class="license-text">{{ licenseDay }}</span>
                <span v-if="licenseDayI > 0" class="license-days">{{ licenseDayI }} 天</span>
            </div>
        </div>
        <div  class="map">
            <div class="system-control-panel">
                <div class="system-status">
@@ -147,8 +159,20 @@
                            <el-button
                                    type="danger"
                                    size="small"
                                    @click="taskDelete(scope.row)">
                                    @click.native="taskDelete(scope.row)">
                                删除
                            </el-button>
                        </template>
                    </el-table-column>
                    <el-table-column
                            label="操作"
                            type="template">
                        <template slot-scope="scope">
                            <el-button
                                    type="danger"
                                    size="small"
                                    @click.native="taskDelete1(scope.row)">
                                初始化
                            </el-button>
                        </template>
                    </el-table-column>
@@ -380,18 +404,38 @@
                    this.getValueSystem()
                    this.getLicenseDays()
                    // 高频更新:小车和设备位置(1.5秒)
                    setInterval(() => {
                        this.getTableDataRgv()
                        this.getTableDataDev()
                        this.getTableDataTrack()
                    }, 1000)
                    // 高频更新:实时任务列表等(2秒)
                    setInterval(() => {
                        this.getTableDataLeft()
                        this.getTableDataLeft1()
                        this.getTableDataRight()
                    }, 2000)
                    // 高频更新:实时站点信息等(3秒)
                    setInterval(() => {
                        this.getTableDataDev()
                    }, 3000)
                    // 低频更新:任务列表等(10秒)
                    setInterval(() => {
                        this.getTableDataLeft1()
                        this.getTableDataRight1()
                        this.getValueSystem()
                        this.getLicenseDays()
                    }, 10*1000)
                    }, 1000)
                    // 低频更新:许可证信息(30秒)
                    setInterval(() => {
                        this.getLicenseDays()
                    }, 30000)
                    // 静态低频更新:PLC(1小时)
                    setInterval(() => {
                        this.getTableDataTrack()
                    }, 60*60*1000)
                },
                // 获取容器实际尺寸
                updateContainerSize() {
@@ -505,6 +549,32 @@
                        });
                    });
                },
                taskDelete1(row) {
                    let that = this;
                    that.$confirm('确认要初始化该任务吗?', '提示', {
                        confirmButtonText: '确定',
                        cancelButtonText: '取消',
                        type: 'warning'
                    }).then(() => {
                        $.ajax({
                            url: baseUrl + "/rgv/disable/task/delete1",
                            headers: {'token': localStorage.getItem('token')},
                            method: 'POST',
                            data: {
                                wrkNo: row.wrkNo
                            },
                            success: function (res) {
                                if (res.code === 200) {
                                    that.$message.success('初始化成功');
                                    // 删除当前行
                                    // that.tableDataRight.splice(that.tableDataRight.indexOf(row), 1);
                                } else {
                                    that.$message.error('初始化失败');
                                }
                            }
                        });
                    });
                },
                toggleStatus(index, row) {
                    let that = this;
                    const currentStatus = row.status;