fix:fightlog添加ttl
This commit is contained in:
parent
0d736e4854
commit
666b7e51c5
@ -1,4 +1,4 @@
|
||||
import {fightResult} from '../shared/fightControl/fightType';
|
||||
|
||||
|
||||
export type CollectionFightLog = fightResult & { uid: string, type: string };
|
||||
export type CollectionFightLog = fightResult & { uid: string, type: string, ttl: Date};
|
@ -137,7 +137,7 @@ export class FightFun {
|
||||
let writeList = ['ganhai', 'jjc', 'hbzbJfs', 'hbzbZbs', 'slzd', 'clsl']
|
||||
if (uid.indexOf('npc') != -1 || !writeList.includes(type)) return;
|
||||
|
||||
G.mongodb.collection('fightLog').insertOne({ uid, type, ...result })
|
||||
G.mongodb.collection('fightLog').insertOne({ uid, type, ...result, ttl: new Date() })
|
||||
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user