You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
OneAuth/oafAdmin/src/store/user.ts

24 lines
399 B
TypeScript

3 years ago
/*
* @name: user
* @author: veypi <i@veypi.com>
* @date: 2022-04-16 10:57
* @descriptionuser
*/
import {defineStore} from 'pinia'
export const useUserStore = defineStore('user', {
state: () => {
return {
id: 0,
username: '',
}
},
actions: {
setUser() {
this.id = 1
this.username = 'admin'
},
},
})