From 99a010f21d278498bafd248217c584e101db2d8f Mon Sep 17 00:00:00 2001
From: loulijun2021 <1694218219@qq.com>
Date: 星期四, 01 九月 2022 17:27:17 +0800
Subject: [PATCH] 1.自动扫码回车功能接入
---
src/views/sbgl/sbqd.vue | 38 +++++++++++++++++++++++++++++---------
1 files changed, 29 insertions(+), 9 deletions(-)
diff --git a/src/views/sbgl/sbqd.vue b/src/views/sbgl/sbqd.vue
index 89cd85d..5788568 100644
--- a/src/views/sbgl/sbqd.vue
+++ b/src/views/sbgl/sbqd.vue
@@ -2,10 +2,13 @@
<div>
<div class="body" :style="{height:mainHeight+'px'}">
- <div class="bodyTopButtonGroup">
+ <div class="bodyTopButtonGroup" style="justify-content: space-between">
<el-button type="primary" icon="el-icon-circle-plus-outline" @click="add('add')">鏂板</el-button>
- <el-button icon="el-icon-c-scale-to-original" @click="deviceTypeButton">璁惧绫诲瀷</el-button>
- <el-button icon="el-icon-document-copy" @click="deviceGroupButton">璁惧缁�</el-button>
+ <div style="display: flex">
+ <el-button icon="el-icon-c-scale-to-original" @click="deviceTypeButton">璁惧绫诲瀷</el-button>
+ <el-button icon="el-icon-document-copy" @click="deviceGroupButton">璁惧缁�</el-button>
+ </div>
+
<!-- <el-button type="primary" icon="el-icon-upload2" @click="upload">瀵煎叆</el-button>-->
</div>
@@ -186,7 +189,8 @@
width="100"
>
<template slot-scope="{row}">
- <div>{{ row.operation_ration }}%</div>
+ <div v-if=" parseFloat(row.operation_ration)===0">/</div>
+ <div v-else>{{ row.operation_ration }}%</div>
</template>
</el-table-column>
<el-table-column
@@ -221,7 +225,6 @@
</div>
<!--鍒嗛〉-->
<pagination
- v-show="total>0"
:total="total"
:page.sync="form.page"
:limit.sync="form.rows"
@@ -386,6 +389,7 @@
width="50"
label="搴忓彿"
prop="RowNum"
+ fixed
/>
<el-table-column
prop="code"
@@ -429,7 +433,6 @@
</el-table>
<!--鍒嗛〉-->
<pagination
- v-show="DeviceTypeTotal>0"
:total="DeviceTypeTotal"
:page.sync="formDeviceType.page"
:limit.sync="formDeviceType.rows"
@@ -475,6 +478,7 @@
<el-table-column
width="50"
label="搴忓彿"
+ fixed
prop="RowNum"
/>
<el-table-column
@@ -542,7 +546,6 @@
</el-table>
<!--鍒嗛〉-->
<pagination
- v-show="DeviceGroupTotal>0"
:total="DeviceGroupTotal"
:page.sync="formDeviceGroup.page"
:limit.sync="formDeviceGroup.rows"
@@ -569,7 +572,7 @@
import Pagination from '@/components/Pagination'
import {
AddUpdateDeviceGroup, AddUpdateDeviceManger,
- AddUpdateDeviceType, DeleteDeviceManger, DeleteDeviceType,
+ AddUpdateDeviceType, DeleteDeviceGroup, DeleteDeviceManger, DeleteDeviceType,
DeviceGroupSearch,
DeviceMangerSearch,
DeviceTypeSearch,
@@ -793,6 +796,9 @@
DeleteDeviceManger({ devicecode: row.code }).then(res => {
if (res.code === '200') {
this.$message.success('鍒犻櫎鎴愬姛!')
+ if (this.form.page > 1 && this.tableData.length === 1) {
+ this.form.page--
+ }
this.getDeviceMangerSearch()
}
})
@@ -926,6 +932,9 @@
DeleteDeviceType({ devicetypecode: row.code }).then(res => {
if (res.code === '200') {
this.$message.success('鍒犻櫎鎴愬姛!')
+ if (this.formDeviceType.page > 1 && this.DeviceTypeArray.length === 1) {
+ this.formDeviceType.page--
+ }
this.getDeviceTypeSearchDialog()
}
})
@@ -1040,6 +1049,9 @@
DeleteDeviceGroup({ devicegroupcode: row.code }).then(res => {
if (res.code === '200') {
this.$message.success('鍒犻櫎鎴愬姛!')
+ if (this.formDeviceGroup.page > 1 && this.DeviceGroupArray.length === 1) {
+ this.formDeviceGroup.page--
+ }
this.getDeviceGroupSearchDialog()
}
})
@@ -1096,6 +1108,10 @@
<!--鍏叡椤甸潰鏍峰紡-->
<style lang="scss" scoped>
$main_color: #42b983;
+::v-deep .el-button--text{
+ font-size: 14px ;
+ cursor: pointer ;
+}
.el-icon-share ,.el-icon-delete,.el-icon-edit-outline{
color: $main_color;
cursor: pointer;
@@ -1181,7 +1197,11 @@
.userDialogVisible ::v-deep .el-form-item {
margin-bottom: 0;
}
-
+::v-deep .el-select__caret{
+ display: flex;
+ justify-content: center;
+ align-items: center;
+}
</style>
<style>
--
Gitblit v1.9.3