@mtgame/core 0.2.72 → 0.2.73

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -25,6 +25,7 @@ export * from './tournament-stage-api';
25
25
  export * from './user-api';
26
26
  export * from './volleyball-game-api';
27
27
  export * from './waterpolo-game-api';
28
+ export * from './wrestball-game-api';
28
29
  export * from './public-team-api';
29
30
  export * from './public-user-api';
30
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVibGljLWFwaS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3Byb2plY3RzL2NvcmUvc3JjL2FwaS9wdWJsaWMtYXBpLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLGNBQWMsdUJBQXVCLENBQUM7QUFDdEMsY0FBYyxnQkFBZ0IsQ0FBQztBQUMvQixjQUFjLFlBQVksQ0FBQztBQUMzQixjQUFjLGlCQUFpQixDQUFDO0FBQ2hDLGNBQWMsbUJBQW1CLENBQUM7QUFDbEMsY0FBYyxxQkFBcUIsQ0FBQztBQUNwQyxjQUFjLHFCQUFxQixDQUFDO0FBQ3BDLGNBQWMsY0FBYyxDQUFDO0FBQzdCLGNBQWMsbUJBQW1CLENBQUM7QUFDbEMsY0FBYyxxQkFBcUIsQ0FBQztBQUNwQyxjQUFjLGFBQWEsQ0FBQztBQUM1QixjQUFjLG9CQUFvQixDQUFDO0FBQ25DLGNBQWMseUJBQXlCLENBQUM7QUFDeEMsY0FBYyx3QkFBd0IsQ0FBQztBQUN2QyxjQUFjLGdDQUFnQyxDQUFDO0FBQy9DLGNBQWMsaUJBQWlCLENBQUM7QUFDaEMsY0FBYyxrQkFBa0IsQ0FBQztBQUNqQyxjQUFjLFlBQVksQ0FBQztBQUMzQixjQUFjLGtCQUFrQixDQUFDO0FBQ2pDLGNBQWMsa0JBQWtCLENBQUM7QUFDakMsY0FB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gJy4vcHVibGljLXVzZXItYXBpJztcbiJdfQ==
@@ -0,0 +1,49 @@
1
+ import { __awaiter } from "tslib";
2
+ import { Injectable } from '@angular/core';
3
+ import { HttpClient } from '@angular/common/http';
4
+ import { map } from 'rxjs/operators';
5
+ import { Game } from '../models/game';
6
+ import { ConfigService } from '../services/config.service';
7
+ import { GameBaseApi } from './game-base-api';
8
+ import { WrestballGameTeamStatistic } from '../models/wrestball-game-team-statistic';
9
+ import { WrestballGameStatistic } from '../models/wrestball-game-statistic';
10
+ import { WrestballGameLog } from '../models/wrestball-game-log';
11
+ import * as i0 from "@angular/core";
12
+ import * as i1 from "@angular/common/http";
13
+ import * as i2 from "../services/config.service";
14
+ export class WrestballGameApi extends GameBaseApi {
15
+ constructor(httpClient, configService) {
16
+ super(httpClient, configService);
17
+ this.httpClient = httpClient;
18
+ this.configService = configService;
19
+ }
20
+ getById(gameId) {
21
+ return __awaiter(this, void 0, void 0, function* () {
22
+ return this.httpClient.get(`${this.configService.get('apiUrl')}/api/v1/tournament_wrestball_game/${gameId}/`).pipe(map(result => Game.toFront(result))).toPromise();
23
+ });
24
+ }
25
+ getTeamStatistic(gameId) {
26
+ return __awaiter(this, void 0, void 0, function* () {
27
+ return this.httpClient.get(`${this.configService.get('apiUrl')}/api/v1/tournament_wrestball_game/${gameId}/team_statistic/`).pipe(map(result => WrestballGameTeamStatistic.toFront(result))).toPromise();
28
+ });
29
+ }
30
+ getUserStatistic(gameId) {
31
+ return __awaiter(this, void 0, void 0, function* () {
32
+ return this.httpClient.get(`${this.configService.get('apiUrl')}/api/v1/tournament_wrestball_game/${gameId}/user_statistic/`).pipe(map(result => WrestballGameStatistic.toFront(result))).toPromise();
33
+ });
34
+ }
35
+ getLogs(gameId) {
36
+ return __awaiter(this, void 0, void 0, function* () {
37
+ return this.httpClient.get(`${this.configService.get('apiUrl')}/api/v1/tournament_wrestball_game/${gameId}/logs/`).pipe(map(result => WrestballGameLog.toFront(result))).toPromise();
38
+ });
39
+ }
40
+ }
41
+ WrestballGameApi.ɵprov = i0.ɵɵdefineInjectable({ factory: function WrestballGameApi_Factory() { return new WrestballGameApi(i0.ɵɵinject(i1.HttpClient), i0.ɵɵinject(i2.ConfigService)); }, token: WrestballGameApi, providedIn: "root" });
42
+ WrestballGameApi.decorators = [
43
+ { type: Injectable, args: [{ providedIn: 'root' },] }
44
+ ];
45
+ WrestballGameApi.ctorParameters = () => [
46
+ { type: HttpClient },
47
+ { type: ConfigService }
48
+ ];
49
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoid3Jlc3RiYWxsLWdhbWUtYXBpLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vcHJvamVjdHMvY29yZS9zcmMvYXBpL3dyZXN0YmFsbC1nYW1lLWFwaS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQUEsT0FBTyxFQUFFLFVBQVUsRUFBRSxNQUFNLGVBQWUsQ0FBQztBQUMzQyxPQUFPLEVBQUUsVUFBVSxFQUFFLE1BQU0sc0JBQXNCLENBQUM7QUFDbEQsT0FBTyxFQUFFLEdBQUcsRUFBRSxNQUFNLGdCQUFnQixDQUFDO0FBQ3JDLE9BQU8sRUFBRSxJQUFJLEVBQUUsTUFBTSxnQkFBZ0IsQ0FBQztBQUN0QyxPQUFPLEVBQUUsYUFBYSxFQUFFLE1BQU0sNEJBQTRCLENBQUM7QUFDM0QsT0FBTyxFQUFFLFdBQVcsRUFBRSxNQUFNLGlCQUFpQixDQUFDO0FBQzlDLE9BQU8sRUFBRSwwQkFBMEIsRUFBRSxNQUFNLHlDQUF5QyxDQUFDO0FBQ3JGLE9BQU8sRUFBRSxzQkFBc0IsRUFBRSxNQUFNLG9DQUFvQyxDQUFDO0FBQzVFLE9BQU8sRUFBRSxnQkFBZ0IsRUFBRSxNQUFNLDhCQUE4QixDQUFDOzs7O0FBR2hFLE1BQU0sT0FBTyxnQkFBaU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ctorParameters = () => [
10333
10333
  { type: ConfigService }
10334
10334
  ];
