forked from rickaard/swiss-tournament
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMONGODB.js
67 lines (66 loc) · 1.16 KB
/
MONGODB.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
const mongodb = {
tournamentName: "tournament",
authId: 'sadkj2323A',
teams: [
{
name: 'Zerowin',
wins: 0,
losses: 1
},
{
name: 'PIMPs',
wins: 1,
losses: 0
}
],
pools: [
{
round: 1,
wins: 0,
losses: 0,
type: '0-0',
games: [
{
home: "PIMPs",
away: "Zerowin",
homeScore: 10,
awayScore: 8
},
{
home: "team2",
away: "anonym",
homeScore: 7,
awayScore: 10
}
]
},
{
round: 2,
type: '1-0',
wins: 1,
losses: 0,
games: [
{
home: "PIMPs",
away: "anonym",
homeScore: undefined,
awayScore: undefined
}
]
},
{
round: 2,
type: '0-1',
wins: 0,
losses: 1,
games: [
{
home: "Zerowin",
away: "team2",
homeScore: undefined,
awayScore: undefined
}
]
},
]
}