fix: 修复样式问题,缩放功能优化

This commit is contained in:
@changcode
2021-08-12 14:28:23 +08:00
parent 8e25b4bf6c
commit add53d7146
4 changed files with 37 additions and 12 deletions

View File

@@ -4230,12 +4230,12 @@
}
},
"echarts": {
"version": "5.0.1",
"resolved": "https://registry.npmjs.org/echarts/-/echarts-5.0.1.tgz",
"integrity": "sha512-JYn22Dolt2esY2jEzUsw1OxbobuW67oGjIoTjZO3rW89SWkfJ4kbrmC2OW9JjsBrD1rdkmaWBuZZ2HgmThyxJw==",
"version": "5.1.2",
"resolved": "https://registry.npmjs.org/echarts/-/echarts-5.1.2.tgz",
"integrity": "sha512-okUhO4sw22vwZp+rTPNjd/bvTdpug4K4sHNHyrV8NdAncIX9/AarlolFqtJCAYKGFYhUBNjIWu1EznFrSWTFxg==",
"requires": {
"tslib": "2.0.3",
"zrender": "5.0.3"
"zrender": "5.1.1"
}
},
"ee-first": {
@@ -4257,9 +4257,9 @@
"dev": true
},
"element-ui": {
"version": "2.13.0",
"resolved": "https://registry.npmjs.org/element-ui/-/element-ui-2.13.0.tgz",
"integrity": "sha512-KYsHWsBXYbLELS8cdfvgJTOMSUby3UEjvsPV1V1VmgJ/DdkOAS4z3MiOrPxrT9w2Cc5lZ4eVSQiGhYFR5NVChw==",
"version": "2.15.5",
"resolved": "https://registry.npmjs.org/element-ui/-/element-ui-2.15.5.tgz",
"integrity": "sha512-B/YCdz2aRY2WnFXzbTRTHPKZHBD/2KV6u88EBnkaARC/Lyxnap+7vpvrcW5UNTyVwjItS5Fj1eQyRy6236lbXg==",
"requires": {
"async-validator": "~1.8.1",
"babel-helper-vue-jsx-merge-props": "^2.0.0",
@@ -11782,6 +11782,11 @@
"integrity": "sha1-fjL3W0E4EpHQRhHxvxQQmsAGUdc=",
"dev": true
},
"qrcodejs2": {
"version": "0.0.2",
"resolved": "https://registry.npmjs.org/qrcodejs2/-/qrcodejs2-0.0.2.tgz",
"integrity": "sha1-Rlr+Xjnxn6zsuTLBH3oYYQkUauE="
},
"qs": {
"version": "6.7.0",
"resolved": "https://registry.npmjs.org/qs/-/qs-6.7.0.tgz",
@@ -14929,6 +14934,12 @@
"lodash": "^4.17.15"
}
},
"webpack-shell-plugin": {
"version": "0.5.0",
"resolved": "https://registry.npmjs.org/webpack-shell-plugin/-/webpack-shell-plugin-0.5.0.tgz",
"integrity": "sha1-Kbih2A3erg3bEOcpZn9yhlPCx0I=",
"dev": true
},
"webpack-sources": {
"version": "1.4.3",
"resolved": "https://registry.npmjs.org/webpack-sources/-/webpack-sources-1.4.3.tgz",
@@ -15244,9 +15255,9 @@
}
},
"zrender": {
"version": "5.0.3",
"resolved": "https://registry.npmjs.org/zrender/-/zrender-5.0.3.tgz",
"integrity": "sha512-TVcN2IMdo7je3GEq/E4CER4AGBe/n50/izILdupppyHf/hVHuiXCRliqdu8+32Z1OmGg6RfKt5qQlkX+bOtU0g==",
"version": "5.1.1",
"resolved": "https://registry.npmjs.org/zrender/-/zrender-5.1.1.tgz",
"integrity": "sha512-oeWlmUZPQdS9f5hK4pV21tHPqA3wgQ7CkKkw7l0CCBgWlJ/FP+lRgLFtUBW6yam4JX8y9CdHJo1o587VVrbcoQ==",
"requires": {
"tslib": "2.0.3"
}

View File

@@ -184,6 +184,18 @@
color: $--theme-color;
}
}
.mt-10.table-container.nz-table2 {
.el-table:not(.chart-table) {
.gutter {
position: fixed;
right: 55px;
height: 42px;
border-bottom: 1px solid $--right-box-border-color;
background-color: white;
box-sizing: border-box;
}
}
}
/* 上滑resize工具条--end */
.nz-table2 {
position: relative;
@@ -226,7 +238,7 @@
}
.gutter {
position: fixed;
right: 59px;
right: 31px;
height: 42px;
border-bottom: 1px solid $--right-box-border-color;
background-color: white;

View File

@@ -24,6 +24,7 @@ export default {
// 判断是否执行缩放弹框功能
if (data != 0) {
window.addEventListener('resize', this.browserZoom)
document.addEventListener('DOMContentLoaded', this.browserZoom)
}
},
beforeDestroy () {
@@ -38,6 +39,7 @@ export default {
localStorage.setItem('browserZoom', 0)
// 移除事件
window.removeEventListener('resize', this.browserZoom)
document.removeEventListener('DOMContentLoaded', this.browserZoom)
},
browserZoom () {
// 初始缩放比例

View File

@@ -95,7 +95,7 @@
<template v-else>-</template>
</template>
<template v-else-if="item.prop === 'brand'">{{scope.row.brand ? scope.row.brand.name : '-'}}</template>
<template v-else-if="item.prop === 'purchaseDate'">{{scope.row.purchaseDate ? scope.row.purchaseDate : '--'}}</template>
<template v-else-if="item.prop === 'purchaseDate'">{{scope.row.purchaseDate ? scope.row.purchaseDate : '-'}}</template>
<template v-else>
<span v-if="scope.row.fields&&scope.row.fields.find(field => field.name === item.prop)">
{{scope.row.fields.find(field => field.name === item.prop).value.join(',')}}