volleyballsimtypes 0.0.199 → 0.0.200
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.
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.CompetitionModel = void 0;
|
|
4
4
|
const sequelize_1 = require("sequelize");
|
|
5
|
+
const _1 = require(".");
|
|
5
6
|
const common_1 = require("../common");
|
|
6
7
|
class CompetitionModel extends sequelize_1.Model {
|
|
7
8
|
static initModel(sequelize) {
|
|
@@ -33,6 +34,12 @@ class CompetitionModel extends sequelize_1.Model {
|
|
|
33
34
|
tableName: 'Competition',
|
|
34
35
|
schema: 'public',
|
|
35
36
|
timestamps: false,
|
|
37
|
+
defaultScope: {
|
|
38
|
+
include: [{
|
|
39
|
+
model: _1.IterationModel,
|
|
40
|
+
as: 'Iteration'
|
|
41
|
+
}]
|
|
42
|
+
},
|
|
36
43
|
indexes: [{
|
|
37
44
|
name: 'competition_pk',
|
|
38
45
|
unique: true,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { DataTypes, Model } from 'sequelize';
|
|
2
|
+
import { IterationModel } from '.';
|
|
2
3
|
import { StatusDataType } from '../common';
|
|
3
4
|
export class CompetitionModel extends Model {
|
|
4
5
|
static initModel(sequelize) {
|
|
@@ -30,6 +31,12 @@ export class CompetitionModel extends Model {
|
|
|
30
31
|
tableName: 'Competition',
|
|
31
32
|
schema: 'public',
|
|
32
33
|
timestamps: false,
|
|
34
|
+
defaultScope: {
|
|
35
|
+
include: [{
|
|
36
|
+
model: IterationModel,
|
|
37
|
+
as: 'Iteration'
|
|
38
|
+
}]
|
|
39
|
+
},
|
|
33
40
|
indexes: [{
|
|
34
41
|
name: 'competition_pk',
|
|
35
42
|
unique: true,
|