diff --git a/src/app/app.module.ts b/src/app/app.module.ts index d538857..79af618 100644 --- a/src/app/app.module.ts +++ b/src/app/app.module.ts @@ -30,6 +30,7 @@ import {ServerService} from "./services/server.service"; import {registerLocaleData} from "@angular/common"; import localeRu from "@angular/common/locales/ru"; import {Tf2dataService} from "./services/tf2data.service"; +import {MatDividerModule} from "@angular/material/divider"; registerLocaleData(localeRu, "ru") @@ -43,24 +44,25 @@ registerLocaleData(localeRu, "ru") RulesPageComponent, BanlistPageComponent ], - imports: [ - BrowserModule, - AppRoutingModule, - BrowserAnimationsModule, - MatToolbarModule, - MatIconModule, - MatButtonModule, - MatGridListModule, - MatCardModule, - MatInputModule, - MatChipsModule, - MatExpansionModule, - MatMenuModule, - HttpClientModule, - MatSnackBarModule, - MatAutocompleteModule, - FormsModule - ], + imports: [ + BrowserModule, + AppRoutingModule, + BrowserAnimationsModule, + MatToolbarModule, + MatIconModule, + MatButtonModule, + MatGridListModule, + MatCardModule, + MatInputModule, + MatChipsModule, + MatExpansionModule, + MatMenuModule, + HttpClientModule, + MatSnackBarModule, + MatAutocompleteModule, + FormsModule, + MatDividerModule + ], providers: [ {provide: LOCALE_ID, useValue: 'ru' }, AnnonceService, diff --git a/src/app/entities/profile/Permition.ts b/src/app/entities/profile/Permition.ts new file mode 100644 index 0000000..ea223d9 --- /dev/null +++ b/src/app/entities/profile/Permition.ts @@ -0,0 +1,7 @@ +export interface Permition { + flags: string; + u_timestamp: number; + amount: number; + immunity: number; + status: string +} diff --git a/src/app/entities/profile/PlayOn.ts b/src/app/entities/profile/PlayOn.ts new file mode 100644 index 0000000..bb00153 --- /dev/null +++ b/src/app/entities/profile/PlayOn.ts @@ -0,0 +1,7 @@ +export interface PlayOn { + server_id: string; + player_id: number; + ip: string; + name: string; + country: string; +} diff --git a/src/app/entities/profile/PlayerProfile.ts b/src/app/entities/profile/PlayerProfile.ts index a9ebe24..fe895a5 100644 --- a/src/app/entities/profile/PlayerProfile.ts +++ b/src/app/entities/profile/PlayerProfile.ts @@ -1,22 +1,26 @@ import {SteamData} from "./SteamData"; import {SteamIDs} from "./SteamIDs"; +import {Ban} from "../ban/Ban"; +import {Permition} from "./Permition"; +import {Reports} from "./Reports"; +import {PlayOn} from "./PlayOn"; export class PlayerProfile { - ban: any|null = null; + ban: Ban|null = null; gametime: {[srv_name: string]: {[map_name: string]: number}} = {}; lastplay: {[srv_name: string]: {[map_name: string]: number}} = {}; - permition: any|null = null; + permition: Permition|null = null; response_time: {[request: string]: number} = {}; steam_data: SteamData|null = null; steamids: SteamIDs|null = null; - play_on: any|null = null; + play_on: PlayOn|null = null; attached_discords: any[]|null = null; donates: any[]|null = null; ban_list: any[]|null = null; killfeed: any|null = null; killfeed_current: any = null; - messages: any = null; - reports: any = null; + messages: number|null = null; + reports: Reports|null = null; static fromData(data:any): PlayerProfile { const p = new PlayerProfile(); diff --git a/src/app/entities/profile/ProfileRequestData.ts b/src/app/entities/profile/ProfileRequestData.ts index 4d7f3d7..8b24214 100644 --- a/src/app/entities/profile/ProfileRequestData.ts +++ b/src/app/entities/profile/ProfileRequestData.ts @@ -16,7 +16,8 @@ export class ProfileRequestData { ProfileRequestData.PLAY_ON, ProfileRequestData.PERMITION, ProfileRequestData.BAN, - ProfileRequestData.STEAM_DATA + ProfileRequestData.STEAM_DATA, + ProfileRequestData.REPORTS ] param: string; description: string; diff --git a/src/app/entities/profile/Reports.ts b/src/app/entities/profile/Reports.ts new file mode 100644 index 0000000..c89e555 --- /dev/null +++ b/src/app/entities/profile/Reports.ts @@ -0,0 +1,5 @@ +export interface Reports { + created: number; + accepted: number; + selfcount: number; +} diff --git a/src/app/pages/profile-page/profile-page.component.html b/src/app/pages/profile-page/profile-page.component.html index d31157d..fd0c39d 100644 --- a/src/app/pages/profile-page/profile-page.component.html +++ b/src/app/pages/profile-page/profile-page.component.html @@ -15,7 +15,166 @@
Профиль малютки
+Steam64: {{profile.steamids.steam64}}
+Steam3: {{profile.steamids.steam3}}
+Steam2: {{profile.steamids.steam2}}
+Назначены: {{profile.permition.u_timestamp * 1000 | date:"hh:mm dd.MM.YYYY"}}
+{{profile.permition.amount == 0?'Выданы на неопределенный срок':'Выданы до: ' + (((profile.permition.u_timestamp + profile.permition.amount) * 1000)| date:"hh:mm dd.MM.YYYY")}}
+Причина: {{profile.ban.ban_reason}}
+Дата: {{profile.ban.ban_utime*1000 | date:"hh:mm dd.MM.YYYY"}}
+ебануть табличку где по серверам выборка когда чел полсдений раз заходил
+ебануть табличку где разпределение по времени
+Тоже табличку
+Табличка где каво когда
+Табличку с репортом
+табличку с поиском сообщений
+табличку с убийствами
+huy
+{{req.key}} - {{req.value*1000}} милисекунды
+