forked from Dri0m/flashpoint-submission-system
-
Notifications
You must be signed in to change notification settings - Fork 1
/
pagedata.go
164 lines (144 loc) · 3.32 KB
/
pagedata.go
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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
package types
type BasePageData struct {
Username string
UserID int64
AvatarURL string
UserRoles []string
IsDevInstance bool
}
type ProfilePageData struct {
BasePageData
NotificationActions []string
}
type MetadataStatsPageDataBare struct {
TotalGames int64
TotalAnimations int64
TotalTags int64
TotalPlatforms int64
TotalLegacy int64
}
type MetadataStatsPageData struct {
BasePageData
MetadataStatsPageDataBare
}
type TagsPageData struct {
BasePageData
Tags []*Tag
Categories []*TagCategory
TotalCount int64
}
type TagsPageDataJSON struct {
Tags []*Tag `json:"tags"`
Categories []*TagCategory `json:"categories"`
}
type PlatformsPageData struct {
BasePageData
Platforms []*Platform
TotalCount int64
}
type TagPageData struct {
BasePageData
Tag *Tag
Categories []*TagCategory
Revisions []*RevisionInfo
GamesUsing int64
}
type GamePageData struct {
BasePageData
Game *Game
GameAvatarURL string
GameAuthorID int64
GameUsername string
Revisions []*RevisionInfo
LogoUrl string
ScreenshotUrl string
ImagesCdn string
ValidDeleteReasons []string
ValidRestoreReasons []string
}
type GameDataIndexFile struct {
SHA256 string `json:"sha256"`
SHA1 string `json:"sha1"`
CRC32 string `json:"crc32"`
MD5 string `json:"md5"`
Path string `json:"path"`
Size int64 `json:"size"`
}
type GameDataIndex struct {
GameID string `json:"game_id"`
Date int64 `json:"date_added"`
Data []GameDataIndexFile `json:"data"`
}
type GameDataPageData struct {
BasePageData
GameData *GameData
}
type GameDataIndexPageData struct {
BasePageData
Index *GameDataIndex
}
type SubmissionsPageData struct {
BasePageData
Submissions []*ExtendedSubmission
TotalCount int64
Filter SubmissionsFilter
FilterLayout string
}
type ApplyContentPatchPageData struct {
BasePageData
SubmissionID int64
CurationMeta *CurationMeta
ExistingMeta *Game
}
type ViewSubmissionPageData struct {
SubmissionsPageData
CurationMeta *CurationMeta
Comments []*ExtendedComment
IsUserSubscribed bool
CurationImageIDs []int64
NextSubmissionID *int64
PreviousSubmissionID *int64
TagList []Tag
}
type SubmissionsFilesPageData struct {
BasePageData
SubmissionFiles []*ExtendedSubmissionFile
}
type SearchFlashfreezePageData struct {
BasePageData
FlashfreezeFiles []*ExtendedFlashfreezeItem
TotalCount int64
Filter FlashfreezeFilter
}
type StatisticsPageData struct {
BasePageData
SubmissionCount int64
SubmissionCountBotHappy int64
SubmissionCountBotSad int64
SubmissionCountApproved int64
SubmissionCountVerified int64
SubmissionCountRejected int64
SubmissionCountInFlashpoint int64
UserCount int64
CommentCount int64
FlashfreezeCount int64
FlashfreezeFileCount int64
TotalSubmissionSize int64
TotalFlashfreezeSize int64
}
type UserStatisticsPageData struct {
BasePageData
Users []*UserStatistics
}
type DeviceAuthStates struct {
Pending int64
Complete int64
Expired int64
Denied int64
}
type DeviceAuthPageData struct {
BasePageData
Token *DeviceFlowToken
States DeviceAuthStates
Scopes []AuthScope
}