mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
用户详情页面
This commit is contained in:
1 parent
26c467f60f
commit
0e590ebe0d
4 files changed
+64
-214
No files matched your search
+6
-1
@@ -1,7 +1,7 @@
|
||||
const
|
||||
system = require('./system'),
|
||||
{ UserNotFoundError, UserAlreadyExistError } = require('../error'),
|
||||
pwhash = require('./lib/pwhash'),
|
||||
pwhash = require('../lib/pwhash'),
|
||||
validator = require('../lib/validator'),
|
||||
db = require('../service/db'),
|
||||
coll = db.collection('user'),
|
||||
@@ -18,6 +18,11 @@ class USER {
|
||||
this.lang = user.language || 'zh_CN';
|
||||
this.codeLang = user.codeLang || 'c';
|
||||
this.codeTemplate = user.codeTemplate || '';
|
||||
this.regat = user.regat;
|
||||
this.loginat = user.loginat;
|
||||
this.bio = user.bio || '';
|
||||
this.nAccept = user.nAccept || 0;
|
||||
this.nSubmit = user.nSubmit || 0;
|
||||
}
|
||||
hasPerm(perm) {
|
||||
return this.perm == '-' || (this.perm || '').includes(perm);
|
||||
|
||||
Reference in new issue
Block a user