10335
10335
 
10336
+ let WrestballGameTeamStatistic = class WrestballGameTeamStatistic extends BaseModel {
10337
+ static toFront(data) { }
10338
+ static toBack(data) { }
10339
+ };
10340
+ __decorate([
10341
+ ToFrontHook
10342
+ ], WrestballGameTeamStatistic, "toFront", null);
10343
+ __decorate([
10344
+ ToBackHook
10345
+ ], WrestballGameTeamStatistic, "toBack", null);
10346
+ WrestballGameTeamStatistic = __decorate([
10347
+ ModelInstance({
10348
+ mappingFields: {
10349
+ team: 'team',
10350
+ competitor_team: 'competitorTeam'
10351
+ },
10352
+ relation: {
10353
+ team: WrestballStatistic,
10354
+ competitorTeam: WrestballStatistic
10355
+ }
10356
+ })
10357
+ ], WrestballGameTeamStatistic);
10358
+
10359
+ let WrestballGameStatistic = class WrestballGameStatistic extends BaseModel {
10360
+ get id() {
10361
+ return this.gameUserId;
10362
+ }
10363
+ static toFront(data) { }
10364
+ static toBack(data) { }
10365
+ get totalFouls() {
10366
+ return (this.personalFouls || 0) + (this.technicalFouls || 0) + (this.unsportsmanlikeFouls || 0) + (this.disqualificationFouls || 0);
10367
+ }
10368
+ set onePointPercent(v) { }
10369
+ get onePointPercent() {
10370
+ if (!this.onePointsMade || !this.onePointAttempts) {
10371
+ return 0;
10372
+ }
10373
+ return Math.round(1000 * this.onePointsMade / this.onePointAttempts) / 10;
10374
+ }
10375
+ set twoPointPercent(v) { }
10376
+ get twoPointPercent() {
10377
+ if (!this.twoPointsMade || !this.twoPointAttempts) {
10378
+ return 0;
10379
+ }
10380
+ return Math.round(1000 * this.twoPointsMade / this.twoPointAttempts) / 10;
10381
+ }
10382
+ set threePointPercent(v) { }
10383
+ get threePointPercent() {
10384
+ if (!this.threePointsMade || !this.threePointAttempts) {
10385
+ return 0;
10386
+ }
10387
+ return Math.round(1000 * this.threePointsMade / this.threePointAttempts) / 10;
10388
+ }
10389
+ set freeThrowPercent(v) { }
10390
+ get freeThrowPercent() {
10391
+ if (!this.freeThrowsMade || !this.freeThrowAttempts) {
10392
+ return 0;
10393
+ }
10394
+ return Math.round(1000 * this.freeThrowsMade / this.freeThrowAttempts) / 10;
10395
+ }
10396
+ get totalRebounds() {
10397
+ return Math.floor(10 * ((this.offensiveRebounds || 0) + (this.defensiveRebounds || 0))) / 10;
10398
+ }
10399
+ get wrestlerScrums() {
10400
+ return (this.wrestlerScrumsWon || 0) + (this.wrestlerScrumsLost || 0) + (this.wrestlerScrumsTie || 0);
10401
+ }
10402
+ get scrums() {
10403
+ return (this.scrumsWon || 0) + (this.scrumsLost || 0) + (this.scrumsTie || 0);
10404
+ }
10405
+ };
10406
+ __decorate([
10407
+ ToFrontHook
10408
+ ], WrestballGameStatistic, "toFront", null);
10409
+ __decorate([
10410
+ ToBackHook
10411
+ ], WrestballGameStatistic, "toBack", null);
10412
+ WrestballGameStatistic = __decorate([
10413
+ ModelInstance({
10414
+ mappingFields: {
10415
+ game_user_id: 'gameUserId',
10416
+ points: 'points',
10417
+ free_throws_made: 'freeThrowsMade',
10418
+ two_points_made: 'twoPointsMade',
10419
+ three_points_made: 'threePointsMade',
10420
+ one_points_made: 'onePointsMade',
10421
+ two_point_attempts: 'twoPointAttempts',
10422
+ three_point_attempts: 'threePointAttempts',
10423
+ free_throw_attempts: 'freeThrowAttempts',
10424
+ one_point_attempts: 'onePointAttempts',
10425
+ one_point_percent: 'onePointPercent',
10426
+ two_point_percent: 'twoPointPercent',
10427
+ three_point_percent: 'threePointPercent',
10428
+ free_throw_percent: 'freeThrowPercent',
10429
+ assists: 'assists',
10430
+ blocks: 'blocks',
10431
+ rebounds: 'rebounds',
10432
+ offensive_rebounds: 'offensiveRebounds',
10433
+ defensive_rebounds: 'defensiveRebounds',
10434
+ steals: 'steals',
10435
+ turnovers: 'turnovers',
10436
+ personal_fouls: 'personalFouls',
10437
+ drawn_fouls: 'drawnFouls',
10438
+ wrestler_scrums_won: 'wrestlerScrumsWon',
10439
+ wrestler_scrums_lost: 'wrestlerScrumsLost',
10440
+ wrestler_scrums_tie: 'wrestlerScrumsTie',
10441
+ wrestler_scrum_points: 'wrestlerScrumPoints',
10442
+ scrums_won: 'scrumsWon',
10443
+ scrums_lost: 'scrumsLost',
10444
+ scrums_tie: 'scrumsTie',
10445
+ scrum_points: 'scrumPoints',
10446
+ yellow_cards: 'yellowCards',
10447
+ red_cards: 'redCards',
10448
+ updated_at: 'updatedAt',
10449
+ },
10450
+ relation: {
10451
+ updatedAt: DateTimeField,
10452
+ }
10453
+ })
10454
+ ], WrestballGameStatistic);
10455
+
10456
+ var WrestballGameLogTypes;
10457
+ (function (WrestballGameLogTypes) {
10458
+ WrestballGameLogTypes[WrestballGameLogTypes["enter_game"] = 1] = "enter_game";
10459
+ WrestballGameLogTypes[WrestballGameLogTypes["exit_game"] = 2] = "exit_game";
10460
+ WrestballGameLogTypes[WrestballGameLogTypes["remove_game"] = 3] = "remove_game";
10461
+ WrestballGameLogTypes[WrestballGameLogTypes["one_point_made"] = 4] = "one_point_made";
10462
+ WrestballGameLogTypes[WrestballGameLogTypes["one_point_attempt"] = 5] = "one_point_attempt";
10463
+ WrestballGameLogTypes[WrestballGameLogTypes["two_point_made"] = 6] = "two_point_made";
10464
+ WrestballGameLogTypes[WrestballGameLogTypes["two_point_attempt"] = 7] = "two_point_attempt";
10465
+ WrestballGameLogTypes[WrestballGameLogTypes["three_point_made"] = 8] = "three_point_made";
10466
+ WrestballGameLogTypes[WrestballGameLogTypes["three_point_attempt"] = 9] = "three_point_attempt";
10467
+ WrestballGameLogTypes[WrestballGameLogTypes["free_throw_made"] = 10] = "free_throw_made";
10468
+ WrestballGameLogTypes[WrestballGameLogTypes["free_throw_attempt"] = 11] = "free_throw_attempt";
10469
+ WrestballGameLogTypes[WrestballGameLogTypes["assist"] = 12] = "assist";
10470
+ WrestballGameLogTypes[WrestballGameLogTypes["block"] = 13] = "block";
10471
+ WrestballGameLogTypes[WrestballGameLogTypes["rebound"] = 14] = "rebound";
10472
+ WrestballGameLogTypes[WrestballGameLogTypes["offensive_rebound"] = 15] = "offensive_rebound";
10473
+ WrestballGameLogTypes[WrestballGameLogTypes["defensive_rebound"] = 16] = "defensive_rebound";
10474
+ WrestballGameLogTypes[WrestballGameLogTypes["team_rebound"] = 17] = "team_rebound";
10475
+ WrestballGameLogTypes[WrestballGameLogTypes["steal"] = 18] = "steal";
10476
+ WrestballGameLogTypes[WrestballGameLogTypes["turnover"] = 19] = "turnover";
10477
+ WrestballGameLogTypes[WrestballGameLogTypes["personal_foul"] = 20] = "personal_foul";
10478
+ WrestballGameLogTypes[WrestballGameLogTypes["timeout"] = 21] = "timeout";
10479
+ WrestballGameLogTypes[WrestballGameLogTypes["wrestler_scrum"] = 22] = "wrestler_scrum";
10480
+ WrestballGameLogTypes[WrestballGameLogTypes["wrestler_scrum_won"] = 23] = "wrestler_scrum_won";
10481
+ WrestballGameLogTypes[WrestballGameLogTypes["wrestler_scrum_lost"] = 24] = "wrestler_scrum_lost";
10482
+ WrestballGameLogTypes[WrestballGameLogTypes["wrestler_scrum_tie"] = 25] = "wrestler_scrum_tie";
10483
+ WrestballGameLogTypes[WrestballGameLogTypes["scrum"] = 26] = "scrum";
10484
+ WrestballGameLogTypes[WrestballGameLogTypes["scrum_won"] = 27] = "scrum_won";
10485
+ WrestballGameLogTypes[WrestballGameLogTypes["scrum_lost"] = 28] = "scrum_lost";
10486
+ WrestballGameLogTypes[WrestballGameLogTypes["scrum_tie"] = 29] = "scrum_tie";
10487
+ WrestballGameLogTypes[WrestballGameLogTypes["yellow_card"] = 30] = "yellow_card";
10488
+ WrestballGameLogTypes[WrestballGameLogTypes["red_card"] = 31] = "red_card";
10489
+ })(WrestballGameLogTypes || (WrestballGameLogTypes = {}));
10490
+ let WrestballGameLog = class WrestballGameLog extends BaseModel {
10491
+ constructor() {
10492
+ super(...arguments);
10493
+ this.active = true;
10494
+ }
10495
+ isPointsType() {
10496
+ return [
10497
+ WrestballGameLogTypes.two_point_made,
10498
+ WrestballGameLogTypes.three_point_made,
10499
+ WrestballGameLogTypes.free_throw_made,
10500
+ WrestballGameLogTypes.one_point_made,
10501
+ WrestballGameLogTypes.scrum_won,
10502
+ WrestballGameLogTypes.wrestler_scrum_won,
10503
+ ].indexOf(this.logType) > -1;
10504
+ }
10505
+ isReboundType() {
10506
+ return [
10507
+ WrestballGameLogTypes.rebound,
10508
+ WrestballGameLogTypes.offensive_rebound,
10509
+ WrestballGameLogTypes.defensive_rebound,
10510
+ WrestballGameLogTypes.team_rebound,
10511
+ ].indexOf(this.logType) > -1;
10512
+ }
10513
+ isFoulType() {
10514
+ return [
10515
+ WrestballGameLogTypes.personal_foul,
10516
+ ].indexOf(this.logType) > -1;
10517
+ }
10518
+ getScore() {
10519
+ const scoreMapping = {
10520
+ [WrestballGameLogTypes.one_point_made]: 1,
10521
+ [WrestballGameLogTypes.free_throw_made]: 1,
10522
+ [WrestballGameLogTypes.two_point_made]: 2,
10523
+ [WrestballGameLogTypes.three_point_made]: 3,
10524
+ [WrestballGameLogTypes.scrum_won]: 2,
10525
+ [WrestballGameLogTypes.wrestler_scrum_won]: 2,
10526
+ };
10527
+ return scoreMapping[this.logType] || 0;
10528
+ }
10529
+ compare(model) {
10530
+ if (this.time === model.time && this.period === model.period) {
10531
+ if (this.datetime.getTime() === model.datetime.getTime()) {
10532
+ return this.id > model.id ? 1 : -1;
10533
+ }
10534
+ return this.datetime.getTime() < model.datetime.getTime() ? 1 : -1;
10535
+ }
10536
+ if (this.period === model.period) {
10537
+ return this.time < model.time ? 1 : -1;
10538
+ }
10539
+ return this.period < model.period ? 1 : -1;
10540
+ }
10541
+ get timeFormatted() {
10542
+ const minutes = Math.floor(this.time / 60);
10543
+ const seconds = this.time - minutes * 60;
10544
+ return `${minutes < 10 ? '0' : ''}${minutes}:${seconds < 10 ? '0' : ''}${seconds}`;
10545
+ }
10546
+ static toFront(value) { }
10547
+ static toBack(value) { }
10548
+ };
10549
+ __decorate([
10550
+ ToFrontHook
10551
+ ], WrestballGameLog, "toFront", null);
10552
+ __decorate([
10553
+ ToBackHook
10554
+ ], WrestballGameLog, "toBack", null);
10555
+ WrestballGameLog = __decorate([
10556
+ ModelInstance({
10557
+ mappingFields: {
10558
+ id: 'id',
10559
+ unique_id: 'uniqueId',
10560
+ game_id: 'gameId',
10561
+ game_user_id: 'gameUserId',
10562
+ team_id: 'teamId',
10563
+ log_type: 'logType',
10564
+ datetime: 'datetime',
10565
+ time: 'time',
10566
+ period: 'period',
10567
+ active: 'active',
10568
+ is_highlight: 'isHighlight',
10569
+ foul_on_game_user_id: 'foulOnGameUserId',
10570
+ is_coach: 'isCoach',
10571
+ is_bench: 'isBench',
10572
+ marked: 'marked',
10573
+ },
10574
+ relation: {
10575
+ datetime: DateTimeField,
10576
+ logType: enumField(WrestballGameLogTypes),
10577
+ }
10578
+ })
10579
+ ], WrestballGameLog);
10580
+
10581
+ class WrestballGameApi extends GameBaseApi {
10582
+ constructor(httpClient, configService) {
10583
+ super(httpClient, configService);
10584
+ this.httpClient = httpClient;
10585
+ this.configService = configService;
10586
+ }
10587
+ getById(gameId) {
10588
+ return __awaiter(this, void 0, void 0, function* () {
10589
+ return this.httpClient.get(`${this.configService.get('apiUrl')}/api/v1/tournament_wrestball_game/${gameId}/`).pipe(map(result => Game.toFront(result))).toPromise();
10590
+ });
10591
+ }
10592
+ getTeamStatistic(gameId) {
10593
+ return __awaiter(this, void 0, void 0, function* () {
10594
+ return this.httpClient.get(`${this.configService.get('apiUrl')}/api/v1/tournament_wrestball_game/${gameId}/team_statistic/`).pipe(map(result => WrestballGameTeamStatistic.toFront(result))).toPromise();
10595
+ });
10596
+ }
10597
+ getUserStatistic(gameId) {
10598
+ return __awaiter(this, void 0, void 0, function* () {
10599
+ return this.httpClient.get(`${this.configService.get('apiUrl')}/api/v1/tournament_wrestball_game/${gameId}/user_statistic/`).pipe(map(result => WrestballGameStatistic.toFront(result))).toPromise();
10600
+ });
10601
+ }
10602
+ getLogs(gameId) {
10603
+ return __awaiter(this, void 0, void 0, function* () {
10604
+ return this.httpClient.get(`${this.configService.get('apiUrl')}/api/v1/tournament_wrestball_game/${gameId}/logs/`).pipe(map(result => WrestballGameLog.toFront(result))).toPromise();
10605
+ });
10606
+ }
10607
+ }
10608
+ WrestballGameApi.ɵprov = i0.ɵɵdefineInjectable({ factory: function WrestballGameApi_Factory() { return new WrestballGameApi(i0.ɵɵinject(i1.HttpClient), i0.ɵɵinject(ConfigService)); }, token: WrestballGameApi, providedIn: "root" });
10609
+ WrestballGameApi.decorators = [
10610
+ { type: Injectable, args: [{ providedIn: 'root' },] }
10611
+ ];
10612
+ WrestballGameApi.ctorParameters = () => [
10613
+ { type: HttpClient },
10614
+ { type: ConfigService }
10615
+ ];
10616
+
10336
10617
  class PublicTeamApi {
10337
10618
  constructor(httpClient, configService) {
10338
10619
  this.httpClient = httpClient;
@@ -11006,251 +11287,6 @@ OrganizationStatistic = __decorate([
11006
11287
  })
11007
11288
  ], OrganizationStatistic);
