左侧菜单栏样式修改

This commit is contained in:
fengerli
2025-09-05 16:56:46 +08:00
parent a31318aa1a
commit c95c0e65d2
6 changed files with 78 additions and 53 deletions

View File

@ -124,6 +124,16 @@
</el-col>
</el-row>
</div>
<!-- ===========充电提示框====== -->
<el-dialog title="充电提示" v-model="centerDialogVisible" width="15%">
<div style="display: flex; align-items: center;">
<h3 style="color: rgba(224, 52, 52, 1)">设备电量低于20%</h3>
</div>
<div>请及时充电</div>
<span slot="footer" class="dialog-footer" style="text-align: right;display: block;">
<el-button type="primary" @click="centerDialogVisible = false"> </el-button>
</span>
</el-dialog>
</div>
</template>
<script setup name="DeviceControl" lang="ts">
@ -151,6 +161,7 @@ const fullscreenLoading = ref(false)
const forceAlarmLoading = ref(false) //强制报警
const sendTextLoading = ref(false)
const lightModesLoading = ref(false)
const centerDialogVisible = ref(false)
const {
connected,
connect,
@ -575,9 +586,8 @@ const handleDeviceMessage = (msg: any) => {
deviceDetail.value.batteryPercentage = deviceState[3]; //电量
deviceDetail.value.batteryRemainingTime = deviceState[5]; //续航时间
// getList(); // 重新获取设备详情
if (deviceDetail.value.batteryPercentage < 20) {
ElMessage.closeAll();
proxy?.$modal.msgWarning('电量低于20%,请及时充电');
if (deviceDetail.value.batteryPercentage < 20 && deviceDetail.value.chargeState == 0) {
centerDialogVisible.value=true
}
break;
default:
@ -663,7 +673,7 @@ onUnmounted(() => {
background: white;
padding: 0px 20px 50px;
border: 1px solid #ebeef5;
height: 250px;
height: 289px;
position: relative;
}
@ -736,6 +746,7 @@ onUnmounted(() => {
}
.brightness-alarm {
display: flex;
justify-content: space-between;
@ -927,4 +938,9 @@ onUnmounted(() => {
}
}
}
.path-img {
width: 52px;
height: 28px;
}
</style>

View File

@ -15,11 +15,10 @@
<el-card>
<!-- =========搜索按钮操作======= -->
<div class="btn_search">
<el-button type="primary" plain icon="Download"
@click="handleExport">导出</el-button>
<el-button type="primary" plain icon="Download" @click="handleExport">导出</el-button>
<div style="position: absolute; right:30px; top:20px">
<el-input v-model="queryParams.content" placeholder="MAC/IMEI" clearable
style="width: 200px; margin-right: 20px;" @keyup.enter="handleQuery" @input="handleInput" />
style="width: 200px; margin-right: 20px;" @keyup.enter="handleQuery" @input="handleInput" />
<el-button type="primary" plain @click="toggleFilter">高级筛选</el-button>
</div>
</div>
@ -109,7 +108,7 @@ const initData: PageData<'', deviceQuery> = {
deviceType: '',
startTime: '',
endTime: '',
content:""
content: ""
},
rules: undefined,
form: ''