mirror of
https://github.com/Sendouc/sendou.ink.git
synced 2026-04-25 07:32:19 -05:00
Give patrons access to tournaments beta
This commit is contained in:
parent
2b984f0169
commit
efd1d75318
|
|
@ -96,8 +96,8 @@ export default function CalendarNewEventPage() {
|
|||
return (
|
||||
<Main className="stack items-center">
|
||||
<Alert variation="WARNING">
|
||||
No permissions to add tournaments. Access to tournaments beta can be
|
||||
applied from Discord helpdesk for established TO's.
|
||||
No permissions to add tournaments. Tournaments are in beta, accessible
|
||||
by Patreon supporters and established TO's.
|
||||
</Alert>
|
||||
</Main>
|
||||
);
|
||||
|
|
|
|||
|
|
@ -93,6 +93,11 @@ const PERKS = [
|
|||
name: "joinFive",
|
||||
extraInfo: false,
|
||||
},
|
||||
{
|
||||
tier: 2,
|
||||
name: "tournamentsBeta",
|
||||
extraInfo: false,
|
||||
},
|
||||
] as const;
|
||||
|
||||
export default function SupportPage() {
|
||||
|
|
|
|||
|
|
@ -263,6 +263,12 @@ export function findBannedStatusByUserId(userId: number) {
|
|||
.executeTakeFirst();
|
||||
}
|
||||
|
||||
const userIsTournamentOrganizer = sql<
|
||||
string | null
|
||||
>`IIF(COALESCE("User"."patronTier", 0) >= 2, 1, "User"."isTournamentOrganizer")`.as(
|
||||
"isTournamentOrganizer",
|
||||
);
|
||||
|
||||
export function findLeanById(id: number) {
|
||||
return db
|
||||
.selectFrom("User")
|
||||
|
|
@ -272,7 +278,7 @@ export function findLeanById(id: number) {
|
|||
...COMMON_USER_FIELDS,
|
||||
"User.isArtist",
|
||||
"User.isVideoAdder",
|
||||
"User.isTournamentOrganizer",
|
||||
userIsTournamentOrganizer,
|
||||
"User.patronTier",
|
||||
"User.favoriteBadgeId",
|
||||
"User.languages",
|
||||
|
|
|
|||
|
|
@ -196,6 +196,7 @@
|
|||
"support.perk.prioritySupport.extra": "Access to a separate helpdesk that I prioritize for support requests",
|
||||
"support.perk.previewQ": "Preview groups in SendouQ before joining",
|
||||
"support.perk.joinFive": "Join up to 5 teams",
|
||||
"support.perk.tournamentsBeta": "Access to tournaments beta",
|
||||
|
||||
"custom.colors.title": "Custom colors",
|
||||
"custom.colors.bg": "Background",
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user