From d33eacc1f85ac3a736b33ba4713a19aae466d711 Mon Sep 17 00:00:00 2001
From: loulijun2021 <1694218219@qq.com>
Date: 星期五, 05 八月 2022 16:42:53 +0800
Subject: [PATCH] 1.做适应平板显示的内容大小
---
src/views/scgl/gd.vue | 40 +++++++++++++++++-----------------------
1 files changed, 17 insertions(+), 23 deletions(-)
diff --git a/src/views/scgl/gd.vue b/src/views/scgl/gd.vue
index 8e70301..29cf57b 100644
--- a/src/views/scgl/gd.vue
+++ b/src/views/scgl/gd.vue
@@ -76,12 +76,12 @@
<el-button type="primary" icon="el-icon-search" @click="search">鏌ヨ</el-button>
<el-button type="info" icon="el-icon-refresh" @click="reset">閲嶇疆</el-button>
</div>
- <!-- <div v-if="!isFullscreen" style="display: flex;align-items: start; margin-top: 15px;z-index: 2">-->
+ <!-- <div v-if="!isIpad" style="display: flex;align-items: start; margin-top: 15px;z-index: 2">-->
<!-- <el-button type="primary" icon="el-icon-circle-plus-outline" @click="add('add')">鏂板</el-button>-->
<!-- <el-button type="primary" icon="el-icon-connection" @click="send('send')">娲惧彂</el-button>-->
<!-- <el-button type="primary" icon="el-icon-switch-button">璁㈠崟鍏抽棴</el-button>-->
<!-- </div>-->
- <!-- <div v-if="isFullscreen" style="display: flex;flex-direction: column;align-items: end">-->
+ <!-- <div v-if="isIpad" style="display: flex;flex-direction: column;align-items: end">-->
<!-- <div style="display: flex;margin: 10px 0">-->
<!-- <el-button type="primary" icon="el-icon-circle-plus-outline" @click="add('add')">鏂板</el-button>-->
<!-- <el-button type="primary" icon="el-icon-connection" @click="send('send')">娲惧彂</el-button>-->
@@ -230,7 +230,7 @@
/>
<el-table-column
label="鎿嶄綔"
- width="120"
+ width="140"
fixed="right"
>
<template slot-scope="{row}">
@@ -732,7 +732,7 @@
}
}
return {
- isFullscreen: false,
+ isIpad: false,
mainHeight: 0,
tableHeight: 0,
username: '',
@@ -860,8 +860,7 @@
}
},
created() {
- this.getMesOrderSearch()
- this.getSelect()
+ this.handleRequest()
},
mounted() {
window.addEventListener('resize', this.getHeight)
@@ -871,6 +870,13 @@
this.username = getCookie('username')
},
methods: {
+ handleRequest() {
+ this.getMesOrderSearch().then(res => {
+ if (res.code === '200') {
+ this.getSelect()
+ }
+ })
+ },
async getMesOrderSearch() {
// let tempDate = this.form.createdate
// if (tempDate.length > 0) {
@@ -895,6 +901,7 @@
this.total = res.count
// this.form.createdate = tempDate
+ return { code: res.code }
},
async getSelect() {
// 鑾峰彇浜у搧淇℃伅
@@ -1180,10 +1187,10 @@
getHeight() {
this.$nextTick(() => {
this.mainHeight = window.innerHeight - 250
- this.tableHeight = this.mainHeight - 100
- // this.isFullscreen = window.innerHeight < 800
- if (this.isFullscreen) {
- this.tableHeight = this.tableHeight - 50
+ this.tableHeight = this.mainHeight - 110
+ this.isIpad = window.innerHeight < 769
+ if (this.isIpad) {
+ this.tableHeight = this.tableHeight - 30
}
})
},
@@ -1299,19 +1306,6 @@
this.formApprove.lm_date = ''
// this.$refs.qrCodeDiv0.title = ''
-
- // this.$refs.qrCodeDiv1 = ''
- // this.$refs.qrCodeDiv2 = ''
- // this.$refs.qrCodeDiv3 = ''
-
- // this.$ref['qrCodeDiv'].clearable()
- // this.tableDataPrint.forEach((item, index) => {
- // this.$refs['qrCodeDiv' + item.seq] = ''
- // this.$refs[('qrCodeDiv' + index).toString()] = ''
- // // this.bindQRCode(item.seq, '', 'small')//姝ゆ柟娉曟病鐢�
- // })
- // this.bindQRCode(this.tableDataPrint.length, '', 'big')//姝ゆ柟娉曟病鐢�
- // this.$refs[('qrCodeDiv' + this.tableDataPrint.length).toString()] = ''
this.tableDataPrint = []
},
--
Gitblit v1.9.3