严智鑫
2024-03-25 130170246c92b431b5b276dd015726bd9eaf9d75
Albania_Mes-ui/src/views/home/index.vue
@@ -302,12 +302,23 @@
    margin-top: -150px;
    margin-left: -200px;
}
.cells {
    height: 100%;
}
</style>
<template>
    <el-container>
        <!-- <el-header style="padding: 10px;"></el-header> -->
        <el-main>
            <div class="box" @click="dialogFormVisible2 = true">
            <el-dialog :visible.sync="dialogFormVisible2" :title="$t('Alarm Information')">
                <el-table :data="this.alarm" border style="width: 100%;font-size: 25px;">
                    <el-table-column prop="id" :label="$t('id')"></el-table-column>
                    <el-table-column prop="content" :label="$t('content')"></el-table-column>
                    <el-table-column prop="timeons" :label="$t('timeon')"></el-table-column>
                </el-table>
            </el-dialog>
            <div class="box" @click="dialogFormVisible2 = true" style="z-index: 999;">
                <div class="text">
                    <!-- Alarm: -->
                    {{ this.text }}
@@ -333,28 +344,52 @@
                    {{ $t('Task queue') }}</el-button>
            </div>
            <div style="display: flex;align-items: center;">
            <div style="display: flex;align-items: center;overflow: hidden;">
                <div class="blocks" style="position: relative;width: 100%;">
                    <div class="blocks-img" :style="'z-index:999;left:150px;top:555px;'">
                    <div class="blocks-img" :style="'z-index:99;left:150px;top:555px;'">
                    </div>
                    <div
                        :style="'position: absolute;z-index:999;left:271px;top:987px;width:210px;height:38px;background-color:' + ShowDeviceList(0) + ';;'">
                        :style="'position: absolute;z-index:99;left:271px;top:987px;width:210px;height:38px;background-color:' + ShowDeviceList(0) + ';'">
                    </div>
                    <div
                        :style="'position: absolute;z-index:999;left:553px;top:956px;width:110px;height:74px;background-color:' + ShowDeviceList(0) + ';;'">
                        :style="'position: absolute;z-index:99;left:553px;top:956px;width:110px;height:74px;background-color:' + ShowDeviceList(0) + ';'">
                    </div>
                    <div
                        :style="'position: absolute;z-index:999;left:800px;top:450px;width:115px;height:30px;background-color:' + ShowDeviceList(0) + ';;'">
                        :style="'position: absolute;z-index:99;left:800px;top:450px;width:115px;height:30px;background-color:' + ShowDeviceList(0) + ';'">
                    </div>
                    <div
                        :style="'position: absolute;z-index:999;left:800px;top:675px;width:115px;height:30px;background-color:' + ShowDeviceList(0) + ';;'">
                        :style="'position: absolute;z-index:99;left:800px;top:675px;width:115px;height:30px;background-color:' + ShowDeviceList(0) + ';'">
                    </div>
                    <div
                        :style="'position: absolute;z-index:999;left:740px;top:930px;width:230px;height:90px;background-color:' + ShowDeviceList(0) + ';;'">
                        <div v-for="item in cagelist1" :key="item['number']">
                            <div v-for="(num) in item['number']" :key="num">
                                1
                    <div :style="'position: absolute;z-index:1000;left:740px;top:507px;width:230px;height:114px;'">
                        <div v-for="item in cagelist4" :key="item['id']"
                            :style="'display:flex;height:4.55px;position: relative;'">
                            <div class="cells" v-for="(num) in item['number']" :key="num" :style="'width: ' + (item['glassWidth'] * 0.046) + 'px;background-color:' + ShowCellList(1) + ';position: absolute;left:' +
                ((item['glassWidth'] * 0.046 * (num - 1)) + ((num - 1) * 5)) + 'px;'">
                            </div>
                        </div>
                    </div>
                    <div :style="'position: absolute;z-index:1000;left:740px;top:730px;width:230px;height:90px;'">
                        <div v-for="item in cagelist3" :key="item['id']"
                            :style="'display:flex;height:2.25px;position: relative;'">
                            <div class="cells" v-for="(num) in item['number']" :key="num" :style="'width: ' + (item['glassWidth'] * 0.046) + 'px;background-color:' + ShowCellList(1) + ';position: absolute;left:' +
                ((item['glassWidth'] * 0.046 * (num - 1)) + ((num - 1) * 5)) + 'px;'">
                            </div>
                        </div>
                    </div>
                    <div :style="'position: absolute;z-index:1000;left:740px;top:830px;width:230px;height:90px;'">
                        <div v-for="item in cagelist2" :key="item['id']"
                            :style="'display:flex;height:2.25px;position: relative;'">
                            <div class="cells" v-for="(num) in item['number']" :key="num" :style="'width: ' + (item['glassWidth'] * 0.046) + 'px;background-color:' + ShowCellList(1) + ';position: absolute;left:' +
                ((item['glassWidth'] * 0.046 * (num - 1)) + ((num - 1) * 5)) + 'px;'">
                            </div>
                        </div>
                    </div>
                    <div :style="'position: absolute;z-index:1000;left:740px;top:930px;width:230px;height:90px;'">
                        <div v-for="item in cagelist1" :key="item['id']"
                            :style="'display:flex;height:2.25px;position: relative;'">
                            <div class="cells" v-for="(num) in item['number']" :key="num" :style="'width: ' + (item['glassWidth'] * 0.046) + 'px;background-color:' + ShowCellList(1) + ';position: absolute;left:' +
                ((item['glassWidth'] * 0.046 * (num - 1)) + ((num - 1) * 5)) + 'px;'">
                            </div>
                        </div>
                    </div>
@@ -480,10 +515,11 @@
                    <el-button type="primary" @click="AnewMeasure()" :disabled="SoftEmergencyStopState"
                        style="z-index: 999;">重新测量</el-button>
                </div>
                <br>
                <!--显示-->
                <div style="width:1000px;height: 720px;border: 2px solid #d1d1d1;margin: auto auto;">
                <div style="width:1000px;height: 720px;border: 2px solid #d1d1d1;">
                    <!--玻璃图  #81b337-->
                    <div :style="'top:10px;bottom: 10px;left: 10px;right: 10px;margin: auto;position:absolute;width:'
                    <div :style="'top:10px;bottom: 10px;left: 10px;right: 10px;margin:auto auto;position:absolute;width:'
                + (this.LastQueue.glasswidth / 25 * 7) + 'px;height:'
                + (this.LastQueue.glassheight / 25 * 7) + 'px;line-height: '
                + (this.LastQueue.glassheight / 25 * 7) + 'px;background-color: #93d2f3;text-align: center;'">
@@ -995,6 +1031,15 @@
                }
            }
        },
        //获取设备显示状态
        ShowCellList(num) {
            if (num == null) {
                return "";
            } else if (num > 0) {
                return "gray";
                // return "rgba(0,0,0,1)";
            }
        },
        //获取设备玻璃id
        ShowGlassIdList(num) {
            if (this.GlassIdList != null && this.GlassIdList.length > 0) {