miao-plugin/models/Profile.js
2022-11-12 05:57:13 +08:00

31 lines
516 B
JavaScript

import Base from './Base.js'
export default class Profile extends Base {
constructor (uid) {
super()
if (!uid) {
return false
}
let cacheObj = this._getCache(`profile:${uid}`)
if (cacheObj) {
return cacheObj
}
this.uid = uid
return this._cache()
}
getProfileData () {
}
static create (uid) {
let profile = new Profile(uid)
return profile
}
static get (uid, id) {
let profile = Profile.create(uid)
return profile.getProfileData(id)
}
}