|
|
@ -1,43 +1,20 @@ |
|
|
<template> |
|
|
<template> |
|
|
<div class="tags-list" ref="totalLists"> |
|
|
<div class="tags-list" ref="totalLists"> |
|
|
<div |
|
|
|
|
|
class="arrow-icon" |
|
|
|
|
|
@click="arrowBack" |
|
|
|
|
|
style="position: fixed; left: 4px" |
|
|
|
|
|
> |
|
|
|
|
|
<el-button |
|
|
|
|
|
size="medium" |
|
|
|
|
|
icon="el-icon-arrow-left" |
|
|
|
|
|
:disabled="isLeftDisabled" |
|
|
|
|
|
></el-button> |
|
|
|
|
|
<el-button icon="el-icon-delete" size="medium" :disabled="tags.length==0" @click="clearControlLabel"></el-button> |
|
|
|
|
|
|
|
|
<div class="arrow-icon" @click="arrowBack" style="position: fixed; left: 4px"> |
|
|
|
|
|
<el-button size="medium" icon="el-icon-arrow-left" :disabled="isLeftDisabled"></el-button> |
|
|
|
|
|
<el-button icon="el-icon-delete" size="medium" :disabled="tags.length == 0" @click="clearControlLabel"></el-button> |
|
|
</div> |
|
|
</div> |
|
|
<div class="tag-style" ref="tagBox"> |
|
|
<div class="tag-style" ref="tagBox"> |
|
|
<div class="scrollWrapper" ref="scrollWrapper" id="nav"> |
|
|
<div class="scrollWrapper" ref="scrollWrapper" id="nav"> |
|
|
<el-tag |
|
|
|
|
|
:key="tag.displayName" |
|
|
|
|
|
size="medium" |
|
|
|
|
|
v-for="(tag, index) in tags" |
|
|
|
|
|
:closable="true" |
|
|
|
|
|
:disable-transitions="false" |
|
|
|
|
|
@close="handleClose(tag, index)" |
|
|
|
|
|
@click="changeMenu(tag)" |
|
|
|
|
|
:effect="$route.name === tag.displayName ? 'dark' : 'plain'" |
|
|
|
|
|
> |
|
|
|
|
|
|
|
|
<el-tag :key="tag.displayName" size="medium" v-for="(tag, index) in tags" :closable="true" |
|
|
|
|
|
:disable-transitions="false" @close="handleClose(tag, index)" @click="changeMenu(tag)" |
|
|
|
|
|
:effect="$route.name === tag.displayName ? 'dark' : 'plain'"> |
|
|
{{ tag.displayName }} |
|
|
{{ tag.displayName }} |
|
|
</el-tag> |
|
|
</el-tag> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
<div |
|
|
|
|
|
class="arrow-icon" |
|
|
|
|
|
@click="arrowForward" |
|
|
|
|
|
style="position: fixed; right: 4px" |
|
|
|
|
|
> |
|
|
|
|
|
<el-button |
|
|
|
|
|
size="medium" |
|
|
|
|
|
icon="el-icon-arrow-right" |
|
|
|
|
|
:disabled="isRightDisabled" |
|
|
|
|
|
></el-button> |
|
|
|
|
|
|
|
|
<div class="arrow-icon" @click="arrowForward" style="position: fixed; right: 4px"> |
|
|
|
|
|
<el-button size="medium" icon="el-icon-arrow-right" :disabled="isRightDisabled"></el-button> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</template> |
|
|
</template> |
|
|
@ -170,9 +147,28 @@ export default { |
|
|
} |
|
|
} |
|
|
}); |
|
|
}); |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
handleClose(tag, index) { |
|
|
handleClose(tag, index) { |
|
|
let length = this.tags.length - 1; |
|
|
let length = this.tags.length - 1; |
|
|
this.close(tag); |
|
|
this.close(tag); |
|
|
|
|
|
// 关闭医生诊台时,要关闭医生诊台的监听 add by pengj 2026-02-26 |
|
|
|
|
|
if (tag?.displayName == "体检医生诊台" && this.$peisAPI) { |
|
|
|
|
|
console.log("CommonTab.handleClose", tag) |
|
|
|
|
|
try { |
|
|
|
|
|
// 取消采图热键监听 |
|
|
|
|
|
this.$peisAPI.removeAllListeners("event-from-picture-hot-key-main") |
|
|
|
|
|
this.$peisAPI.removeAllListeners("event-from-picture-and-print-hot-key-main") |
|
|
|
|
|
this.$peisAPI.removeAllListeners("event-from-picture-print-hot-key-main") |
|
|
|
|
|
this.$peisAPI.removeAllListeners("event-from-picture-cancel-print-hot-key-main") |
|
|
|
|
|
this.$peisAPI.removeAllListeners("event-from-picture-delete-hot-key-main") |
|
|
|
|
|
|
|
|
|
|
|
// 取消 身高体重仪、血压仪 监听 |
|
|
|
|
|
this.$peisAPI.removeAllListeners("serial:data") |
|
|
|
|
|
} catch (error) { |
|
|
|
|
|
console.error(error) |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
// 如果关闭的标签不是当前路由的话,就不跳转 |
|
|
// 如果关闭的标签不是当前路由的话,就不跳转 |
|
|
if (tag.displayName !== this.$route.name) { |
|
|
if (tag.displayName !== this.$route.name) { |
|
|
this.handleScroll(); |
|
|
this.handleScroll(); |
|
|
@ -238,6 +234,7 @@ export default { |
|
|
|
|
|
|
|
|
<style scoped lang="scss"> |
|
|
<style scoped lang="scss"> |
|
|
@import '../../assets/css/global_button.css'; |
|
|
@import '../../assets/css/global_button.css'; |
|
|
|
|
|
|
|
|
.tags-list { |
|
|
.tags-list { |
|
|
display: flex; |
|
|
display: flex; |
|
|
align-items: center; |
|
|
align-items: center; |
|
|
@ -250,6 +247,7 @@ export default { |
|
|
box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.12), 0 0 3px 0 rgba(0, 0, 0, 0.04); |
|
|
box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.12), 0 0 3px 0 rgba(0, 0, 0, 0.04); |
|
|
padding-bottom: 0; |
|
|
padding-bottom: 0; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
.tag-style { |
|
|
.tag-style { |
|
|
display: flex; |
|
|
display: flex; |
|
|
align-items: center; |
|
|
align-items: center; |
|
|
@ -259,36 +257,44 @@ export default { |
|
|
position: relative; |
|
|
position: relative; |
|
|
margin: 0 64px 0 138px; |
|
|
margin: 0 64px 0 138px; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
.scrollWrapper { |
|
|
.scrollWrapper { |
|
|
display: flex; |
|
|
display: flex; |
|
|
align-items: center; |
|
|
align-items: center; |
|
|
overflow-x: auto; |
|
|
overflow-x: auto; |
|
|
transition: all 500ms linear; |
|
|
transition: all 500ms linear; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
.scrollWrapper::-webkit-scrollbar { |
|
|
.scrollWrapper::-webkit-scrollbar { |
|
|
height: 0; |
|
|
height: 0; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
.el-tag { |
|
|
.el-tag { |
|
|
margin: 0 5px; |
|
|
margin: 0 5px; |
|
|
cursor: pointer; |
|
|
cursor: pointer; |
|
|
padding: 0 0px 0 10px; |
|
|
padding: 0 0px 0 10px; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
.el-tag .el-tag--info { |
|
|
.el-tag .el-tag--info { |
|
|
background: #fff; |
|
|
background: #fff; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
::v-deep .el-tag .el-icon-close { |
|
|
::v-deep .el-tag .el-icon-close { |
|
|
right: 0px; |
|
|
right: 0px; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
.arrow-icon { |
|
|
.arrow-icon { |
|
|
pointer-events: all; |
|
|
pointer-events: all; |
|
|
cursor: pointer; |
|
|
cursor: pointer; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
.arrow-style { |
|
|
.arrow-style { |
|
|
font-size: 16px; |
|
|
font-size: 16px; |
|
|
padding: 0 8px; |
|
|
padding: 0 8px; |
|
|
position: relative; |
|
|
position: relative; |
|
|
top: 8px; |
|
|
top: 8px; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
.arrow-icon .el-button { |
|
|
.arrow-icon .el-button { |
|
|
padding: 0px 5px; |
|
|
padding: 0px 5px; |
|
|
height: 28px; |
|
|
height: 28px; |
|
|
|