| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263 |
- <template>
- <div id="app">
- <!-- <router-view /> -->
- <keep-alive :include="cachedViews">
- <router-view></router-view>
- </keep-alive>
- </div>
- </template>
- <script>
- import { delAllTabsKey } from "@/util/keyData";
- import { mapState } from "vuex";
- export default {
- name: "app",
- data() {
- return {};
- },
- watch: {
- cachedViews: {
- handler(val) {
- console.log('监听组件暂存',val);
- },
- deep: true,
- immediate: true
- }
- },
- mounted() {
- //刷新浏览器清除标签key
- delAllTabsKey("ALL");
- },
- methods: {},
- computed: {
- ...mapState({
- cachedViews: state => state.tags.cachedViews
- })
- }
- };
- </script>
- <style lang="scss">
- #app {
- width: 100%;
- height: 100%;
- overflow: hidden;
- }
- .el-input.is-disabled .el-input__inner {
- color: #000000 !important;
- background-color: #fafafa !important;
- }
- .el-textarea.is-disabled .el-textarea__inner {
- color: #000000 !important;
- background-color: #fafafa !important;
- }
- .el-range-editor.is-disabled input {
- color: #000000 !important;
- background-color: #fafafa !important;
- }
- .el-dialog__headerbtn {
- top: 9px !important;
- }
- .el-dialog__headerbtn {
- margin-top: 5px !important;
- }
- </style>
|