volleyballsimtypes 0.0.89 → 0.0.90

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.
@@ -1,3 +1,4 @@
1
1
  import { SeasonMatchAttributes } from '../models';
2
- declare function transformToAttributes(seasonId: string, matchId: string): SeasonMatchAttributes;
2
+ import { Match } from '../../service';
3
+ declare function transformToAttributes(seasonId: string, match: Match): SeasonMatchAttributes;
3
4
  export { transformToAttributes as transformFromSeasonMatch };
@@ -1,10 +1,12 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.transformFromSeasonMatch = void 0;
4
- function transformToAttributes(seasonId, matchId) {
4
+ const match_1 = require("./match");
5
+ function transformToAttributes(seasonId, match) {
5
6
  return {
6
7
  season_id: seasonId,
7
- match_id: matchId
8
+ match_id: match.id,
9
+ match: (0, match_1.transformFromMatch)(match)
8
10
  };
9
11
  }
10
12
  exports.transformFromSeasonMatch = transformToAttributes;
@@ -5,7 +5,7 @@ const _1 = require(".");
5
5
  const service_1 = require("../../service");
6
6
  function transformToAttributes(season, leagueId) {
7
7
  const seasonMatches = season.matches != null ?
8
- season.matches.map(match => (0, _1.transformFromSeasonMatch)(season.id, match.id)) : [];
8
+ season.matches.map(match => (0, _1.transformFromSeasonMatch)(season.id, match)) : [];
9
9
  const seasonTeams = season.teams.map(team => ({ season_id: season.id, team_id: team.id }));
10
10
  return {
11
11
  season_id: season.id,
@@ -9,7 +9,7 @@ function transformToAttributes(tournamentMatch, tournamentId) {
9
9
  match_id: tournamentMatch.match.id,
10
10
  index: tournamentMatch.index,
11
11
  stage: (0, _1.transformFromStage)(tournamentMatch.stage),
12
- match: tournamentMatch.match != null ? (0, _1.transformFromMatch)(tournamentMatch.match) : undefined
12
+ match: (0, _1.transformFromMatch)(tournamentMatch.match)
13
13
  };
14
14
  }
15
15
  exports.transformFromTournamentMatch = transformToAttributes;
@@ -1,3 +1,4 @@
1
1
  import { SeasonMatchAttributes } from '../models';
2
- declare function transformToAttributes(seasonId: string, matchId: string): SeasonMatchAttributes;
2
+ import { Match } from '../../service';
3
+ declare function transformToAttributes(seasonId: string, match: Match): SeasonMatchAttributes;
3
4
  export { transformToAttributes as transformFromSeasonMatch };
@@ -1,7 +1,9 @@
1
- function transformToAttributes(seasonId, matchId) {
1
+ import { transformFromMatch } from './match';
2
+ function transformToAttributes(seasonId, match) {
2
3
  return {
3
4
  season_id: seasonId,
4
- match_id: matchId
5
+ match_id: match.id,
6
+ match: transformFromMatch(match)
5
7
  };
6
8
  }
7
9
  export { transformToAttributes as transformFromSeasonMatch };
@@ -2,7 +2,7 @@ import { transformFromSeasonMatch, transformFromTeam, transformToAPIMatch, trans
2
2
  import { Season } from '../../service';
3
3
  function transformToAttributes(season, leagueId) {
4
4
  const seasonMatches = season.matches != null ?
5
- season.matches.map(match => transformFromSeasonMatch(season.id, match.id)) : [];
5
+ season.matches.map(match => transformFromSeasonMatch(season.id, match)) : [];
6
6
  const seasonTeams = season.teams.map(team => ({ season_id: season.id, team_id: team.id }));
7
7
  return {
8
8
  season_id: season.id,
@@ -6,7 +6,7 @@ function transformToAttributes(tournamentMatch, tournamentId) {
6
6
  match_id: tournamentMatch.match.id,
7
7
  index: tournamentMatch.index,
8
8
  stage: transformFromStage(tournamentMatch.stage),
9
- match: tournamentMatch.match != null ? transformFromMatch(tournamentMatch.match) : undefined
9
+ match: transformFromMatch(tournamentMatch.match)
10
10
  };
11
11
  }
12
12
  function transformToObject(model) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "volleyballsimtypes",
3
- "version": "0.0.89",
3
+ "version": "0.0.90",
4
4
  "description": "vbsim types",
5
5
  "main": "./dist/cjs/src/index.js",
6
6
  "module": "./dist/esm/src/index.js",