Sign in

cnlive_project / cnlive-community-web-vue · Files

GitLab

  • Back to group
  • Project
  • Activity
  • Files
  • Commits
  • Network
  • Graphs
  • Milestones
  • Issues 0
  • Merge Requests 0
  • Labels
  • Wiki
  • cnlive-community-web-vue
  • src
  • pinia
  • modules
  • login.ts
  • login
    eab5869b
    杨泽宇 authored
    2022-01-10 13:38:02 +0800  
    Browse Code »
login.ts 339 Bytes
Edit Raw Blame History
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25
const id = 'login'
const state = () => ({
  token: '',
})
const getters = {
  // getCollapseStatus () {
  //   return this.isCollapse
  // }
  getToken() {
    return this.token
  }
}
const actions = {
  setToken(tokenStr: string) {
    this.token = tokenStr
  }
}

export default {
  namespace: true,
  actions,
  getters,
  state,
  id
}