From d13248277fe74822d40602d8a70bd115974b28fb Mon Sep 17 00:00:00 2001 From: Daniel Szabo Date: Sun, 15 Jun 2025 18:23:56 +0100 Subject: [PATCH 01/15] Add Tag interface --- src/interfaces/tag.ts | 4 ++++ src/interfaces/tournament.ts | 2 ++ 2 files changed, 6 insertions(+) create mode 100644 src/interfaces/tag.ts diff --git a/src/interfaces/tag.ts b/src/interfaces/tag.ts new file mode 100644 index 0000000..847b8c6 --- /dev/null +++ b/src/interfaces/tag.ts @@ -0,0 +1,4 @@ +export interface Tag { + id?: number; + label: string; +} diff --git a/src/interfaces/tournament.ts b/src/interfaces/tournament.ts index 5c6231d..33c985f 100644 --- a/src/interfaces/tournament.ts +++ b/src/interfaces/tournament.ts @@ -1,6 +1,7 @@ import { Category } from "./category"; import { Club } from "./club"; import { Official } from "./official"; +import { Tag } from "./tag"; import { TeamCategory } from "./team-category"; export interface Tournament { @@ -24,4 +25,5 @@ export interface Tournament { drawUrl: string | null; notificationsSentAt?: Date | null; '@type'?: string; + tags?: Tag[]; } From 6e533bd945247bd7cba0cdfea3bf2327b946b4d0 Mon Sep 17 00:00:00 2001 From: Richard Toth Date: Sun, 15 Jun 2025 19:57:16 +0200 Subject: [PATCH 02/15] 2.1.0 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 899fe1e..62f3482 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@mtlsz/common", - "version": "2.0.2", + "version": "2.1.0", "description": "MTLSZ frontend packages", "main": "dist/index.ts", "types": "dist/index.d.ts", From 67a999796a03c71776c5f33af6cbc9c7617ae0ca Mon Sep 17 00:00:00 2001 From: Daniel Szabo Date: Sun, 15 Jun 2025 19:11:15 +0100 Subject: [PATCH 03/15] Export tag interface --- src/index.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/index.ts b/src/index.ts index cf8398f..bbb1c40 100644 --- a/src/index.ts +++ b/src/index.ts @@ -18,3 +18,4 @@ export * from "./interfaces/tournament"; export * from "./interfaces/guest-player-request"; export * from "./interfaces/single-tournament"; export * from "./interfaces/team-championship"; +export * from "./interfaces/tag"; From 209775f968356483f15bc2b17e380a8fa2b0609d Mon Sep 17 00:00:00 2001 From: Richard Toth Date: Sun, 15 Jun 2025 22:29:49 +0200 Subject: [PATCH 04/15] 2.1.1 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 62f3482..8681935 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@mtlsz/common", - "version": "2.1.0", + "version": "2.1.1", "description": "MTLSZ frontend packages", "main": "dist/index.ts", "types": "dist/index.d.ts", From 696c3577a78753d4d5ec74e0124e84b58e38a08e Mon Sep 17 00:00:00 2001 From: Richard Toth Date: Fri, 11 Apr 2025 11:40:09 +0200 Subject: [PATCH 05/15] 3.0.0 --- package.json | 5 ++--- src/interfaces/generic-user.ts | 7 +++++++ src/interfaces/official.ts | 7 ++++--- src/interfaces/player.ts | 31 +++++++++++++--------------- src/interfaces/team-administrator.ts | 15 +++++++------- 5 files changed, 34 insertions(+), 31 deletions(-) create mode 100644 src/interfaces/generic-user.ts diff --git a/package.json b/package.json index 8681935..823d0ec 100644 --- a/package.json +++ b/package.json @@ -1,13 +1,12 @@ { "name": "@mtlsz/common", - "version": "2.1.1", + "version": "3.0.0", "description": "MTLSZ frontend packages", "main": "dist/index.ts", "types": "dist/index.d.ts", "scripts": { "build": "tsc", - "test": "echo \"Error: no test specified\" && exit 1", - "publish": "npm publish --registry http://registry.trweb.hu" + "test": "echo \"Error: no test specified\" && exit 1" }, "repository": { "type": "git", diff --git a/src/interfaces/generic-user.ts b/src/interfaces/generic-user.ts new file mode 100644 index 0000000..83d9727 --- /dev/null +++ b/src/interfaces/generic-user.ts @@ -0,0 +1,7 @@ +export interface GenericUser { + firstName: string | null; + lastName: string | null; + emai: string | null; + phone: string | null; + keycloakUserId: string | null; +} diff --git a/src/interfaces/official.ts b/src/interfaces/official.ts index 61125ed..4cfe857 100644 --- a/src/interfaces/official.ts +++ b/src/interfaces/official.ts @@ -1,8 +1,9 @@ -export interface Official { +import { GenericUser } from "./generic-user"; + +export interface Official extends GenericUser { id?: number; + /** @deprecated since 3.0.0. Use lastName and firstName instead */ name: string; - email: string; - phone?: string; /** @deprecated Use referee and umpire booleans instead */ type?: number; referee: boolean; diff --git a/src/interfaces/player.ts b/src/interfaces/player.ts index 452a423..34539ae 100644 --- a/src/interfaces/player.ts +++ b/src/interfaces/player.ts @@ -1,21 +1,18 @@ import { Club } from "./club"; +import { GenericUser } from "./generic-user"; import { RankingEntry } from "./ranking-entry"; -export interface Player { - id?: number; - firstName: string; - lastName: string; - gender: string; - birthDate: string; - birthPlace: string | null; - officialId?: number; - club: Club; - email?: string; - keycloakUserId?: string; - active?: boolean; - licenceFrom?: string; - licenceTo?: string; - disabledBecauseRanking?: boolean; - disabledBecauseSimilarEntry?: boolean; - rankingEntries?: RankingEntry[]; +export interface Player extends GenericUser { + id?: number; + gender: string; + birthDate: string; + birthPlace: string | null; + officialId?: number; + club: Club; + active?: boolean; + licenceFrom?: string; + licenceTo?: string; + disabledBecauseRanking?: boolean; + disabledBecauseSimilarEntry?: boolean; + rankingEntries?: RankingEntry[]; } diff --git a/src/interfaces/team-administrator.ts b/src/interfaces/team-administrator.ts index 973e443..a7503bb 100644 --- a/src/interfaces/team-administrator.ts +++ b/src/interfaces/team-administrator.ts @@ -1,11 +1,10 @@ import { Club } from "./club"; +import { GenericUser } from "./generic-user"; -export interface TeamAdministrator { - id?: number; - keycloakId?: string; - lastName: string; - firstName: string; - email: string; - active?: boolean; - club: Club; +export interface TeamAdministrator extends GenericUser { + id?: number; + /** @deprecated since 3.0.0. Use keycloakUserId instead */ + keycloakId?: string; + active?: boolean; + club: Club; } From e1397d781c1c77de97b2f2f44272397d441db2f0 Mon Sep 17 00:00:00 2001 From: Richard Toth Date: Fri, 11 Apr 2025 11:55:47 +0200 Subject: [PATCH 06/15] 3.0.1 --- package.json | 2 +- src/interfaces/generic-user.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 823d0ec..bec5ed3 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@mtlsz/common", - "version": "3.0.0", + "version": "3.0.1", "description": "MTLSZ frontend packages", "main": "dist/index.ts", "types": "dist/index.d.ts", diff --git a/src/interfaces/generic-user.ts b/src/interfaces/generic-user.ts index 83d9727..6c089ff 100644 --- a/src/interfaces/generic-user.ts +++ b/src/interfaces/generic-user.ts @@ -1,7 +1,7 @@ export interface GenericUser { firstName: string | null; lastName: string | null; - emai: string | null; + email: string | null; phone: string | null; keycloakUserId: string | null; } From df4ab60ee00a9a870d829923c998e06366da7733 Mon Sep 17 00:00:00 2001 From: Richard Toth Date: Fri, 11 Apr 2025 12:01:16 +0200 Subject: [PATCH 07/15] 3.0.2 --- package.json | 2 +- src/interfaces/generic-user.ts | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index bec5ed3..f06c8e4 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@mtlsz/common", - "version": "3.0.1", + "version": "3.0.2", "description": "MTLSZ frontend packages", "main": "dist/index.ts", "types": "dist/index.d.ts", diff --git a/src/interfaces/generic-user.ts b/src/interfaces/generic-user.ts index 6c089ff..24663ab 100644 --- a/src/interfaces/generic-user.ts +++ b/src/interfaces/generic-user.ts @@ -1,7 +1,7 @@ export interface GenericUser { - firstName: string | null; - lastName: string | null; - email: string | null; + firstName: string; + lastName: string; + email: string; phone: string | null; keycloakUserId: string | null; } From 5937c0cc5b9672a12b78ea7386df5476b716a398 Mon Sep 17 00:00:00 2001 From: Richard Toth Date: Fri, 11 Apr 2025 12:14:40 +0200 Subject: [PATCH 08/15] 3.0.3 --- package.json | 2 +- src/interfaces/generic-user.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index f06c8e4..1e14382 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@mtlsz/common", - "version": "3.0.2", + "version": "3.0.3", "description": "MTLSZ frontend packages", "main": "dist/index.ts", "types": "dist/index.d.ts", diff --git a/src/interfaces/generic-user.ts b/src/interfaces/generic-user.ts index 24663ab..9d754c5 100644 --- a/src/interfaces/generic-user.ts +++ b/src/interfaces/generic-user.ts @@ -3,5 +3,5 @@ export interface GenericUser { lastName: string; email: string; phone: string | null; - keycloakUserId: string | null; + keycloakUserId?: string | null; } From 2abc690bf90fea18fc8c391e91f7fe05402e13c5 Mon Sep 17 00:00:00 2001 From: Richard Toth Date: Tue, 6 May 2025 13:33:58 +0200 Subject: [PATCH 09/15] 3.0.4 --- package.json | 2 +- src/interfaces/official.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 1e14382..a7a1f74 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@mtlsz/common", - "version": "3.0.3", + "version": "3.0.4", "description": "MTLSZ frontend packages", "main": "dist/index.ts", "types": "dist/index.d.ts", diff --git a/src/interfaces/official.ts b/src/interfaces/official.ts index 4cfe857..6405405 100644 --- a/src/interfaces/official.ts +++ b/src/interfaces/official.ts @@ -3,7 +3,7 @@ import { GenericUser } from "./generic-user"; export interface Official extends GenericUser { id?: number; /** @deprecated since 3.0.0. Use lastName and firstName instead */ - name: string; + name?: string; /** @deprecated Use referee and umpire booleans instead */ type?: number; referee: boolean; From 8b8fe1402b40e9d3b7780bb9655994a8dbfe47e0 Mon Sep 17 00:00:00 2001 From: Richard Toth Date: Fri, 6 Jun 2025 16:40:57 +0200 Subject: [PATCH 10/15] 3.0.5 --- package.json | 2 +- src/interfaces/club.ts | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index a7a1f74..eb2aabc 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@mtlsz/common", - "version": "3.0.4", + "version": "3.0.5", "description": "MTLSZ frontend packages", "main": "dist/index.ts", "types": "dist/index.d.ts", diff --git a/src/interfaces/club.ts b/src/interfaces/club.ts index 51c8f24..eb3f373 100644 --- a/src/interfaces/club.ts +++ b/src/interfaces/club.ts @@ -9,4 +9,5 @@ export interface Club { address?: string; phone?: string; active: boolean; + hasManager: boolean; } \ No newline at end of file From 8dd92f32b7b285a11fd034a41d8e18544bb0a22b Mon Sep 17 00:00:00 2001 From: Richard Toth Date: Fri, 6 Jun 2025 16:54:26 +0200 Subject: [PATCH 11/15] 3.0.6 --- package.json | 2 +- src/interfaces/club.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index eb2aabc..06afde3 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@mtlsz/common", - "version": "3.0.5", + "version": "3.0.6", "description": "MTLSZ frontend packages", "main": "dist/index.ts", "types": "dist/index.d.ts", diff --git a/src/interfaces/club.ts b/src/interfaces/club.ts index eb3f373..5de9632 100644 --- a/src/interfaces/club.ts +++ b/src/interfaces/club.ts @@ -9,5 +9,5 @@ export interface Club { address?: string; phone?: string; active: boolean; - hasManager: boolean; + hasManager?: boolean; } \ No newline at end of file From 0b212e701b382f041eecb1cbdfd394bd2f616943 Mon Sep 17 00:00:00 2001 From: Richard Toth Date: Sun, 6 Jul 2025 18:55:27 +0200 Subject: [PATCH 12/15] 3.1.0 --- package.json | 2 +- src/interfaces/role.ts | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) create mode 100644 src/interfaces/role.ts diff --git a/package.json b/package.json index 06afde3..32b2bd6 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@mtlsz/common", - "version": "3.0.6", + "version": "3.1.0", "description": "MTLSZ frontend packages", "main": "dist/index.ts", "types": "dist/index.d.ts", diff --git a/src/interfaces/role.ts b/src/interfaces/role.ts new file mode 100644 index 0000000..ac77398 --- /dev/null +++ b/src/interfaces/role.ts @@ -0,0 +1,4 @@ +export interface Role { + role: string; + status: number; +} From c08588d5e844fdfb1a70e9ef978475459f340315 Mon Sep 17 00:00:00 2001 From: Richard Toth Date: Sun, 6 Jul 2025 18:59:19 +0200 Subject: [PATCH 13/15] 3.1.1 --- package.json | 2 +- src/index.ts | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index 32b2bd6..8826854 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@mtlsz/common", - "version": "3.1.0", + "version": "3.1.1", "description": "MTLSZ frontend packages", "main": "dist/index.ts", "types": "dist/index.d.ts", diff --git a/src/index.ts b/src/index.ts index bbb1c40..0029034 100644 --- a/src/index.ts +++ b/src/index.ts @@ -19,3 +19,4 @@ export * from "./interfaces/guest-player-request"; export * from "./interfaces/single-tournament"; export * from "./interfaces/team-championship"; export * from "./interfaces/tag"; +export * from "./interfaces/role"; From dfa40e5397ee5ed170ce966e0199a800952aca7d Mon Sep 17 00:00:00 2001 From: Richard Toth Date: Tue, 8 Jul 2025 16:35:20 +0200 Subject: [PATCH 14/15] 3.2.0 --- package.json | 2 +- src/index.ts | 6 ++++++ src/interfaces/confirmation-request.ts | 17 +++++++++++++++++ .../adult-confirmation-request.ts | 5 +++++ .../official-confirmation-request.ts | 4 ++++ .../player-confirmation-request.ts | 5 +++++ .../team-admin-confirmation-request.ts | 6 ++++++ .../team-manager-confirmation-request.ts | 5 +++++ 8 files changed, 49 insertions(+), 1 deletion(-) create mode 100644 src/interfaces/confirmation-request.ts create mode 100644 src/interfaces/confirmation-request/adult-confirmation-request.ts create mode 100644 src/interfaces/confirmation-request/official-confirmation-request.ts create mode 100644 src/interfaces/confirmation-request/player-confirmation-request.ts create mode 100644 src/interfaces/confirmation-request/team-admin-confirmation-request.ts create mode 100644 src/interfaces/confirmation-request/team-manager-confirmation-request.ts diff --git a/package.json b/package.json index 8826854..ad98381 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@mtlsz/common", - "version": "3.1.1", + "version": "3.2.0", "description": "MTLSZ frontend packages", "main": "dist/index.ts", "types": "dist/index.d.ts", diff --git a/src/index.ts b/src/index.ts index 0029034..024e814 100644 --- a/src/index.ts +++ b/src/index.ts @@ -20,3 +20,9 @@ export * from "./interfaces/single-tournament"; export * from "./interfaces/team-championship"; export * from "./interfaces/tag"; export * from "./interfaces/role"; +export * from "./interfaces/confirmation-request"; +export * from "./interfaces/confirmation-request/adult-confirmation-request"; +export * from "./interfaces/confirmation-request/official-confirmation-request"; +export * from "./interfaces/confirmation-request/player-confirmation-request"; +export * from "./interfaces/confirmation-request/team-admin-confirmation-request"; +export * from "./interfaces/confirmation-request/team-manager-confirmation-request"; diff --git a/src/interfaces/confirmation-request.ts b/src/interfaces/confirmation-request.ts new file mode 100644 index 0000000..af2176e --- /dev/null +++ b/src/interfaces/confirmation-request.ts @@ -0,0 +1,17 @@ +import { AdultConfirmationRequest } from "./confirmation-request/adult-confirmation-request"; +import { OfficialConfirmationRequest } from "./confirmation-request/official-confirmation-request"; +import { PlayerConfirmationRequest } from "./confirmation-request/player-confirmation-request"; +import { TeamAdminConfirmationRequest } from "./confirmation-request/team-admin-confirmation-request"; +import { TeamManagerConfirmationRequest } from "./confirmation-request/team-manager-confirmation-request"; + +export interface ConfirmationRequest { + id: number; + status: number; + roleString: string; + entity: + | PlayerConfirmationRequest + | AdultConfirmationRequest + | TeamManagerConfirmationRequest + | TeamAdminConfirmationRequest + | OfficialConfirmationRequest; +} diff --git a/src/interfaces/confirmation-request/adult-confirmation-request.ts b/src/interfaces/confirmation-request/adult-confirmation-request.ts new file mode 100644 index 0000000..d3247a0 --- /dev/null +++ b/src/interfaces/confirmation-request/adult-confirmation-request.ts @@ -0,0 +1,5 @@ +import { Player } from "../player"; + +export interface AdultConfirmationRequest { + kids: Player[]; +} diff --git a/src/interfaces/confirmation-request/official-confirmation-request.ts b/src/interfaces/confirmation-request/official-confirmation-request.ts new file mode 100644 index 0000000..b23c8a9 --- /dev/null +++ b/src/interfaces/confirmation-request/official-confirmation-request.ts @@ -0,0 +1,4 @@ +export interface OfficialConfirmationRequest { + referee: boolean; + umpire: boolean; +} diff --git a/src/interfaces/confirmation-request/player-confirmation-request.ts b/src/interfaces/confirmation-request/player-confirmation-request.ts new file mode 100644 index 0000000..fadf2f3 --- /dev/null +++ b/src/interfaces/confirmation-request/player-confirmation-request.ts @@ -0,0 +1,5 @@ +import { Club } from "../club"; + +export interface PlayerConfirmationRequest { + club: Club; +} \ No newline at end of file diff --git a/src/interfaces/confirmation-request/team-admin-confirmation-request.ts b/src/interfaces/confirmation-request/team-admin-confirmation-request.ts new file mode 100644 index 0000000..1892ed2 --- /dev/null +++ b/src/interfaces/confirmation-request/team-admin-confirmation-request.ts @@ -0,0 +1,6 @@ +import { Club } from "../club"; + +export interface TeamAdminConfirmationRequest { + active: boolean; + club: Club; +} \ No newline at end of file diff --git a/src/interfaces/confirmation-request/team-manager-confirmation-request.ts b/src/interfaces/confirmation-request/team-manager-confirmation-request.ts new file mode 100644 index 0000000..c8c0b0d --- /dev/null +++ b/src/interfaces/confirmation-request/team-manager-confirmation-request.ts @@ -0,0 +1,5 @@ +import { Club } from "../club"; + +export interface TeamManagerConfirmationRequest { + club: Club; +} From cff48d1e96ce37f4379024468df1078df301b551 Mon Sep 17 00:00:00 2001 From: Richard Toth Date: Fri, 11 Jul 2025 14:45:45 +0200 Subject: [PATCH 15/15] 3.2.1 --- package-lock.json | 4 ++-- package.json | 2 +- src/index.ts | 1 + src/interfaces/confirmation-requests.ts | 6 ++++++ 4 files changed, 10 insertions(+), 3 deletions(-) create mode 100644 src/interfaces/confirmation-requests.ts diff --git a/package-lock.json b/package-lock.json index 7f01004..70e1d70 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@mtlsz/common", - "version": "2.0.2", + "version": "3.2.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@mtlsz/common", - "version": "2.0.2", + "version": "3.2.0", "license": "ISC", "devDependencies": { "typescript": "^5.8.2" diff --git a/package.json b/package.json index ad98381..faf522c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@mtlsz/common", - "version": "3.2.0", + "version": "3.2.1", "description": "MTLSZ frontend packages", "main": "dist/index.ts", "types": "dist/index.d.ts", diff --git a/src/index.ts b/src/index.ts index 024e814..1aede93 100644 --- a/src/index.ts +++ b/src/index.ts @@ -26,3 +26,4 @@ export * from "./interfaces/confirmation-request/official-confirmation-request"; export * from "./interfaces/confirmation-request/player-confirmation-request"; export * from "./interfaces/confirmation-request/team-admin-confirmation-request"; export * from "./interfaces/confirmation-request/team-manager-confirmation-request"; +export * from "./interfaces/confirmation-requests"; diff --git a/src/interfaces/confirmation-requests.ts b/src/interfaces/confirmation-requests.ts new file mode 100644 index 0000000..1b50ba1 --- /dev/null +++ b/src/interfaces/confirmation-requests.ts @@ -0,0 +1,6 @@ +import { ConfirmationRequest } from "./confirmation-request"; + +export interface ConfirmationRequests { + roles: ConfirmationRequest[]; + canAddNewRole: boolean; +}