| | |
| | | data() { |
| | | return { |
| | | buttonAuthority: sessionStorage.getItem('buttonAuthoritys') || [], |
| | | defaultBgUrl:"/images/desktop/background.png" |
| | | // defaultBgUrl:"/images/desktop/background.png" |
| | | } |
| | | }, |
| | | computed: { |
| | |
| | | ) |
| | | } |
| | | return false |
| | | }, |
| | | defaultBgUrl(){ |
| | | return JSON.parse(sessionStorage.getItem('userInfo')).backgroundpic |
| | | } |
| | | }, |
| | | mounted() { |
| | | // document.getElementById('app').style.backgroundImage = process.env.VUE_APP_MAIN_URL; |
| | | const url = localStorage.getItem("backgroundPic") |
| | | document.getElementById('app').style.backgroundImage = `url(${url||this.defaultBgUrl})` |
| | | document.getElementById('app').style.backgroundImage = `url(${this.defaultBgUrl})` |
| | | this.showApps(); |
| | | let _that = this; |
| | | let msgResp = require("./mock/messages.json") |
| | |
| | | }, |
| | | onChangeBg(v){ |
| | | document.getElementById('app').style.backgroundImage = "url(" + v + ")" |
| | | this.defaultBgUrl = v |
| | | localStorage.setItem("backgroundPic", v) |
| | | }, |
| | | showApps() { |
| | | let _that = this; |