🎈 perf(热更新): 添加白名单热更新地址
This commit is contained in:
@@ -18,26 +18,17 @@ export default class RegionWhiteList extends BaseModel {
|
||||
|
||||
@prop({ required: true })
|
||||
ip: string; // ip
|
||||
|
||||
@prop({ required: true })
|
||||
serverId: number; // 小区id
|
||||
|
||||
@prop({ required: true })
|
||||
uid: number; // 玩家uid
|
||||
|
||||
@prop({ required: true })
|
||||
roleId: string; // 玩家角色id
|
||||
|
||||
@prop({ required: true })
|
||||
roleName: string; // 玩家角色名
|
||||
|
||||
public static async checkIp(env: string, ip: string) {
|
||||
const rec = await WhiteListModel.exists({ env, ip });
|
||||
return rec;
|
||||
}
|
||||
|
||||
public static async checkUid(env: string, serverId: number, uid: number) {
|
||||
const rec = await WhiteListModel.exists({ env, serverId, uid });
|
||||
public static async checkUid(env: string, uid: number) {
|
||||
const rec = await WhiteListModel.exists({ env, uid });
|
||||
return rec;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user