bantr-api-client 1.6.0 → 11.0.2
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.
- package/api-type/src/models/assists.d.ts +7 -0
- package/api-type/src/models/base_league.d.ts +45 -0
- package/api-type/src/models/block.d.ts +27 -0
- package/api-type/src/models/chat.d.ts +37 -0
- package/api-type/src/models/chat_members.d.ts +36 -0
- package/api-type/src/models/clap.d.ts +38 -0
- package/api-type/src/models/comment.d.ts +46 -0
- package/api-type/src/models/demo_leads.d.ts +64 -0
- package/api-type/src/models/direct_message.d.ts +34 -0
- package/api-type/src/models/dynamic_group.d.ts +42 -0
- package/api-type/src/models/dynamic_season_league_template.d.ts +120 -0
- package/api-type/src/models/dynamic_stage.d.ts +52 -0
- package/api-type/src/models/dynamic_stage_template.d.ts +50 -0
- package/api-type/src/models/emoji.d.ts +31 -0
- package/api-type/src/models/emoji_media_mapper.d.ts +38 -0
- package/api-type/src/models/event.d.ts +133 -0
- package/api-type/src/models/free_agent_payment.d.ts +108 -0
- package/api-type/src/models/game_stat_model.d.ts +55 -0
- package/api-type/src/models/goals.d.ts +7 -0
- package/api-type/src/models/hooks/chat_member.d.ts +4 -0
- package/api-type/src/models/hooks/event.d.ts +6 -0
- package/api-type/src/models/hooks/league_schedule.d.ts +3 -0
- package/api-type/src/models/hooks/pickup_group_member.d.ts +4 -0
- package/api-type/src/models/hooks/schedule_events.d.ts +2 -0
- package/api-type/src/models/hooks/team_roster.d.ts +4 -0
- package/api-type/src/models/invite.d.ts +108 -0
- package/api-type/src/models/job.d.ts +33 -0
- package/api-type/src/models/job_type.d.ts +26 -0
- package/api-type/src/models/last_seen_team_message.d.ts +31 -0
- package/api-type/src/models/league.d.ts +175 -0
- package/api-type/src/models/league_group_teams.d.ts +38 -0
- package/api-type/src/models/league_media.d.ts +57 -0
- package/api-type/src/models/league_payment.d.ts +93 -0
- package/api-type/src/models/league_price.d.ts +52 -0
- package/api-type/src/models/league_registration.d.ts +41 -0
- package/api-type/src/models/league_schedule.d.ts +116 -0
- package/api-type/src/models/league_schedule_referee.d.ts +29 -0
- package/api-type/src/models/league_standing.d.ts +83 -0
- package/api-type/src/models/league_stripe.d.ts +23 -0
- package/api-type/src/models/league_teams.d.ts +34 -0
- package/api-type/src/models/league_template.d.ts +35 -0
- package/api-type/src/models/league_waitlist.d.ts +39 -0
- package/api-type/src/models/market_post.d.ts +91 -0
- package/api-type/src/models/match_cards.d.ts +42 -0
- package/api-type/src/models/match_notes.d.ts +49 -0
- package/api-type/src/models/member.d.ts +138 -0
- package/api-type/src/models/member_hidden_comment.d.ts +31 -0
- package/api-type/src/models/member_hidden_message.d.ts +48 -0
- package/api-type/src/models/member_muted_chat.d.ts +38 -0
- package/api-type/src/models/member_muted_event.d.ts +25 -0
- package/api-type/src/models/member_organizations.d.ts +65 -0
- package/api-type/src/models/member_stripe.d.ts +23 -0
- package/api-type/src/models/message.d.ts +34 -0
- package/api-type/src/models/mvp_votes.d.ts +42 -0
- package/api-type/src/models/notification.d.ts +46 -0
- package/api-type/src/models/oauth.d.ts +49 -0
- package/api-type/src/models/organization.d.ts +68 -0
- package/api-type/src/models/organization_free_agent.d.ts +70 -0
- package/api-type/src/models/organization_free_agent_price.d.ts +37 -0
- package/api-type/src/models/organization_leagues.d.ts +23 -0
- package/api-type/src/models/organization_learn_more.d.ts +75 -0
- package/api-type/src/models/organization_stripe.d.ts +68 -0
- package/api-type/src/models/organization_waivers.d.ts +59 -0
- package/api-type/src/models/organization_workspace.d.ts +76 -0
- package/api-type/src/models/organizer.d.ts +70 -0
- package/api-type/src/models/organizer_roles.d.ts +26 -0
- package/api-type/src/models/pickup.d.ts +163 -0
- package/api-type/src/models/pickup_config.d.ts +34 -0
- package/api-type/src/models/pickup_group.d.ts +83 -0
- package/api-type/src/models/pickup_group_members.d.ts +42 -0
- package/api-type/src/models/pickup_payments.d.ts +79 -0
- package/api-type/src/models/pickup_price.d.ts +41 -0
- package/api-type/src/models/pickup_registration.d.ts +38 -0
- package/api-type/src/models/pickup_roster.d.ts +41 -0
- package/api-type/src/models/pickup_stripe.d.ts +23 -0
- package/api-type/src/models/pickup_waitlist.d.ts +33 -0
- package/api-type/src/models/post.d.ts +66 -0
- package/api-type/src/models/referee_note.d.ts +35 -0
- package/api-type/src/models/referee_organization.d.ts +29 -0
- package/api-type/src/models/referees.d.ts +63 -0
- package/api-type/src/models/refresh_token.d.ts +39 -0
- package/api-type/src/models/refund.d.ts +57 -0
- package/api-type/src/models/report.d.ts +32 -0
- package/api-type/src/models/reported_comment.d.ts +28 -0
- package/api-type/src/models/reported_event.d.ts +28 -0
- package/api-type/src/models/reported_message.d.ts +28 -0
- package/api-type/src/models/reported_player.d.ts +28 -0
- package/api-type/src/models/role.d.ts +44 -0
- package/api-type/src/models/rsvp.d.ts +47 -0
- package/api-type/src/models/schedule_event.d.ts +59 -0
- package/api-type/src/models/season.d.ts +48 -0
- package/api-type/src/models/season_league_template.d.ts +126 -0
- package/api-type/src/models/setting.d.ts +24 -0
- package/api-type/src/models/signed_member_waivers.d.ts +59 -0
- package/api-type/src/models/stripe_balance.d.ts +59 -0
- package/api-type/src/models/stripe_transaction.d.ts +65 -0
- package/api-type/src/models/stripe_transfer.d.ts +59 -0
- package/api-type/src/models/stripe_webhook.d.ts +26 -0
- package/api-type/src/models/support.d.ts +39 -0
- package/api-type/src/models/team.d.ts +97 -0
- package/api-type/src/models/team_league_season_roster.d.ts +42 -0
- package/api-type/src/models/team_members.d.ts +43 -0
- package/api-type/src/models/team_message.d.ts +33 -0
- package/api-type/src/models/team_roster.d.ts +71 -0
- package/api-type/src/models/transaction.d.ts +155 -0
- package/api-type/src/models/transaction_event.d.ts +49 -0
- package/api-type/src/models/utils/chat.d.ts +6 -0
- package/api-type/src/models/utils/league.d.ts +2 -0
- package/api-type/src/models/utils/organization.d.ts +1 -0
- package/api-type/src/models/utils/team.d.ts +2 -0
- package/api-type/src/trpcRouter/discount_code.router.d.ts +12 -12
- package/api-type/src/trpcRouter/free_agent_payments.router.d.ts +3 -3
- package/api-type/src/trpcRouter/league_payments.router.d.ts +21 -21
- package/api-type/src/trpcRouter/oauth.router.d.ts +1 -1
- package/api-type/src/trpcRouter/organization.router.d.ts +2 -2
- package/api-type/src/trpcRouter/pickup_payments.router.d.ts +3 -3
- package/api-type/src/trpcRouter/product.router.d.ts +2 -2
- package/api-type/src/trpcRouter/router.d.ts +148 -148
- package/api-type/src/trpcRouter/team.d.ts +16 -16
- package/api-type/src/trpcRouter/transaction.router.d.ts +14 -14
- package/dist/src/index.d.ts +222 -222
- package/dist/src/provider.d.ts +148 -148
- package/dist/src/query.d.ts +74 -74
- package/package.json +1 -1
- package/tsconfig.json +1 -1
@@ -0,0 +1,175 @@
|
|
1
|
+
import { Model, RelationMappings } from 'objection';
|
2
|
+
import { DayOfWeek, Gender, TLeaguePayments, TMatchDayProgress, LeagueType } from '../types/league';
|
3
|
+
import { LeagueTemplate } from './league_template';
|
4
|
+
import { LeagueSchedule } from './league_schedule';
|
5
|
+
import { Organization } from './organization';
|
6
|
+
import { Organizer } from './organizer';
|
7
|
+
import { Team } from './team';
|
8
|
+
import { Season } from './season';
|
9
|
+
import { OrgWorkspace } from './organization_workspace';
|
10
|
+
import { DynamicStage } from './dynamic_stage';
|
11
|
+
import { DynamicGroup } from './dynamic_group';
|
12
|
+
import { OrgFreeAgent } from './organization_free_agent';
|
13
|
+
export declare const enum LeagueStatus {
|
14
|
+
UNKNOWN = "unknown",
|
15
|
+
FUTURE = "future",
|
16
|
+
CURRENT = "current",
|
17
|
+
PAST = "past"
|
18
|
+
}
|
19
|
+
export declare const enum LeagueStatusUpdated {
|
20
|
+
unknown = "UNKNOWN",
|
21
|
+
future = "UPCOMING",
|
22
|
+
current = "IN PROGRESS",
|
23
|
+
past = "COMPLETED"
|
24
|
+
}
|
25
|
+
declare const League_base: Omit<typeof Model, "new"> & import("objection-js-soft-delete").SoftDeleteStatic<typeof Model>;
|
26
|
+
export declare class League extends League_base {
|
27
|
+
id: number;
|
28
|
+
name: string;
|
29
|
+
teamLimit: number;
|
30
|
+
minGamesPerTeam: number;
|
31
|
+
format: string;
|
32
|
+
gender: Gender;
|
33
|
+
startDate: Date | string;
|
34
|
+
completedAt: Date | null;
|
35
|
+
skillLevel: number;
|
36
|
+
price: number;
|
37
|
+
heroImage: string | null;
|
38
|
+
paymentLink: string | null;
|
39
|
+
description: string | null;
|
40
|
+
dayOfWeek: DayOfWeek | null | string;
|
41
|
+
creatorId: number | null;
|
42
|
+
organizationId: number;
|
43
|
+
baseLeagueId: number | null;
|
44
|
+
seasonId: number | null;
|
45
|
+
isLatest: boolean | null;
|
46
|
+
deposit: number | null;
|
47
|
+
coordinatorId: number | null;
|
48
|
+
orgWorkspaceId: number | null;
|
49
|
+
leagueType: LeagueType | string;
|
50
|
+
updatedAt: Date | string;
|
51
|
+
createdAt: Date | string;
|
52
|
+
deletedAt: Date | null;
|
53
|
+
organization?: Organization | null;
|
54
|
+
orgWorkspace?: OrgWorkspace | null;
|
55
|
+
orgFreeAgent?: OrgFreeAgent | null;
|
56
|
+
scheduleTemplate?: LeagueTemplate | null;
|
57
|
+
status?: LeagueStatus | LeagueStatusUpdated;
|
58
|
+
isEndOfSeason?: boolean;
|
59
|
+
isFull?: boolean;
|
60
|
+
isHalfFull?: boolean;
|
61
|
+
isPaymentRequired?: boolean;
|
62
|
+
allGamesPlayed?: boolean;
|
63
|
+
creator?: Organizer | null;
|
64
|
+
daysToKickoff?: number;
|
65
|
+
teamCount?: number;
|
66
|
+
minNumMatchdays?: number;
|
67
|
+
memberTeamsRegistered?: Team[] | null;
|
68
|
+
formattedStartDate?: string;
|
69
|
+
matchDays?: LeagueSchedule[];
|
70
|
+
currentMatchDay?: number;
|
71
|
+
season?: Season;
|
72
|
+
locations?: string[] | null;
|
73
|
+
startTimes?: string[] | null;
|
74
|
+
coordinator?: Organizer;
|
75
|
+
leaguePayments?: TLeaguePayments;
|
76
|
+
matchDayProgress?: TMatchDayProgress[];
|
77
|
+
reigningChampion?: Team;
|
78
|
+
leagueSchedules?: LeagueSchedule[];
|
79
|
+
teams?: Team[];
|
80
|
+
currentMatchDayQuery?: any;
|
81
|
+
stages?: DynamicStage[] | null;
|
82
|
+
groups?: DynamicGroup[];
|
83
|
+
stripeVersion: number;
|
84
|
+
static tableName: string;
|
85
|
+
static get idColumn(): string;
|
86
|
+
static get relationMappings(): RelationMappings;
|
87
|
+
static jsonSchema: {
|
88
|
+
type: string;
|
89
|
+
required: string[];
|
90
|
+
properties: {
|
91
|
+
id: {
|
92
|
+
type: string;
|
93
|
+
};
|
94
|
+
name: {
|
95
|
+
type: string;
|
96
|
+
minLength: number;
|
97
|
+
maxLength: number;
|
98
|
+
};
|
99
|
+
teamLimit: {
|
100
|
+
type: string;
|
101
|
+
};
|
102
|
+
minGamesPerTeam: {
|
103
|
+
type: string;
|
104
|
+
};
|
105
|
+
format: {
|
106
|
+
type: string;
|
107
|
+
minLength: number;
|
108
|
+
maxLength: number;
|
109
|
+
};
|
110
|
+
gender: {
|
111
|
+
type: string;
|
112
|
+
enum: Gender[];
|
113
|
+
minLength: number;
|
114
|
+
maxLength: number;
|
115
|
+
};
|
116
|
+
startDate: {
|
117
|
+
type: string;
|
118
|
+
};
|
119
|
+
completedAt: {
|
120
|
+
type: string;
|
121
|
+
};
|
122
|
+
skillLevel: {
|
123
|
+
type: string;
|
124
|
+
};
|
125
|
+
price: {
|
126
|
+
type: string;
|
127
|
+
};
|
128
|
+
heroImage: {
|
129
|
+
type: string[];
|
130
|
+
};
|
131
|
+
paymentLink: {
|
132
|
+
type: string[];
|
133
|
+
};
|
134
|
+
description: {
|
135
|
+
type: string[];
|
136
|
+
minLength: number;
|
137
|
+
maxLength: number;
|
138
|
+
};
|
139
|
+
dayOfWeek: {
|
140
|
+
type: string;
|
141
|
+
enum: DayOfWeek[];
|
142
|
+
minLength: number;
|
143
|
+
maxLength: number;
|
144
|
+
};
|
145
|
+
organizationId: {
|
146
|
+
type: string;
|
147
|
+
};
|
148
|
+
orgWorkspaceId: {
|
149
|
+
type: string[];
|
150
|
+
};
|
151
|
+
baseLeagueId: {
|
152
|
+
type: string[];
|
153
|
+
};
|
154
|
+
seasonId: {
|
155
|
+
type: string[];
|
156
|
+
};
|
157
|
+
isLatest: {
|
158
|
+
type: string[];
|
159
|
+
};
|
160
|
+
leagueType: {
|
161
|
+
type: string;
|
162
|
+
enum: LeagueType[];
|
163
|
+
default: LeagueType;
|
164
|
+
};
|
165
|
+
stripeVersion: {
|
166
|
+
type: string;
|
167
|
+
default: number;
|
168
|
+
};
|
169
|
+
};
|
170
|
+
};
|
171
|
+
isOrganizer(organizerId: number): Promise<boolean>;
|
172
|
+
checkVacancyForDynamicLeague(groupId?: number): Promise<boolean>;
|
173
|
+
hasVacancy(groupId?: number): Promise<boolean>;
|
174
|
+
}
|
175
|
+
export {};
|
@@ -0,0 +1,38 @@
|
|
1
|
+
import { Model, RelationMappings } from 'objection';
|
2
|
+
declare const LeagueGroupTeam_base: Omit<typeof Model, "new"> & import("objection-js-soft-delete").SoftDeleteStatic<typeof Model>;
|
3
|
+
export declare class LeagueGroupTeam extends LeagueGroupTeam_base {
|
4
|
+
id: number;
|
5
|
+
leagueId: number;
|
6
|
+
teamId: number;
|
7
|
+
dynamicGroupId: number;
|
8
|
+
updatedAt: Date | string;
|
9
|
+
createdAt: Date | string;
|
10
|
+
deletedAt: Date | null;
|
11
|
+
teamName?: string;
|
12
|
+
position?: number;
|
13
|
+
gamesPlayed?: number;
|
14
|
+
gamesScheduled?: number;
|
15
|
+
static tableName: string;
|
16
|
+
static get idColumn(): string;
|
17
|
+
static get modifiers(): Record<string, (builder: any) => void>;
|
18
|
+
static get relationMappings(): RelationMappings;
|
19
|
+
static jsonSchema: {
|
20
|
+
type: string;
|
21
|
+
required: string[];
|
22
|
+
properties: {
|
23
|
+
id: {
|
24
|
+
type: string;
|
25
|
+
};
|
26
|
+
leagueId: {
|
27
|
+
type: string;
|
28
|
+
};
|
29
|
+
teamId: {
|
30
|
+
type: string;
|
31
|
+
};
|
32
|
+
dynamicGroupId: {
|
33
|
+
type: string;
|
34
|
+
};
|
35
|
+
};
|
36
|
+
};
|
37
|
+
}
|
38
|
+
export {};
|
@@ -0,0 +1,57 @@
|
|
1
|
+
import { Model, RelationMappings } from 'objection';
|
2
|
+
import { TEmojiInteractions } from '../types/league_media';
|
3
|
+
export declare const enum MEDIA_TYPE {
|
4
|
+
image = "image",
|
5
|
+
video = "video",
|
6
|
+
gif = "gif"
|
7
|
+
}
|
8
|
+
export declare const enum USER_TYPE {
|
9
|
+
member = "member",
|
10
|
+
organizer = "organizer"
|
11
|
+
}
|
12
|
+
export declare class LeagueMedia extends Model {
|
13
|
+
id: number;
|
14
|
+
leagueId: number;
|
15
|
+
url: string;
|
16
|
+
type: MEDIA_TYPE;
|
17
|
+
isHighlighted: boolean;
|
18
|
+
isFlagged: boolean;
|
19
|
+
creatorId: number | null;
|
20
|
+
creatorType: USER_TYPE | null;
|
21
|
+
updatedAt: Date;
|
22
|
+
createdAt: Date;
|
23
|
+
interactions?: TEmojiInteractions[];
|
24
|
+
totalInteractions?: number;
|
25
|
+
feedType?: string;
|
26
|
+
static tableName: string;
|
27
|
+
static get relationMappings(): RelationMappings;
|
28
|
+
static get idColumn(): string;
|
29
|
+
static jsonSchema: {
|
30
|
+
type: string;
|
31
|
+
required: string[];
|
32
|
+
properties: {
|
33
|
+
id: {
|
34
|
+
type: string;
|
35
|
+
};
|
36
|
+
leagueId: {
|
37
|
+
type: string;
|
38
|
+
};
|
39
|
+
isHighlighted: {
|
40
|
+
type: string;
|
41
|
+
default: boolean;
|
42
|
+
};
|
43
|
+
isFlagged: {
|
44
|
+
type: string;
|
45
|
+
default: boolean;
|
46
|
+
};
|
47
|
+
creatorId: {
|
48
|
+
type: string[];
|
49
|
+
};
|
50
|
+
creatorType: {
|
51
|
+
type: string[];
|
52
|
+
};
|
53
|
+
};
|
54
|
+
};
|
55
|
+
IsTeamMemberOfLeague(memberId: number): Promise<boolean>;
|
56
|
+
}
|
57
|
+
export default LeagueMedia;
|
@@ -0,0 +1,93 @@
|
|
1
|
+
import { Model, RelationMappings } from 'objection';
|
2
|
+
import { LeaguePaymentSchema } from '../modules/league_payments/league_payments.schema';
|
3
|
+
import { League } from './league';
|
4
|
+
import { LeaguePrice } from './league_price';
|
5
|
+
import { LeagueRegistration } from './league_registration';
|
6
|
+
import { Member } from './member';
|
7
|
+
import { Team } from './team';
|
8
|
+
import { Refund } from './refund';
|
9
|
+
import { DiscountCode } from '../modules/discount_code/discount_code.model';
|
10
|
+
import { Transaction } from './transaction';
|
11
|
+
export declare class LeaguePayment extends Model {
|
12
|
+
id: number;
|
13
|
+
leagueId: number;
|
14
|
+
teamId: number;
|
15
|
+
leaguePriceId: number;
|
16
|
+
leagueRegistrationId: number | null;
|
17
|
+
payerId: number;
|
18
|
+
stripeCheckoutSessionId: string | null;
|
19
|
+
stripeIdempotencyKey: string | null;
|
20
|
+
stripePaymentIntentId: string | null;
|
21
|
+
status: LeaguePaymentSchema['status'];
|
22
|
+
orgFreeAgentId: number | null;
|
23
|
+
amountApplied: number | null;
|
24
|
+
originalLeagueId: number | null;
|
25
|
+
offlineMethod: LeaguePaymentSchema['offlineMethod'] | null;
|
26
|
+
updatedAt: Date | string;
|
27
|
+
createdAt: Date | string;
|
28
|
+
deletedAt: Date | null;
|
29
|
+
league?: League;
|
30
|
+
leaguePrice?: LeaguePrice;
|
31
|
+
leagueRegistration?: LeagueRegistration;
|
32
|
+
team?: Team;
|
33
|
+
payer?: Member;
|
34
|
+
isRegistrationPayment?: boolean;
|
35
|
+
refunds?: Refund[];
|
36
|
+
originalLeague?: League;
|
37
|
+
discountCodeId: number | null;
|
38
|
+
discountCode?: DiscountCode;
|
39
|
+
appliedDiscountValue: number;
|
40
|
+
transactions?: Transaction[];
|
41
|
+
static tableName: string;
|
42
|
+
static get relationMappings(): RelationMappings;
|
43
|
+
static jsonSchema: {
|
44
|
+
type: string;
|
45
|
+
required: string[];
|
46
|
+
properties: {
|
47
|
+
id: {
|
48
|
+
type: string;
|
49
|
+
};
|
50
|
+
leagueId: {
|
51
|
+
type: string;
|
52
|
+
};
|
53
|
+
leaguePriceId: {
|
54
|
+
type: string;
|
55
|
+
};
|
56
|
+
leagueRegistrationId: {
|
57
|
+
type: string[];
|
58
|
+
};
|
59
|
+
payerId: {
|
60
|
+
type: string;
|
61
|
+
};
|
62
|
+
stripeCheckoutSessionId: {
|
63
|
+
type: string[];
|
64
|
+
};
|
65
|
+
stripeIdempotencyKey: {
|
66
|
+
type: string[];
|
67
|
+
};
|
68
|
+
stripePaymentIntentId: {
|
69
|
+
type: string[];
|
70
|
+
};
|
71
|
+
offlineMethod: {
|
72
|
+
type: string[];
|
73
|
+
enum: ["STRIPE", "CASH", "CHECK", "VENMO", "ZELLE", "ONLINE", "BANK", "Other"];
|
74
|
+
};
|
75
|
+
status: {
|
76
|
+
type: string;
|
77
|
+
enum: [import("../types/common").StripePaymentStatus.CREATED, import("../types/common").StripePaymentStatus.PENDING, import("../types/common").StripePaymentStatus.PAID, import("../types/common").StripePaymentStatus.FAILED, import("../types/common").StripePaymentStatus.REFUNDED, import("../types/common").StripePaymentStatus.REFUND_INITIATED, import("../types/common").StripePaymentStatus.PARTIALLY_REFUNDED];
|
78
|
+
};
|
79
|
+
teamId: {
|
80
|
+
type: string;
|
81
|
+
};
|
82
|
+
originalLeagueId: {
|
83
|
+
type: string[];
|
84
|
+
};
|
85
|
+
discountCodeId: {
|
86
|
+
type: string[];
|
87
|
+
};
|
88
|
+
appliedDiscountValue: {
|
89
|
+
type: string;
|
90
|
+
};
|
91
|
+
};
|
92
|
+
};
|
93
|
+
}
|
@@ -0,0 +1,52 @@
|
|
1
|
+
import { Model, QueryBuilder } from 'objection';
|
2
|
+
import { VALID_CURRENCY_CODES } from '../constants';
|
3
|
+
export declare const enum LeaguePriceType {
|
4
|
+
TOTAL_PRICE = "total_price",
|
5
|
+
DEPOSIT_PRICE = "deposit_price",
|
6
|
+
BALANCE_PRICE = "balance_price",
|
7
|
+
CUSTOM_PRICE = "custom_price",
|
8
|
+
OFF_PLATFORM = "off_platform"
|
9
|
+
}
|
10
|
+
declare const LeaguePrice_base: Omit<typeof Model, "new"> & import("objection-js-soft-delete").SoftDeleteStatic<typeof Model>;
|
11
|
+
export declare class LeaguePrice extends LeaguePrice_base {
|
12
|
+
id: number;
|
13
|
+
price: number;
|
14
|
+
type: LeaguePriceType;
|
15
|
+
leagueId: number;
|
16
|
+
stripePriceId: string | null;
|
17
|
+
currency: VALID_CURRENCY_CODES;
|
18
|
+
updatedAt: Date | string;
|
19
|
+
createdAt: Date | string;
|
20
|
+
deletedAt: Date | string | null;
|
21
|
+
static tableName: string;
|
22
|
+
static get idColumn(): string;
|
23
|
+
static modifiers: {
|
24
|
+
filterStripe(query: QueryBuilder<LeaguePrice>): void;
|
25
|
+
};
|
26
|
+
static jsonSchema: {
|
27
|
+
type: string;
|
28
|
+
required: never[];
|
29
|
+
properties: {
|
30
|
+
id: {
|
31
|
+
type: string;
|
32
|
+
};
|
33
|
+
price: {
|
34
|
+
type: string;
|
35
|
+
};
|
36
|
+
type: {
|
37
|
+
type: string;
|
38
|
+
};
|
39
|
+
leagueId: {
|
40
|
+
type: string;
|
41
|
+
};
|
42
|
+
stripePriceId: {
|
43
|
+
type: string[];
|
44
|
+
};
|
45
|
+
currency: {
|
46
|
+
type: string;
|
47
|
+
enum: VALID_CURRENCY_CODES[];
|
48
|
+
};
|
49
|
+
};
|
50
|
+
};
|
51
|
+
}
|
52
|
+
export {};
|
@@ -0,0 +1,41 @@
|
|
1
|
+
import { Model } from 'objection';
|
2
|
+
export declare const enum LeagueRegistrationStatus {
|
3
|
+
PAYMENT_PENDING = "payment_pending",
|
4
|
+
PAID_IN_FULL = "paid_in_full"
|
5
|
+
}
|
6
|
+
declare const LeagueRegistration_base: Omit<typeof Model, "new"> & import("objection-js-soft-delete").SoftDeleteStatic<typeof Model>;
|
7
|
+
export declare class LeagueRegistration extends LeagueRegistration_base {
|
8
|
+
id: number;
|
9
|
+
teamId: number;
|
10
|
+
leagueId: number;
|
11
|
+
originalLeagueId: number | null;
|
12
|
+
status: LeagueRegistrationStatus | null;
|
13
|
+
registrantId: number | null;
|
14
|
+
updatedAt: Date | string;
|
15
|
+
createdAt: Date | string;
|
16
|
+
deletedAt: Date | null;
|
17
|
+
static tableName: string;
|
18
|
+
static get idColumn(): string;
|
19
|
+
static jsonSchema: {
|
20
|
+
type: string;
|
21
|
+
required: string[];
|
22
|
+
properties: {
|
23
|
+
registrantId: {
|
24
|
+
type: string[];
|
25
|
+
};
|
26
|
+
teamId: {
|
27
|
+
type: string;
|
28
|
+
};
|
29
|
+
leagueId: {
|
30
|
+
type: string;
|
31
|
+
};
|
32
|
+
status: {
|
33
|
+
type: string[];
|
34
|
+
};
|
35
|
+
originalLeagueId: {
|
36
|
+
type: string[];
|
37
|
+
};
|
38
|
+
};
|
39
|
+
};
|
40
|
+
}
|
41
|
+
export {};
|
@@ -0,0 +1,116 @@
|
|
1
|
+
import { Model, RelationMappings } from 'objection';
|
2
|
+
import { GameStatTypes } from '../types/game_stats';
|
3
|
+
import { League } from './league';
|
4
|
+
import { ScheduleEvent } from './schedule_event';
|
5
|
+
import { Team } from './team';
|
6
|
+
import { DynamicGroup } from './dynamic_group';
|
7
|
+
import { DynamicStage } from './dynamic_stage';
|
8
|
+
import { MatchNotes } from './match_notes';
|
9
|
+
import { Referee } from './referees';
|
10
|
+
import { Organizer } from './organizer';
|
11
|
+
export declare const enum Status {
|
12
|
+
preview = "preview",
|
13
|
+
saved = "saved",
|
14
|
+
saved_incomplete = "saved_incomplete",
|
15
|
+
saved_complete = "saved_complete",
|
16
|
+
published = "published",
|
17
|
+
conflict = "conflict",
|
18
|
+
canceled = "canceled"
|
19
|
+
}
|
20
|
+
export declare const TimeDelimiter = ":";
|
21
|
+
export declare class LeagueSchedule extends Model {
|
22
|
+
id: number;
|
23
|
+
templateId?: number;
|
24
|
+
leagueId: number;
|
25
|
+
team1Id: number | null;
|
26
|
+
team2Id: number | null;
|
27
|
+
date?: string | null;
|
28
|
+
location?: string | null;
|
29
|
+
time?: string | null;
|
30
|
+
status: Status;
|
31
|
+
matchDay: number;
|
32
|
+
label?: string | null;
|
33
|
+
gameLabel?: string | null;
|
34
|
+
gameScoresId?: number | null;
|
35
|
+
localizedDatetime: Date | null;
|
36
|
+
dynamicGroupId: number | null;
|
37
|
+
dynamicStageId: number | null;
|
38
|
+
ignoreFromStandings: boolean;
|
39
|
+
cancellationMessage?: null | string;
|
40
|
+
updatedAt: Date | string;
|
41
|
+
createdAt: Date | string;
|
42
|
+
league?: League;
|
43
|
+
gameScores?: ScheduleEvent | null;
|
44
|
+
team1?: Team;
|
45
|
+
team2?: Team;
|
46
|
+
statsStep?: GameStatTypes;
|
47
|
+
feedType?: string;
|
48
|
+
totalGames?: number;
|
49
|
+
confirmedGames?: number;
|
50
|
+
confirmedByOrganizer?: boolean;
|
51
|
+
group?: DynamicGroup;
|
52
|
+
stage?: DynamicStage;
|
53
|
+
stageId?: number;
|
54
|
+
matchNotes?: MatchNotes[];
|
55
|
+
noteLabels?: string[];
|
56
|
+
referees?: Referee[];
|
57
|
+
organizersAsReferee?: Organizer[];
|
58
|
+
static tableName: string;
|
59
|
+
static get idColumn(): string;
|
60
|
+
static get modifiers(): Record<string, (builder: any) => void>;
|
61
|
+
static get relationMappings(): RelationMappings;
|
62
|
+
static jsonSchema: {
|
63
|
+
type: string;
|
64
|
+
required: string[];
|
65
|
+
properties: {
|
66
|
+
id: {
|
67
|
+
type: string;
|
68
|
+
};
|
69
|
+
templateId: {
|
70
|
+
type: string;
|
71
|
+
};
|
72
|
+
leagueId: {
|
73
|
+
type: string;
|
74
|
+
};
|
75
|
+
team1Id: {
|
76
|
+
type: string[];
|
77
|
+
};
|
78
|
+
team2Id: {
|
79
|
+
type: string[];
|
80
|
+
};
|
81
|
+
date: {
|
82
|
+
type: string[];
|
83
|
+
};
|
84
|
+
location: {
|
85
|
+
type: string[];
|
86
|
+
maxLength: number;
|
87
|
+
};
|
88
|
+
time: {
|
89
|
+
type: string[];
|
90
|
+
maxLength: number;
|
91
|
+
};
|
92
|
+
status: {
|
93
|
+
type: string;
|
94
|
+
enum: Status[];
|
95
|
+
minLength: number;
|
96
|
+
maxLength: number;
|
97
|
+
};
|
98
|
+
matchDay: {
|
99
|
+
type: string;
|
100
|
+
};
|
101
|
+
gameScoresId: {
|
102
|
+
type: string;
|
103
|
+
};
|
104
|
+
localizedDatetime: {
|
105
|
+
type: string;
|
106
|
+
};
|
107
|
+
dynamicGroupId: {
|
108
|
+
type: string[];
|
109
|
+
};
|
110
|
+
ignoreFromStandings: {
|
111
|
+
type: string;
|
112
|
+
default: boolean;
|
113
|
+
};
|
114
|
+
};
|
115
|
+
};
|
116
|
+
}
|
@@ -0,0 +1,29 @@
|
|
1
|
+
import { Model } from 'objection';
|
2
|
+
export declare class LeagueScheduleReferee extends Model {
|
3
|
+
id: number;
|
4
|
+
leagueScheduleId: number;
|
5
|
+
organizerId: number | null;
|
6
|
+
refereeId: number | null;
|
7
|
+
static tableName: string;
|
8
|
+
static jsonSchema: {
|
9
|
+
type: string;
|
10
|
+
required: string[];
|
11
|
+
properties: {
|
12
|
+
id: {
|
13
|
+
type: string;
|
14
|
+
};
|
15
|
+
leagueScheduleId: {
|
16
|
+
type: string;
|
17
|
+
};
|
18
|
+
organizerId: {
|
19
|
+
type: string[];
|
20
|
+
default: null;
|
21
|
+
};
|
22
|
+
refereeId: {
|
23
|
+
type: string[];
|
24
|
+
default: null;
|
25
|
+
};
|
26
|
+
};
|
27
|
+
};
|
28
|
+
}
|
29
|
+
export default LeagueScheduleReferee;
|
@@ -0,0 +1,83 @@
|
|
1
|
+
import { Model, RelationMappings, TransactionOrKnex } from 'objection';
|
2
|
+
import { League } from './league';
|
3
|
+
import { OrgWorkspace } from '@bantr/api/models/organization_workspace';
|
4
|
+
import { Team } from './team';
|
5
|
+
declare const LeagueStanding_base: Omit<typeof Model, "new"> & import("objection-js-soft-delete").SoftDeleteStatic<typeof Model>;
|
6
|
+
export declare class LeagueStanding extends LeagueStanding_base {
|
7
|
+
id: number;
|
8
|
+
leagueId: number;
|
9
|
+
teamId: number;
|
10
|
+
position: number | null;
|
11
|
+
finalPosition: number | null;
|
12
|
+
points: number;
|
13
|
+
wins: number;
|
14
|
+
losses: number;
|
15
|
+
draws: number;
|
16
|
+
goalsFor: number;
|
17
|
+
goalsAgainst: number;
|
18
|
+
gamesPlayed: number;
|
19
|
+
goalsDiff: number;
|
20
|
+
dynamicGroupId: number | null;
|
21
|
+
isPublished: boolean;
|
22
|
+
updatedAt: Date | string;
|
23
|
+
createdAt: Date | string;
|
24
|
+
deletedAt: Date | null;
|
25
|
+
team?: Team;
|
26
|
+
league?: League;
|
27
|
+
feedType?: string;
|
28
|
+
orgWorkspace?: OrgWorkspace;
|
29
|
+
constructor(opts?: {
|
30
|
+
leagueId?: number;
|
31
|
+
teamId?: number;
|
32
|
+
dynamicGroupId?: number | null;
|
33
|
+
isPublished?: boolean;
|
34
|
+
});
|
35
|
+
static tableName: string;
|
36
|
+
static get relationMappings(): RelationMappings;
|
37
|
+
static get idColumn(): string;
|
38
|
+
static jsonSchema: {
|
39
|
+
type: string;
|
40
|
+
required: string[];
|
41
|
+
properties: {
|
42
|
+
id: {
|
43
|
+
type: string;
|
44
|
+
};
|
45
|
+
leagueId: {
|
46
|
+
type: string;
|
47
|
+
};
|
48
|
+
teamId: {
|
49
|
+
type: string;
|
50
|
+
};
|
51
|
+
position: {
|
52
|
+
type: string[];
|
53
|
+
};
|
54
|
+
finalPosition: {
|
55
|
+
type: string[];
|
56
|
+
};
|
57
|
+
points: {
|
58
|
+
type: string;
|
59
|
+
};
|
60
|
+
wins: {
|
61
|
+
type: string;
|
62
|
+
};
|
63
|
+
losses: {
|
64
|
+
type: string;
|
65
|
+
};
|
66
|
+
draws: {
|
67
|
+
type: string;
|
68
|
+
};
|
69
|
+
goalsFor: {
|
70
|
+
type: string;
|
71
|
+
};
|
72
|
+
goalsAgainst: {
|
73
|
+
type: string;
|
74
|
+
};
|
75
|
+
dynamicGroupId: {
|
76
|
+
type: string[];
|
77
|
+
};
|
78
|
+
};
|
79
|
+
};
|
80
|
+
static recalculateLeagueStandings(leagueId: number, trx?: TransactionOrKnex): Promise<void>;
|
81
|
+
private static _addScores;
|
82
|
+
}
|
83
|
+
export {};
|