11008
11289
 
11009
- var WrestballGameLogTypes;
11010
- (function (WrestballGameLogTypes) {
11011
- WrestballGameLogTypes[WrestballGameLogTypes["enter_game"] = 1] = "enter_game";
11012
- WrestballGameLogTypes[WrestballGameLogTypes["exit_game"] = 2] = "exit_game";
11013
- WrestballGameLogTypes[WrestballGameLogTypes["remove_game"] = 3] = "remove_game";
11014
- WrestballGameLogTypes[WrestballGameLogTypes["one_point_made"] = 4] = "one_point_made";
11015
- WrestballGameLogTypes[WrestballGameLogTypes["one_point_attempt"] = 5] = "one_point_attempt";
11016
- WrestballGameLogTypes[WrestballGameLogTypes["two_point_made"] = 6] = "two_point_made";
11017
- WrestballGameLogTypes[WrestballGameLogTypes["two_point_attempt"] = 7] = "two_point_attempt";
11018
- WrestballGameLogTypes[WrestballGameLogTypes["three_point_made"] = 8] = "three_point_made";
11019
- WrestballGameLogTypes[WrestballGameLogTypes["three_point_attempt"] = 9] = "three_point_attempt";
11020
- WrestballGameLogTypes[WrestballGameLogTypes["free_throw_made"] = 10] = "free_throw_made";
11021
- WrestballGameLogTypes[WrestballGameLogTypes["free_throw_attempt"] = 11] = "free_throw_attempt";
11022
- WrestballGameLogTypes[WrestballGameLogTypes["assist"] = 12] = "assist";
11023
- WrestballGameLogTypes[WrestballGameLogTypes["block"] = 13] = "block";
11024
- WrestballGameLogTypes[WrestballGameLogTypes["rebound"] = 14] = "rebound";
11025
- WrestballGameLogTypes[WrestballGameLogTypes["offensive_rebound"] = 15] = "offensive_rebound";
11026
- WrestballGameLogTypes[WrestballGameLogTypes["defensive_rebound"] = 16] = "defensive_rebound";
11027
- WrestballGameLogTypes[WrestballGameLogTypes["team_rebound"] = 17] = "team_rebound";
11028
- WrestballGameLogTypes[WrestballGameLogTypes["steal"] = 18] = "steal";
11029
- WrestballGameLogTypes[WrestballGameLogTypes["turnover"] = 19] = "turnover";
11030
- WrestballGameLogTypes[WrestballGameLogTypes["personal_foul"] = 20] = "personal_foul";
11031
- WrestballGameLogTypes[WrestballGameLogTypes["timeout"] = 21] = "timeout";
11032
- WrestballGameLogTypes[WrestballGameLogTypes["wrestler_scrum"] = 22] = "wrestler_scrum";
11033
- WrestballGameLogTypes[WrestballGameLogTypes["wrestler_scrum_won"] = 23] = "wrestler_scrum_won";
11034
- WrestballGameLogTypes[WrestballGameLogTypes["wrestler_scrum_lost"] = 24] = "wrestler_scrum_lost";
11035
- WrestballGameLogTypes[WrestballGameLogTypes["wrestler_scrum_tie"] = 25] = "wrestler_scrum_tie";
11036
- WrestballGameLogTypes[WrestballGameLogTypes["scrum"] = 26] = "scrum";
11037
- WrestballGameLogTypes[WrestballGameLogTypes["scrum_won"] = 27] = "scrum_won";
11038
- WrestballGameLogTypes[WrestballGameLogTypes["scrum_lost"] = 28] = "scrum_lost";
11039
- WrestballGameLogTypes[WrestballGameLogTypes["scrum_tie"] = 29] = "scrum_tie";
11040
- WrestballGameLogTypes[WrestballGameLogTypes["yellow_card"] = 30] = "yellow_card";
11041
- WrestballGameLogTypes[WrestballGameLogTypes["red_card"] = 31] = "red_card";
11042
- })(WrestballGameLogTypes || (WrestballGameLogTypes = {}));
11043
- let WrestballGameLog = class WrestballGameLog extends BaseModel {
11044
- constructor() {
11045
- super(...arguments);
11046
- this.active = true;
11047
- }
11048
- isPointsType() {
11049
- return [
11050
- WrestballGameLogTypes.two_point_made,
11051
- WrestballGameLogTypes.three_point_made,
11052
- WrestballGameLogTypes.free_throw_made,
11053
- WrestballGameLogTypes.one_point_made,
11054
- WrestballGameLogTypes.scrum_won,
11055
- WrestballGameLogTypes.wrestler_scrum_won,
11056
- ].indexOf(this.logType) > -1;
11057
- }
11058
- isReboundType() {
11059
- return [
11060
- WrestballGameLogTypes.rebound,
11061
- WrestballGameLogTypes.offensive_rebound,
11062
- WrestballGameLogTypes.defensive_rebound,
11063
- WrestballGameLogTypes.team_rebound,
11064
- ].indexOf(this.logType) > -1;
11065
- }
11066
- isFoulType() {
11067
- return [
11068
- WrestballGameLogTypes.personal_foul,
11069
- ].indexOf(this.logType) > -1;
11070
- }
11071
- getScore() {
11072
- const scoreMapping = {
11073
- [WrestballGameLogTypes.one_point_made]: 1,
11074
- [WrestballGameLogTypes.free_throw_made]: 1,
11075
- [WrestballGameLogTypes.two_point_made]: 2,
11076
- [WrestballGameLogTypes.three_point_made]: 3,
11077
- [WrestballGameLogTypes.scrum_won]: 2,
11078
- [WrestballGameLogTypes.wrestler_scrum_won]: 2,
11079
- };
11080
- return scoreMapping[this.logType] || 0;
11081
- }
11082
- compare(model) {
11083
- if (this.time === model.time && this.period === model.period) {
11084
- if (this.datetime.getTime() === model.datetime.getTime()) {
11085
- return this.id > model.id ? 1 : -1;
11086
- }
11087
- return this.datetime.getTime() < model.datetime.getTime() ? 1 : -1;
11088
- }
11089
- if (this.period === model.period) {
11090
- return this.time < model.time ? 1 : -1;
11091
- }
11092
- return this.period < model.period ? 1 : -1;
11093
- }
11094
- get timeFormatted() {
11095
- const minutes = Math.floor(this.time / 60);
11096
- const seconds = this.time - minutes * 60;
11097
- return `${minutes < 10 ? '0' : ''}${minutes}:${seconds < 10 ? '0' : ''}${seconds}`;
11098
- }
11099
- static toFront(value) { }
11100
- static toBack(value) { }
11101
- };
11102
- __decorate([
11103
- ToFrontHook
11104
- ], WrestballGameLog, "toFront", null);
11105
- __decorate([
11106
- ToBackHook
11107
- ], WrestballGameLog, "toBack", null);
11108
- WrestballGameLog = __decorate([
11109
- ModelInstance({
11110
- mappingFields: {
11111
- id: 'id',
11112
- unique_id: 'uniqueId',
11113
- game_id: 'gameId',
11114
- game_user_id: 'gameUserId',
11115
- team_id: 'teamId',
11116
- log_type: 'logType',
11117
- datetime: 'datetime',
11118
- time: 'time',
11119
- period: 'period',
11120
- active: 'active',
11121
- is_highlight: 'isHighlight',
11122
- foul_on_game_user_id: 'foulOnGameUserId',
11123
- is_coach: 'isCoach',
11124
- is_bench: 'isBench',
11125
- marked: 'marked',
11126
- },
11127
- relation: {
11128
- datetime: DateTimeField,
11129
- logType: enumField(WrestballGameLogTypes),
11130
- }
11131
- })
11132
- ], WrestballGameLog);
11133
-
11134
- let WrestballGameStatistic = class WrestballGameStatistic extends BaseModel {
11135
- get id() {
11136
- return this.gameUserId;
11137
- }
11138
- static toFront(data) { }
11139
- static toBack(data) { }
11140
- get totalFouls() {
11141
- return (this.personalFouls || 0) + (this.technicalFouls || 0) + (this.unsportsmanlikeFouls || 0) + (this.disqualificationFouls || 0);
11142
- }
11143
- set onePointPercent(v) { }
11144
- get onePointPercent() {
11145
- if (!this.onePointsMade || !this.onePointAttempts) {
11146
- return 0;
11147
- }
11148
- return Math.round(1000 * this.onePointsMade / this.onePointAttempts) / 10;
11149
- }
11150
- set twoPointPercent(v) { }
11151
- get twoPointPercent() {
11152
- if (!this.twoPointsMade || !this.twoPointAttempts) {
11153
- return 0;
11154
- }
11155
- return Math.round(1000 * this.twoPointsMade / this.twoPointAttempts) / 10;
11156
- }
11157
- set threePointPercent(v) { }
11158
- get threePointPercent() {
11159
- if (!this.threePointsMade || !this.threePointAttempts) {
11160
- return 0;
11161
- }
11162
- return Math.round(1000 * this.threePointsMade / this.threePointAttempts) / 10;
11163
- }
11164
- set freeThrowPercent(v) { }
11165
- get freeThrowPercent() {
11166
- if (!this.freeThrowsMade || !this.freeThrowAttempts) {
11167
- return 0;
11168
- }
11169
- return Math.round(1000 * this.freeThrowsMade / this.freeThrowAttempts) / 10;
11170
- }
11171
- get totalRebounds() {
11172
- return Math.floor(10 * ((this.offensiveRebounds || 0) + (this.defensiveRebounds || 0))) / 10;
11173
- }
11174
- get wrestlerScrums() {
11175
- return (this.wrestlerScrumsWon || 0) + (this.wrestlerScrumsLost || 0) + (this.wrestlerScrumsTie || 0);
11176
- }
11177
- get scrums() {
11178
- return (this.scrumsWon || 0) + (this.scrumsLost || 0) + (this.scrumsTie || 0);
11179
- }
11180
- };
11181
- __decorate([
11182
- ToFrontHook
11183
- ], WrestballGameStatistic, "toFront", null);
11184
- __decorate([
11185
- ToBackHook
11186
- ], WrestballGameStatistic, "toBack", null);
11187
- WrestballGameStatistic = __decorate([
11188
- ModelInstance({
11189
- mappingFields: {
11190
- game_user_id: 'gameUserId',
11191
- points: 'points',
11192
- free_throws_made: 'freeThrowsMade',
11193
- two_points_made: 'twoPointsMade',
11194
- three_points_made: 'threePointsMade',
11195
- one_points_made: 'onePointsMade',
11196
- two_point_attempts: 'twoPointAttempts',
11197
- three_point_attempts: 'threePointAttempts',
11198
- free_throw_attempts: 'freeThrowAttempts',
11199
- one_point_attempts: 'onePointAttempts',
11200
- one_point_percent: 'onePointPercent',
11201
- two_point_percent: 'twoPointPercent',
11202
- three_point_percent: 'threePointPercent',
11203
- free_throw_percent: 'freeThrowPercent',
11204
- assists: 'assists',
11205
- blocks: 'blocks',
11206
- rebounds: 'rebounds',
11207
- offensive_rebounds: 'offensiveRebounds',
11208
- defensive_rebounds: 'defensiveRebounds',
11209
- steals: 'steals',
11210
- turnovers: 'turnovers',
11211
- personal_fouls: 'personalFouls',
11212
- drawn_fouls: 'drawnFouls',
11213
- wrestler_scrums_won: 'wrestlerScrumsWon',
11214
- wrestler_scrums_lost: 'wrestlerScrumsLost',
11215
- wrestler_scrums_tie: 'wrestlerScrumsTie',
11216
- wrestler_scrum_points: 'wrestlerScrumPoints',
11217
- scrums_won: 'scrumsWon',
11218
- scrums_lost: 'scrumsLost',
11219
- scrums_tie: 'scrumsTie',
11220
- scrum_points: 'scrumPoints',
11221
- yellow_cards: 'yellowCards',
11222
- red_cards: 'redCards',
11223
- updated_at: 'updatedAt',
11224
- },
11225
- relation: {
11226
- updatedAt: DateTimeField,
11227
- }
11228
- })
11229
- ], WrestballGameStatistic);
11230
-
11231
- let WrestballGameTeamStatistic = class WrestballGameTeamStatistic extends BaseModel {
11232
- static toFront(data) { }
11233
- static toBack(data) { }
11234
- };
11235
- __decorate([
11236
- ToFrontHook
11237
- ], WrestballGameTeamStatistic, "toFront", null);
11238
- __decorate([
11239
- ToBackHook
11240
- ], WrestballGameTeamStatistic, "toBack", null);
11241
- WrestballGameTeamStatistic = __decorate([
11242
- ModelInstance({
11243
- mappingFields: {
11244
- team: 'team',
11245
- competitor_team: 'competitorTeam'
11246
- },
11247
- relation: {
11248
- team: WrestballStatistic,
11249
- competitorTeam: WrestballStatistic
11250
- }
11251
- })
11252
- ], WrestballGameTeamStatistic);
11253
-
11254
11290
  class CentrifugoService {
11255
11291
  constructor(httpClient, configService, platformId) {
11256
11292
  this.httpClient = httpClient;
@@ -11648,5 +11684,5 @@ HttpCookieInterceptor.ctorParameters = () => [
11648
11684
  * Generated bundle index. Do not edit.
11649
11685
  */
11650
11686
 
11651
- export { Achievement, AchievementTypes, BannerLocation, BaseModel, BaseService, BasketballCourtSides, BasketballCourtZones, BasketballGameApi, BasketballGameConfig, BasketballGameLog, BasketballGameLogTypeLocalization, BasketballGameLogTypes, BasketballGameStatistic, BasketballGameSubLogTypesLocalization, BasketballGameTeamStatistic, BasketballPenaltyTypes, BasketballProfile, BasketballStatistic, BasketballStatisticTypes, BasketballSubLogTypes, CONFIG_DATA, CentrifugoService, City, ConfigService, DateField, DateTimeField, FAULT_LOG_TYPES, Feedback, FeedbackApi, File, FileApi, FileEngine, FootballGameApi, FootballGameConfig, FootballGameLog, FootballGameLogTypeLocalization, FootballGameLogTypes, FootballGameStatistic, FootballGameTeamStatistic, FootballProfile, FootballStatistic, FootballWorkFoot, FootballWorkFootLocalization, Game, GameBaseApi, GameBasketballPosition, GameBasketballPositionLocalization, GameBasketballPositionShortLocalization, GameBill, GameBillStatusLocalization, GameBillStatuses, GameFootballPosition, GameFootballPositionLocalization, GameHandballPosition, GameHandballPositionLocalization, GameHockeyPosition, GameHockeyPositionLocalization, GameInvite, GameInviteStatus, GameResultTypes, GameRugbyPosition, GameRugbyPositionLocalization, GameStatuses, GameTeamAdditionalData, GameTimeTypes, GameTimelineStageItem, GameTimelineStages, GameUser, GameUserDisqualification, GameUserLimitationTypes, GameUserLimitations, GameVolleyballPosition, GameVolleyballPositionLocalization, GameVolleyballPositionShortLocalization, GameVolleyballPositionShortRuLocalization, GameWaterpoloPosition, GameWaterpoloPositionLocalization, GameWaterpoloPositionShortRuLocalization, HandballGameApi, HandballGameConfig, HandballGameLog, HandballGameLogTypeLocalization, HandballGameLogTypes, HandballGameStatistic, HandballGameTeamStatistic, HandballProfile, HandballStatistic, HockeyAdvantageTypes, HockeyGameApi, HockeyGameConfig, HockeyGameLog, HockeyGameLogTypeLocalization, HockeyGameLogTypes, HockeyGameStatistic, HockeyGameTeamStatistic, HockeyPenaltyTypes, HockeyProfile, HockeyStatistic, HockeyWorkHand, HockeyWorkHandLocalization, HttpCookieInterceptor, League, LeagueApi, LeagueBanner, LeagueCourt, LeagueDocument, LeagueFieldBase, LeagueFieldBaseValue, LeagueFieldTypes, LeagueNews, LeagueNewsApi, LeagueNewsType, LeaguePartner, LeaguePlayer, LeaguePlayerApi, LeaguePlayerField, LeaguePlayerFieldValue, LeaguePlaylist, LeagueTeamField, LocalStorageEngine, MODEL_MAPPING_FIELDS_KEY, MODEL_RELATION_KEY, MODEL_TO_BACK_KEY, MODEL_TO_FRONT_KEY, MediaApi, MediaItem, ModelInstance, Notification, NotificationAllowTypes, NotificationApi, NotificationBaseApi, NotificationServiceEnum, NotificationSettings, NotificationType, OrgNotificationApi, Organization, OrganizationBill, OrganizationBillStatusLocalization, OrganizationBillStatuses, OrganizationStatistic, OrganizationStatuses, OrganizationStatusesLocalization, OrganizationTariff, OvertimeTypeLocalization, OvertimeTypes, Playoff, PlayoffSettings, PlayoffTypes, Poll, PollAnswer, PollStatuses, PollVariant, PublicTeamApi, PublicUserApi, Qualification, QualificationLocalization, RUGBY_GAME_LOG_TYPE_POINTS, RUGBY_TEAM_LOG_TYPES, ReferenceApi, RoundTeamGame, RugbyFoulGameStage, RugbyFoulGameStageLocalization, RugbyFoulSanctionLocalization, RugbyFoulSanctions, RugbyFoulType, RugbyGameApi, RugbyGameConfig, RugbyGameLog, RugbyGameLogTypeLocalization, RugbyGameLogTypes, RugbyGameStatistic, RugbyGameTeamStatistic, RugbyProfile, RugbyStatistic, RugbyStatisticTypes, SCORE_LOG_TYPES, Sport, SportTypes, StageTeamGame, StorageEngine, StorageEngineField, Store, Team, TeamAccess, TeamAchievement, TeamAdditionalData, TeamApi, TeamEvent, TeamEventApi, TeamEventInvite, TeamEventInviteStatuses, TeamEventTypeLocalization, TeamEventTypes, TeamInvite, TeamInviteExternal, TeamPermission, TeamPermissionTypes, TeamUser, TeamUserRole, TeamUserRoleLocalization, TeamsAndUsers, TimerTypes, ToBackHook, ToFrontHook, Tournament, TournamentApi, TournamentDisqualification, TournamentDivision, TournamentEvent, TournamentEventTypes, TournamentGender, TournamentGroup, TournamentInvite, TournamentJoin1x1Data, TournamentJoin1x1Status, TournamentJoinApi, TournamentJoinData, TournamentJoinTeam, TournamentNews, TournamentRound, TournamentRoundApi, TournamentRoundSettings, TournamentRoundTeam, TournamentRoundTypes, TournamentSeason, TournamentSeasonApi, TournamentSeasonStatuses, TournamentSettings, TournamentStage, TournamentStageApi, TournamentStageStatuses, TournamentStageTeam, TournamentStatuses, TournamentTeam, TournamentTeamFieldValue, TournamentTeamShort, TournamentTeamUser, TournamentTeamUserInvite, TournamentTeamWinner, TournamentTypes, UntilDestroy, User, UserAccess, UserApi, UserGender, UserPermission, UserPermissionTypes, UserProfile, VolleyballGameApi, VolleyballGameConfig, VolleyballGameLog, VolleyballGameLogType, VolleyballGameLogTypeLocalization, VolleyballGameStatistic, VolleyballGameTeamStatistic, VolleyballGameTypes, VolleyballProfile, VolleyballStatistic, VolleyballStatisticTypes, VolleyballWorkHand, VolleyballWorkHandLocalization, WaterpoloAdvantageTypes, WaterpoloGameApi, WaterpoloGameConfig, WaterpoloGameLog, WaterpoloGameLogTypeLocalization, WaterpoloGameLogTypes, WaterpoloGameStatistic, WaterpoloGameTeamStatistic, WaterpoloProfile, WaterpoloStatistic, WaterpoloStatisticTypes, WaterpoloWorkHand, WaterpoloWorkHandLocalization, WorkHand, WorkHandLocalization, WrestballGameConfig, WrestballGameLog, WrestballGameLogTypes, WrestballGameStatistic, WrestballGameTeamStatistic, WrestballProfile, WrestballStatistic, WrestballStatisticTypes, WrestballWorkHand, addItemInArray, addItemsInArray, applyGameMediaFilters, applyGamesFilters, applyStatisticFilters, applyStatisticLeadersFilters, changeFavicons, componentDestroyed, deleteItemFromArray, enumField, fileSizeValidator, generateArray, getArrayChunks, getCookie, getEnumOptions, getIconsData, handleError, isTouchDevice, listField, markFormGroupTouched, minLengthArrayValidator, parseDate, patchItemInArray, penaltyTypeField, updateItemInArray, updateItemsInArray, validateDate, validateEmail, validatePhone, validateUrl };
11687
+ export { Achievement, AchievementTypes, BannerLocation, BaseModel, BaseService, BasketballCourtSides, BasketballCourtZones, BasketballGameApi, BasketballGameConfig, BasketballGameLog, BasketballGameLogTypeLocalization, BasketballGameLogTypes, BasketballGameStatistic, BasketballGameSubLogTypesLocalization, BasketballGameTeamStatistic, BasketballPenaltyTypes, BasketballProfile, BasketballStatistic, BasketballStatisticTypes, BasketballSubLogTypes, CONFIG_DATA, CentrifugoService, City, ConfigService, DateField, DateTimeField, FAULT_LOG_TYPES, Feedback, FeedbackApi, File, FileApi, FileEngine, FootballGameApi, FootballGameConfig, FootballGameLog, FootballGameLogTypeLocalization, FootballGameLogTypes, FootballGameStatistic, FootballGameTeamStatistic, FootballProfile, FootballStatistic, FootballWorkFoot, FootballWorkFootLocalization, Game, GameBaseApi, GameBasketballPosition, GameBasketballPositionLocalization, GameBasketballPositionShortLocalization, GameBill, GameBillStatusLocalization, GameBillStatuses, GameFootballPosition, GameFootballPositionLocalization, GameHandballPosition, GameHandballPositionLocalization, GameHockeyPosition, GameHockeyPositionLocalization, GameInvite, GameInviteStatus, GameResultTypes, GameRugbyPosition, GameRugbyPositionLocalization, GameStatuses, GameTeamAdditionalData, GameTimeTypes, GameTimelineStageItem, GameTimelineStages, GameUser, GameUserDisqualification, GameUserLimitationTypes, GameUserLimitations, GameVolleyballPosition, GameVolleyballPositionLocalization, GameVolleyballPositionShortLocalization, GameVolleyballPositionShortRuLocalization, GameWaterpoloPosition, GameWaterpoloPositionLocalization, GameWaterpoloPositionShortRuLocalization, HandballGameApi, HandballGameConfig, HandballGameLog, HandballGameLogTypeLocalization, HandballGameLogTypes, HandballGameStatistic, HandballGameTeamStatistic, HandballProfile, HandballStatistic, HockeyAdvantageTypes, HockeyGameApi, HockeyGameConfig, HockeyGameLog, HockeyGameLogTypeLocalization, HockeyGameLogTypes, HockeyGameStatistic, HockeyGameTeamStatistic, HockeyPenaltyTypes, HockeyProfile, HockeyStatistic, HockeyWorkHand, HockeyWorkHandLocalization, HttpCookieInterceptor, League, LeagueApi, LeagueBanner, LeagueCourt, LeagueDocument, LeagueFieldBase, LeagueFieldBaseValue, LeagueFieldTypes, LeagueNews, LeagueNewsApi, LeagueNewsType, LeaguePartner, LeaguePlayer, LeaguePlayerApi, LeaguePlayerField, LeaguePlayerFieldValue, LeaguePlaylist, LeagueTeamField, LocalStorageEngine, MODEL_MAPPING_FIELDS_KEY, MODEL_RELATION_KEY, MODEL_TO_BACK_KEY, MODEL_TO_FRONT_KEY, MediaApi, MediaItem, ModelInstance, Notification, NotificationAllowTypes, NotificationApi, NotificationBaseApi, NotificationServiceEnum, NotificationSettings, NotificationType, OrgNotificationApi, Organization, OrganizationBill, OrganizationBillStatusLocalization, OrganizationBillStatuses, OrganizationStatistic, OrganizationStatuses, OrganizationStatusesLocalization, OrganizationTariff, OvertimeTypeLocalization, OvertimeTypes, Playoff, PlayoffSettings, PlayoffTypes, Poll, PollAnswer, PollStatuses, PollVariant, PublicTeamApi, PublicUserApi, Qualification, QualificationLocalization, RUGBY_GAME_LOG_TYPE_POINTS, RUGBY_TEAM_LOG_TYPES, ReferenceApi, RoundTeamGame, RugbyFoulGameStage, RugbyFoulGameStageLocalization, RugbyFoulSanctionLocalization, RugbyFoulSanctions, RugbyFoulType, RugbyGameApi, RugbyGameConfig, RugbyGameLog, RugbyGameLogTypeLocalization, RugbyGameLogTypes, RugbyGameStatistic, RugbyGameTeamStatistic, RugbyProfile, RugbyStatistic, RugbyStatisticTypes, SCORE_LOG_TYPES, Sport, SportTypes, StageTeamGame, StorageEngine, StorageEngineField, Store, Team, TeamAccess, TeamAchievement, TeamAdditionalData, TeamApi, TeamEvent, TeamEventApi, TeamEventInvite, TeamEventInviteStatuses, TeamEventTypeLocalization, TeamEventTypes, TeamInvite, TeamInviteExternal, TeamPermission, TeamPermissionTypes, TeamUser, TeamUserRole, TeamUserRoleLocalization, TeamsAndUsers, TimerTypes, ToBackHook, ToFrontHook, Tournament, TournamentApi, TournamentDisqualification, TournamentDivision, TournamentEvent, TournamentEventTypes, TournamentGender, TournamentGroup, TournamentInvite, TournamentJoin1x1Data, TournamentJoin1x1Status, TournamentJoinApi, TournamentJoinData, TournamentJoinTeam, TournamentNews, TournamentRound, TournamentRoundApi, TournamentRoundSettings, TournamentRoundTeam, TournamentRoundTypes, TournamentSeason, TournamentSeasonApi, TournamentSeasonStatuses, TournamentSettings, TournamentStage, TournamentStageApi, TournamentStageStatuses, TournamentStageTeam, TournamentStatuses, TournamentTeam, TournamentTeamFieldValue, TournamentTeamShort, TournamentTeamUser, TournamentTeamUserInvite, TournamentTeamWinner, TournamentTypes, UntilDestroy, User, UserAccess, UserApi, UserGender, UserPermission, UserPermissionTypes, UserProfile, VolleyballGameApi, VolleyballGameConfig, VolleyballGameLog, VolleyballGameLogType, VolleyballGameLogTypeLocalization, VolleyballGameStatistic, VolleyballGameTeamStatistic, VolleyballGameTypes, VolleyballProfile, VolleyballStatistic, VolleyballStatisticTypes, VolleyballWorkHand, VolleyballWorkHandLocalization, WaterpoloAdvantageTypes, WaterpoloGameApi, WaterpoloGameConfig, WaterpoloGameLog, WaterpoloGameLogTypeLocalization, WaterpoloGameLogTypes, WaterpoloGameStatistic, WaterpoloGameTeamStatistic, WaterpoloProfile, WaterpoloStatistic, WaterpoloStatisticTypes, WaterpoloWorkHand, WaterpoloWorkHandLocalization, WorkHand, WorkHandLocalization, WrestballGameApi, WrestballGameConfig, WrestballGameLog, WrestballGameLogTypes, WrestballGameStatistic, WrestballGameTeamStatistic, WrestballProfile, WrestballStatistic, WrestballStatisticTypes, WrestballWorkHand, addItemInArray, addItemsInArray, applyGameMediaFilters, applyGamesFilters, applyStatisticFilters, applyStatisticLeadersFilters, changeFavicons, componentDestroyed, deleteItemFromArray, enumField, fileSizeValidator, generateArray, getArrayChunks, getCookie, getEnumOptions, getIconsData, handleError, isTouchDevice, listField, markFormGroupTouched, minLengthArrayValidator, parseDate, patchItemInArray, penaltyTypeField, updateItemInArray, updateItemsInArray, validateDate, validateEmail, validatePhone, validateUrl };
11652
11688
  //# sourceMappingURL=mtgame-core.js.map