🐞 fix(gvg): 修复战区问题,不跨服服务器应单列

This commit is contained in:
luying
2023-02-20 20:46:20 +08:00
parent 015b4293fb
commit 5b3747a78e
27 changed files with 324 additions and 390 deletions
+5 -2
View File
@@ -10,6 +10,9 @@ export default class GVGRec extends BaseModel {
@prop({ required: true, default: '' })
leagueCode: string; // 联军id
@prop({ required: false, default: '' })
groupKey: string; // 战区
@prop({ required: false, default: '' })
roleId: string; // 玩家id
@@ -45,8 +48,8 @@ export default class GVGRec extends BaseModel {
}
// 查询城池战报
public static async findBattleRecByCity(configId: number, groupId: number, serverType: number, cityId: number) {
const result: GVGRecType[] = await GVGRecModel.find({ cityId, configId, groupId, serverType, type: GVG_REC_TYPE.BATTLE_BY_CITY }, { _id: 0, recId: 1, params: 1, createTime: 1 }).sort({ createTime: -1 }).limit(50).lean();
public static async findBattleRecByCity(configId: number, groupKey: string, cityId: number) {
const result: GVGRecType[] = await GVGRecModel.find({ cityId, configId, groupKey, type: GVG_REC_TYPE.BATTLE_BY_CITY }, { _id: 0, recId: 1, params: 1, createTime: 1 }).sort({ createTime: -1 }).limit(50).lean();
return result;
}