| | |
| | | import BasicSetting from "../components/BasicSetting"; |
| | | |
| | | export default { |
| | | name: 'settings', |
| | | name: "settings", |
| | | components: { |
| | | BasicSetting |
| | | BasicSetting, |
| | | }, |
| | | data() { |
| | | return { |
| | | activeName: "basic", |
| | | buttonAuthority: sessionStorage.getItem("buttonAuthoritys") || [], |
| | | loginName: JSON.parse(sessionStorage.getItem("userInfo")).username || "用户名" |
| | | } |
| | | loginName: |
| | | JSON.parse(sessionStorage.getItem("userInfo")).username || "用户名", |
| | | }; |
| | | }, |
| | | computed: { |
| | | isAdmin() { |
| | |
| | | return loginName === "superadmin" || loginName === "basic"; |
| | | } |
| | | return false; |
| | | } |
| | | }, |
| | | }, |
| | | methods: { |
| | | isShow(authority) { |
| | |
| | | }, |
| | | }, |
| | | created() { |
| | | if (this.isShow('videoSystem:base')) { |
| | | this.activeName = "basic" |
| | | } else if (this.isShow('videoSystem:permission')) { |
| | | this.activeName = "user" |
| | | } else if (this.isShow('videoSystem:broadcast')) { |
| | | this.activeName = "radio" |
| | | } else if (this.isShow('videoSystem:eventPush')) { |
| | | this.activeName = "event" |
| | | } else if (this.isShow('videoSystem:logManage')) { |
| | | this.activeName = "log" |
| | | } else if (this.isShow('videoSystem:sysManage')) { |
| | | this.activeName = "system" |
| | | if (this.isShow("videoSystem:base")) { |
| | | this.activeName = "basic"; |
| | | } else if (this.isShow("videoSystem:permission")) { |
| | | this.activeName = "user"; |
| | | } else if (this.isShow("videoSystem:broadcast")) { |
| | | this.activeName = "radio"; |
| | | } else if (this.isShow("videoSystem:eventPush")) { |
| | | this.activeName = "event"; |
| | | } else if (this.isShow("videoSystem:logManage")) { |
| | | this.activeName = "log"; |
| | | } else if (this.isShow("videoSystem:sysManage")) { |
| | | this.activeName = "system"; |
| | | } |
| | | }, |
| | | }; |