@dcrackel/hematournamentui 1.0.699 → 1.0.702
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/AGENTS.md +3 -0
- package/dist/HemaTournamentUI-lib.es.js +10913 -10269
- package/dist/HemaTournamentUI-lib.umd.js +27 -27
- package/dist/hematournamentui-tailwind.css +23 -0
- package/dist/hematournamentui.css +1 -1
- package/package.json +8 -8
- package/src/stories/Molecules/Boxes/BoutBoxes/TimerBox/TimerBox.vue +1 -1
- package/src/stories/Molecules/Buttons/BaseButton/BaseButton.vue +1 -1
- package/src/stories/Molecules/Buttons/ButtonBar/ButtonBar.vue +1 -1
- package/src/stories/Molecules/Modals/DirectorModal/DirectorModal.vue +2 -2
- package/src/stories/Organisms/Cards/BoutCard/Variants/BoutCardActive/BoutCardActive.vue +25 -22
- package/src/stories/Organisms/Cards/BoutCard/Variants/BoutCardInactive/BoutCardInactive.vue +31 -29
- package/src/stories/Organisms/Cards/BoutCard/Variants/BoutCardWaiting/BoutCardWaiting.vue +2 -4
- package/src/stories/Organisms/Cards/KioskCard/KioskCard.vue +54 -35
- package/src/stories/Organisms/Cards/PenaltyCard/PenaltyCard.stories.js +6 -6
- package/src/stories/Organisms/Cards/PenaltyCard/PenaltyCard.vue +64 -53
- package/src/stories/Organisms/Cards/PenaltyFencerCard/PenaltyFencerCard.stories.js +6 -7
- package/src/stories/Organisms/Cards/PenaltyFencerCard/PenaltyFencerCard.vue +18 -10
- package/src/stories/Organisms/Cards/StaffCard/StaffCard.vue +4 -4
- package/src/stories/Organisms/Cards/WaitlistFencerCard/WaitlistFencerCard.vue +129 -0
- package/src/stories/Organisms/ComplexInputs/DatePicker/DatePicker.vue +64 -45
- package/src/stories/Organisms/Containers/KioskContainer/KioskContainer.vue +13 -9
- package/src/stories/Organisms/Containers/Pool/Pool.vue +1 -1
- package/src/stories/Organisms/Containers/PoolResults/PoolResultsTable.vue +35 -20
- package/src/stories/Organisms/Headers/AttendanceSummary/AttendanceSummary.vue +45 -19
- package/src/stories/Templates/Assignment/Assignment.stories.js +17 -15
- package/src/stories/Templates/Assignment/Assignment.vue +71 -40
- package/src/stories/Templates/ClubManagement/ClubBasic/ClubBasic.stories.js +49 -30
- package/src/stories/Templates/ClubManagement/ClubBasic/ClubBasic.vue +29 -28
- package/src/stories/Templates/ClubManagement/{ClubMangement.stories.js → ClubManagement.stories.js} +74 -59
- package/src/stories/Templates/ClubManagement/ClubManagement.vue +104 -92
- package/src/stories/Templates/EventManagement/Bracket/Bracket.vue +92 -97
- package/src/stories/Templates/EventManagement/EditEventInfo/EditEventInfo.stories.js +37 -33
- package/src/stories/Templates/EventManagement/EditEventInfo/EditEventInfo.vue +11 -14
- package/src/stories/Templates/EventManagement/EventAttendance/EventAttendance.stories.js +49 -14
- package/src/stories/Templates/EventManagement/EventAttendance/EventAttendance.vue +156 -62
- package/src/stories/Templates/EventManagement/EventFinalResults/EventFinalResults.stories.js +11 -10
- package/src/stories/Templates/EventManagement/EventFinalResults/EventFinalResults.vue +8 -8
- package/src/stories/Templates/EventManagement/KioskDisplay/KioskDisplay.stories.js +13 -16
- package/src/stories/Templates/EventManagement/KioskDisplay/KioskDisplay.vue +25 -25
- package/src/stories/Templates/EventManagement/Penalties/PenaltyReport.stories.js +25 -24
- package/src/stories/Templates/EventManagement/Penalties/PenaltyReport.vue +28 -34
- package/src/stories/Templates/EventManagement/PoolLive/PoolLive.stories.js +54 -19
- package/src/stories/Templates/EventManagement/PoolLive/PoolLive.vue +75 -68
- package/src/stories/Templates/EventManagement/PoolManagement/PoolManagement.stories.js +55 -45
- package/src/stories/Templates/EventManagement/PoolManagement/PoolManagement.vue +47 -55
- package/src/stories/Templates/EventManagement/PoolResults/PoolResults.stories.js +56 -55
- package/src/stories/Templates/EventManagement/PoolResults/PoolResults.vue +71 -73
- package/src/stories/Templates/EventManagement/StaffList/StaffList.stories.js +18 -16
- package/src/stories/Templates/EventManagement/StaffList/StaffList.vue +9 -6
- package/src/stories/Templates/Menus/Admin/AdminLeftMenu.stories.js +22 -19
- package/src/stories/Templates/Menus/Admin/AdminLeftMenu.vue +44 -36
- package/src/stories/Templates/Menus/EditEventsTopMenu/EditEventsTopMenu.stories.js +30 -23
- package/src/stories/Templates/Menus/EditEventsTopMenu/EditEventsTopMenu.vue +55 -58
- package/src/stories/Templates/PersonManagement/Admin/Administration/Administration.stories.js +67 -0
- package/src/stories/Templates/PersonManagement/Admin/{Administration.vue → Administration/Administration.vue} +94 -87
- package/src/stories/Templates/PersonManagement/Admin/FencerAdmin/FencerAdmin.stories.js +71 -0
- package/src/stories/Templates/PersonManagement/Admin/{FencerAdmin.vue → FencerAdmin/FencerAdmin.vue} +90 -77
- package/src/stories/Templates/PersonManagement/Admin/MergeAccounts/MergeAccounts.stories.js +86 -0
- package/src/stories/Templates/PersonManagement/Admin/{MergeAccounts.vue → MergeAccounts/MergeAccounts.vue} +258 -242
- package/src/stories/Templates/PersonManagement/Attendance/Attendance.vue +28 -28
- package/src/stories/Templates/PersonManagement/PersonManagement.vue +1 -1
- package/src/stories/Templates/TournamentManagement/ListEvents/ListEvents.stories.js +45 -28
- package/src/stories/Templates/TournamentManagement/ListEvents/ListEvents.vue +22 -16
- package/src/stories/Templates/TournamentManagement/{TournamentMangement.stories.js → TournamentManagement.stories.js} +68 -39
- package/src/stories/Templates/TournamentManagement/TournamentManagement.vue +199 -153
- package/src/stories/Templates/TournamentManagement/TournamentPageOne/TournamentPageOne.stories.js +113 -0
- package/src/stories/Templates/TournamentManagement/TournamentPageOne/TournamentPageOne.vue +123 -106
- package/src/stories/Templates/TournamentManagement/TournamentPageTwo/TournamentPageTwo.stories.js +76 -31
- package/src/stories/Templates/TournamentManagement/TournamentPageTwo/{TouranmentPageTwo.vue → TournamentPageTwo.vue} +63 -44
- package/src/stories/Templates/PersonManagement/Admin/FencerAdmin.stories.js +0 -48
- package/src/stories/Templates/TournamentManagement/TournamentPageOne/TouranmentPageOne.stories.js +0 -63
|
@@ -1,9 +1,35 @@
|
|
|
1
1
|
import EditEvents from './EventAttendance.vue';
|
|
2
|
-
import eventPersonGetEventById from '../../../../mocks/eventpersonGetEventById.js';
|
|
3
|
-
import personsAllMock from '../../../../mocks/personGetAllMock.js';
|
|
4
|
-
import clubsMock from '../../../../mocks/clubGetAllMock.js';
|
|
5
|
-
|
|
6
|
-
|
|
2
|
+
import eventPersonGetEventById from '../../../../mocks/eventpersonGetEventById.js';
|
|
3
|
+
import personsAllMock from '../../../../mocks/personGetAllMock.js';
|
|
4
|
+
import clubsMock from '../../../../mocks/clubGetAllMock.js';
|
|
5
|
+
|
|
6
|
+
const makeEventWithCapacity = (event, capacity) => ({
|
|
7
|
+
...event,
|
|
8
|
+
EventRules: [
|
|
9
|
+
...(event.EventRules || []),
|
|
10
|
+
{
|
|
11
|
+
Rules: {RuleName: 'CutOffNumber'},
|
|
12
|
+
RuleValue: capacity
|
|
13
|
+
}
|
|
14
|
+
]
|
|
15
|
+
});
|
|
16
|
+
|
|
17
|
+
const makeWaitlistPerson = (person, waitlistPosition) => ({
|
|
18
|
+
...person,
|
|
19
|
+
Id: `${person.Id}-waitlist`,
|
|
20
|
+
Status: 'Waitlist',
|
|
21
|
+
WaitlistPosition: waitlistPosition,
|
|
22
|
+
Person: {
|
|
23
|
+
...person.Person,
|
|
24
|
+
PersonId: `${person.Person.PersonId}-waitlist`,
|
|
25
|
+
DisplayName: `${person.Person.DisplayName} WL`
|
|
26
|
+
}
|
|
27
|
+
});
|
|
28
|
+
|
|
29
|
+
const waitlistedPersons = eventPersonGetEventById.persons.slice(0, 3).map((person, index) => makeWaitlistPerson(person, index + 1));
|
|
30
|
+
const activeRoster = eventPersonGetEventById.persons.slice(3);
|
|
31
|
+
|
|
32
|
+
export default {
|
|
7
33
|
title: 'Templates/EventManagement/EventAttendance',
|
|
8
34
|
component: EditEvents,
|
|
9
35
|
tags: ['autodocs'],
|
|
@@ -67,12 +93,21 @@ export const NoPeople = {
|
|
|
67
93
|
}
|
|
68
94
|
};
|
|
69
95
|
|
|
70
|
-
export const peopleAndLoading = {
|
|
71
|
-
args: {
|
|
72
|
-
personsInTournament: eventPersonGetEventById.persons,
|
|
73
|
-
personsAll: personsAllMock,
|
|
74
|
-
fencingClubs: clubsMock,
|
|
75
|
-
event: eventPersonGetEventById.event,
|
|
76
|
-
loading: true
|
|
77
|
-
}
|
|
78
|
-
};
|
|
96
|
+
export const peopleAndLoading = {
|
|
97
|
+
args: {
|
|
98
|
+
personsInTournament: eventPersonGetEventById.persons,
|
|
99
|
+
personsAll: personsAllMock,
|
|
100
|
+
fencingClubs: clubsMock,
|
|
101
|
+
event: eventPersonGetEventById.event,
|
|
102
|
+
loading: true
|
|
103
|
+
}
|
|
104
|
+
};
|
|
105
|
+
|
|
106
|
+
export const WithWaitlist = {
|
|
107
|
+
args: {
|
|
108
|
+
personsInTournament: [...activeRoster, ...waitlistedPersons],
|
|
109
|
+
personsAll: personsAllMock,
|
|
110
|
+
fencingClubs: clubsMock,
|
|
111
|
+
event: makeEventWithCapacity(eventPersonGetEventById.event, activeRoster.length)
|
|
112
|
+
}
|
|
113
|
+
};
|
|
@@ -1,7 +1,13 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<section>
|
|
3
3
|
<EditEventsTopMenu :currentTab="'Checkin'" :tabs="tabs(role, isMobile)" @tabMenuClick="handleTabMenuClick"/>
|
|
4
|
-
<AttendanceSummary
|
|
4
|
+
<AttendanceSummary
|
|
5
|
+
:event="event"
|
|
6
|
+
:absent="absent"
|
|
7
|
+
:present="present"
|
|
8
|
+
:activeCount="activeRosterCount"
|
|
9
|
+
:waitlistCount="waitlistCount"
|
|
10
|
+
:capacity="eventCapacity"/>
|
|
5
11
|
<div class="w-full flex flex-row justify-center mt-1 md:mt-3">
|
|
6
12
|
<section class="w-full">
|
|
7
13
|
<div class="w-full flex flex-col justify-center items-center" style="text-align: center">
|
|
@@ -24,22 +30,44 @@
|
|
|
24
30
|
</div>
|
|
25
31
|
</section>
|
|
26
32
|
|
|
27
|
-
<section v-if="loading"
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
33
|
+
<section v-if="loading" class="w-full">
|
|
34
|
+
<div v-for="index in 6" :key="index">
|
|
35
|
+
<FencerCardSkeleton class="mb-4"/>
|
|
36
|
+
</div>
|
|
37
|
+
</section>
|
|
38
|
+
<section v-if="!loading" class="w-full">
|
|
39
|
+
<div v-if="activeRosterCount > 0" class="mb-2 flex items-center justify-between">
|
|
40
|
+
<BaseText text="Active Roster" size="md" color="quaternary" weight="bold"/>
|
|
41
|
+
<BaseText :text="activeRosterSummary" size="sm" color="quinary"/>
|
|
42
|
+
</div>
|
|
43
|
+
<div v-for="(person, index) in sortedActivePersons" :key="person.PersonId || person.Person?.PersonId || index">
|
|
44
|
+
<FencerCard :person="person" class="mb-4"
|
|
45
|
+
:isLast="index === sortedActivePersons.length - 1"
|
|
46
|
+
:isEdit="event.Status === 'planning' || event.Status === 'preparation'"
|
|
47
|
+
@forward:toProfile="handleForwardToProfile"
|
|
48
|
+
@update:status="handleStatus"
|
|
36
49
|
@remove:fencer="handleRemoveFencer"
|
|
37
50
|
@update:moveUp="handleMoveUp"
|
|
38
51
|
@update:moveDown="handleMoveDown"
|
|
39
|
-
@request:weaver-sign="openWeaverModal"
|
|
40
|
-
/>
|
|
41
|
-
|
|
42
|
-
|
|
52
|
+
@request:weaver-sign="openWeaverModal"
|
|
53
|
+
/>
|
|
54
|
+
</div>
|
|
55
|
+
<section v-if="waitlistCount > 0" class="mt-6 w-full">
|
|
56
|
+
<div class="mb-2 flex items-center justify-between">
|
|
57
|
+
<BaseText text="Waitlist" size="md" color="quaternary" weight="bold"/>
|
|
58
|
+
<BaseText :text="waitlistSummary" size="sm" color="quinary"/>
|
|
59
|
+
</div>
|
|
60
|
+
<div v-for="(person, index) in sortedWaitlistedPersons" :key="person.PersonId || person.Person?.PersonId || index" class="mb-3">
|
|
61
|
+
<WaitlistFencerCard
|
|
62
|
+
:person="person"
|
|
63
|
+
:queuePosition="index + 1"
|
|
64
|
+
@forward:toProfile="handleForwardToProfile"
|
|
65
|
+
@move:active="handleMoveWaitlistToActive"
|
|
66
|
+
@remove:fencer="handleRemoveWaitlistFencer"/>
|
|
67
|
+
</div>
|
|
68
|
+
</section>
|
|
69
|
+
</section>
|
|
70
|
+
<div v-if="!loading && personsInTournament.length === 0" class="mb-10">
|
|
43
71
|
<div class="flex items-center border border-dropdownSelect rounded-lg shadow-lg bg-poolBox">
|
|
44
72
|
<BaseText text="Remember to assign staff to your event!" size="lg" color="quaternary" weight="bold" class="w-full text-center py-2 px-8"/>
|
|
45
73
|
</div>
|
|
@@ -68,11 +96,10 @@
|
|
|
68
96
|
</template>
|
|
69
97
|
|
|
70
98
|
<script>
|
|
71
|
-
import BaseText from "../../../Atoms/Text/BaseText.vue";
|
|
72
|
-
import
|
|
73
|
-
import
|
|
74
|
-
import
|
|
75
|
-
import FencerCard from "../../../Organisms/Cards/FencerCard/FencerCard.vue";
|
|
99
|
+
import BaseText from "../../../Atoms/Text/BaseText.vue";
|
|
100
|
+
import emptyDesertIcon from '../../../../assets/empty_desert_icon.png';
|
|
101
|
+
import FencerCard from "../../../Organisms/Cards/FencerCard/FencerCard.vue";
|
|
102
|
+
import WaitlistFencerCard from "../../../Organisms/Cards/WaitlistFencerCard/WaitlistFencerCard.vue";
|
|
76
103
|
import EditEventsTopMenu from "../../Menus/EditEventsTopMenu/EditEventsTopMenu.vue";
|
|
77
104
|
import DropDownMenu from "../../../Organisms/ComplexInputs/DropDown/DropDownMenu.vue";
|
|
78
105
|
import FindOrAddPerson from "../../../Organisms/ComplexInputs/FindOrAddPerson/FindOrAddPerson.vue";
|
|
@@ -96,19 +123,34 @@ const personSorters = {
|
|
|
96
123
|
}
|
|
97
124
|
};
|
|
98
125
|
|
|
126
|
+
const waitlistStatuses = new Set(['waitlist', 'waitlisted', 'waitinglist']);
|
|
127
|
+
|
|
128
|
+
const normalizeStatus = (status) => String(status || '').toLocaleLowerCase().replace(/[\s_-]/g, '');
|
|
129
|
+
|
|
130
|
+
const isWaitlistedPerson = (person) => waitlistStatuses.has(normalizeStatus(person?.Status));
|
|
131
|
+
|
|
132
|
+
const getEventRuleValue = (event, ruleName) => {
|
|
133
|
+
const rule = event?.EventRules?.find(eventRule => eventRule?.Rules?.RuleName === ruleName);
|
|
134
|
+
return rule?.RuleValue;
|
|
135
|
+
};
|
|
136
|
+
|
|
137
|
+
const getWaitlistOrderValue = (person) => {
|
|
138
|
+
const order = person?.WaitlistPosition ?? person?.WaitlistOrder ?? person?.CreatedAt ?? person?.Seed ?? person?.PoolPosition ?? 0;
|
|
139
|
+
return Number.isNaN(Number(order)) ? order : Number(order);
|
|
140
|
+
};
|
|
141
|
+
|
|
99
142
|
export default {
|
|
100
|
-
emits: ['add:existing-person', 'add:person', 'forward:toProfile', 'remove:fencer', 'tab:menu-click', 'update:moveDown', 'update:moveUp', 'update:person', 'weaver:sign'],
|
|
101
|
-
components: {
|
|
102
|
-
|
|
143
|
+
emits: ['add:existing-person', 'add:person', 'forward:toProfile', 'move:waitlist-to-active', 'remove:fencer', 'remove:waitlist-fencer', 'tab:menu-click', 'update:moveDown', 'update:moveUp', 'update:person', 'weaver:sign'],
|
|
144
|
+
components: {
|
|
145
|
+
WaitlistFencerCard,
|
|
146
|
+
FencerCardSkeleton,
|
|
103
147
|
AttendanceSummary,
|
|
104
148
|
FindOrAddPerson,
|
|
105
149
|
DropDownMenu,
|
|
106
150
|
EditEventsTopMenu,
|
|
107
|
-
FencerCard,
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
BaseButton,
|
|
111
|
-
BaseModal
|
|
151
|
+
FencerCard,
|
|
152
|
+
BaseText,
|
|
153
|
+
BaseModal
|
|
112
154
|
},
|
|
113
155
|
props: {
|
|
114
156
|
personsAll: Array,
|
|
@@ -159,22 +201,35 @@ export default {
|
|
|
159
201
|
},
|
|
160
202
|
computed: {
|
|
161
203
|
weaverModalBody() {
|
|
162
|
-
const p = this.pendingWeaverPerson?.Person;
|
|
163
|
-
const name = p?.DisplayName ?? 'This fencer';
|
|
164
|
-
return `Has ${name}
|
|
204
|
+
const p = this.pendingWeaverPerson?.Person;
|
|
205
|
+
const name = p?.DisplayName ?? 'This fencer';
|
|
206
|
+
return `Has ${name} completed signing the waiver?`;
|
|
165
207
|
},
|
|
166
208
|
isMobile() {
|
|
167
209
|
return this.windowWidth <= 748;
|
|
168
210
|
},
|
|
169
|
-
|
|
170
|
-
if (!Array.isArray(this.personsInTournament) || this.personsInTournament.length === 0) {
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
211
|
+
activePersons() {
|
|
212
|
+
if (!Array.isArray(this.personsInTournament) || this.personsInTournament.length === 0) {
|
|
213
|
+
return [];
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
return this.personsInTournament.filter(person => !isWaitlistedPerson(person));
|
|
217
|
+
},
|
|
218
|
+
waitlistedPersons() {
|
|
219
|
+
if (!Array.isArray(this.personsInTournament) || this.personsInTournament.length === 0) {
|
|
220
|
+
return [];
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
return this.personsInTournament.filter(isWaitlistedPerson);
|
|
224
|
+
},
|
|
225
|
+
sortedActivePersons() {
|
|
226
|
+
if (this.activePersons.length === 0) {
|
|
227
|
+
return [];
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
let sortedArray = [...this.activePersons]; // Clone array to prevent modifying props
|
|
231
|
+
|
|
232
|
+
sortedArray.sort((a, b) => {
|
|
178
233
|
if (!a || !b || !a.Person || !b.Person) {
|
|
179
234
|
console.warn("Undefined person object detected:", a, b);
|
|
180
235
|
return 0;
|
|
@@ -186,14 +241,50 @@ export default {
|
|
|
186
241
|
console.warn("Unknown sorting key:", this.localSelectedItem.link);
|
|
187
242
|
return 0;
|
|
188
243
|
});
|
|
189
|
-
return sortedArray;
|
|
190
|
-
},
|
|
191
|
-
|
|
192
|
-
return this.
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
244
|
+
return sortedArray;
|
|
245
|
+
},
|
|
246
|
+
sortedWaitlistedPersons() {
|
|
247
|
+
return [...this.waitlistedPersons].sort((a, b) => {
|
|
248
|
+
const orderA = getWaitlistOrderValue(a);
|
|
249
|
+
const orderB = getWaitlistOrderValue(b);
|
|
250
|
+
|
|
251
|
+
if (typeof orderA === 'number' && typeof orderB === 'number') {
|
|
252
|
+
return orderA - orderB;
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
return String(orderA).localeCompare(String(orderB));
|
|
256
|
+
});
|
|
257
|
+
},
|
|
258
|
+
activeRosterCount() {
|
|
259
|
+
return this.activePersons.length;
|
|
260
|
+
},
|
|
261
|
+
waitlistCount() {
|
|
262
|
+
return this.waitlistedPersons.length;
|
|
263
|
+
},
|
|
264
|
+
eventCapacity() {
|
|
265
|
+
const capacity = this.event?.CutOffNumber ?? this.event?.MaxFencers ?? getEventRuleValue(this.event, 'CutOffNumber');
|
|
266
|
+
if (capacity === 0 || capacity === '0') {
|
|
267
|
+
return 'Unlimited';
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
return capacity || '';
|
|
271
|
+
},
|
|
272
|
+
activeRosterSummary() {
|
|
273
|
+
if (!this.eventCapacity) {
|
|
274
|
+
return `${this.activeRosterCount} active`;
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
return `${this.activeRosterCount} / ${this.eventCapacity}`;
|
|
278
|
+
},
|
|
279
|
+
waitlistSummary() {
|
|
280
|
+
return `${this.waitlistCount} waiting`;
|
|
281
|
+
},
|
|
282
|
+
absent() {
|
|
283
|
+
return this.activePersons.filter(person => person.Status === 'Absent').length;
|
|
284
|
+
},
|
|
285
|
+
present() {
|
|
286
|
+
return this.activePersons.filter(person => person.Status === 'Present').length;
|
|
287
|
+
},
|
|
197
288
|
},
|
|
198
289
|
methods: {
|
|
199
290
|
openWeaverModal(person) {
|
|
@@ -210,25 +301,28 @@ export default {
|
|
|
210
301
|
},
|
|
211
302
|
handleSelectedItem(selectedItem) {
|
|
212
303
|
this.localSelectedItem = selectedItem;
|
|
213
|
-
},
|
|
214
|
-
handleStatus(person) {
|
|
215
|
-
person
|
|
216
|
-
|
|
217
|
-
},
|
|
304
|
+
},
|
|
305
|
+
handleStatus(person) {
|
|
306
|
+
this.$emit('update:person', person);
|
|
307
|
+
},
|
|
218
308
|
handleNewPerson(value) {
|
|
219
309
|
this.$emit('add:person', value);
|
|
220
|
-
},
|
|
221
|
-
handleAddExistingPerson(value) {
|
|
222
|
-
this
|
|
223
|
-
|
|
224
|
-
},
|
|
310
|
+
},
|
|
311
|
+
handleAddExistingPerson(value) {
|
|
312
|
+
this.$emit('add:existing-person', value);
|
|
313
|
+
},
|
|
225
314
|
handleTabMenuClick(value) {
|
|
226
315
|
this.$emit('tab:menu-click', value);
|
|
227
|
-
},
|
|
228
|
-
handleRemoveFencer(value) {
|
|
229
|
-
this
|
|
230
|
-
|
|
231
|
-
|
|
316
|
+
},
|
|
317
|
+
handleRemoveFencer(value) {
|
|
318
|
+
this.$emit('remove:fencer', value);
|
|
319
|
+
},
|
|
320
|
+
handleMoveWaitlistToActive(person) {
|
|
321
|
+
this.$emit('move:waitlist-to-active', person);
|
|
322
|
+
},
|
|
323
|
+
handleRemoveWaitlistFencer(person) {
|
|
324
|
+
this.$emit('remove:waitlist-fencer', person);
|
|
325
|
+
},
|
|
232
326
|
handleMoveUp(person){
|
|
233
327
|
this.$emit('update:moveUp', person);
|
|
234
328
|
},
|
package/src/stories/Templates/EventManagement/EventFinalResults/EventFinalResults.stories.js
CHANGED
|
@@ -14,10 +14,10 @@ export default {
|
|
|
14
14
|
argTypes: {
|
|
15
15
|
event: {
|
|
16
16
|
control: {type: 'object'}
|
|
17
|
-
},
|
|
18
|
-
finalResults: {
|
|
19
|
-
control: {type: '
|
|
20
|
-
},
|
|
17
|
+
},
|
|
18
|
+
finalResults: {
|
|
19
|
+
control: {type: 'array'}
|
|
20
|
+
},
|
|
21
21
|
role: {
|
|
22
22
|
control: {type: 'text'}
|
|
23
23
|
}
|
|
@@ -32,9 +32,10 @@ export const Default = {
|
|
|
32
32
|
}
|
|
33
33
|
};
|
|
34
34
|
|
|
35
|
-
export const NoResultsYet = {
|
|
36
|
-
args: {
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
}
|
|
35
|
+
export const NoResultsYet = {
|
|
36
|
+
args: {
|
|
37
|
+
event: eventMock[0],
|
|
38
|
+
finalResults: [],
|
|
39
|
+
role: 'director'
|
|
40
|
+
}
|
|
41
|
+
}
|
|
@@ -24,19 +24,19 @@ import BaseText from "../../../Atoms/Text/BaseText.vue";
|
|
|
24
24
|
import emptyDesertIcon from "../../../../assets/empty_desert_icon.png";
|
|
25
25
|
import { tabs } from '../../../Util/tabs.js';
|
|
26
26
|
|
|
27
|
-
export default {
|
|
28
|
-
name: '
|
|
27
|
+
export default {
|
|
28
|
+
name: 'EventFinalResults',
|
|
29
29
|
emits: ['export:HemaRatings', 'tab:menu-click'],
|
|
30
30
|
components: {BaseText, EventFinalResultsHeader, FinalResultsTable, EditEventsTopMenu},
|
|
31
31
|
props: {
|
|
32
32
|
event: {
|
|
33
33
|
type: Object,
|
|
34
34
|
required: true
|
|
35
|
-
},
|
|
36
|
-
finalResults: {
|
|
37
|
-
type:
|
|
38
|
-
required: true
|
|
39
|
-
},
|
|
35
|
+
},
|
|
36
|
+
finalResults: {
|
|
37
|
+
type: Array,
|
|
38
|
+
required: true
|
|
39
|
+
},
|
|
40
40
|
role: {
|
|
41
41
|
type: String,
|
|
42
42
|
default: 'Admin'
|
|
@@ -72,4 +72,4 @@ export default {
|
|
|
72
72
|
}
|
|
73
73
|
}
|
|
74
74
|
};
|
|
75
|
-
</script>
|
|
75
|
+
</script>
|
|
@@ -8,20 +8,17 @@ export default {
|
|
|
8
8
|
component: KioskDisplay,
|
|
9
9
|
tags: ['autodocs'],
|
|
10
10
|
args: {
|
|
11
|
-
displays: getCLubDisplayByClubId,
|
|
12
|
-
staffDropDown: getAllStaffByTournamentId,
|
|
13
|
-
eventDropDown: getEventByTournamentId,
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
clubs: { control: 'array '},
|
|
23
|
-
role: { control: 'text' }
|
|
24
|
-
},
|
|
11
|
+
displays: getCLubDisplayByClubId,
|
|
12
|
+
staffDropDown: getAllStaffByTournamentId,
|
|
13
|
+
eventDropDown: getEventByTournamentId,
|
|
14
|
+
role: 'Admin'
|
|
15
|
+
},
|
|
16
|
+
argTypes: {
|
|
17
|
+
displays: { control: 'array' },
|
|
18
|
+
staffDropDown: { control: 'array' },
|
|
19
|
+
eventDropDown: { control: 'array' },
|
|
20
|
+
role: { control: 'text' }
|
|
21
|
+
},
|
|
25
22
|
};
|
|
26
23
|
|
|
27
24
|
|
|
@@ -43,7 +40,7 @@ export const isAdmin = {
|
|
|
43
40
|
}
|
|
44
41
|
};
|
|
45
42
|
|
|
46
|
-
export const
|
|
43
|
+
export const isDirector = {
|
|
47
44
|
args: {
|
|
48
45
|
displays: getCLubDisplayByClubId,
|
|
49
46
|
staffDropDown: getAllStaffByTournamentId,
|
|
@@ -59,4 +56,4 @@ export const isClub = {
|
|
|
59
56
|
eventDropDown: getEventByTournamentId,
|
|
60
57
|
role: 'Club'
|
|
61
58
|
}
|
|
62
|
-
};
|
|
59
|
+
};
|
|
@@ -5,24 +5,22 @@
|
|
|
5
5
|
:displays="localDisplays"
|
|
6
6
|
:eventDropDown="eventDropDown"
|
|
7
7
|
:staffDropDown="staffDropDown"
|
|
8
|
-
:userRole="role"
|
|
9
|
-
@remove:kiosk="handleRemove"
|
|
10
|
-
@
|
|
8
|
+
:userRole="role"
|
|
9
|
+
@remove:kiosk="handleRemove"
|
|
10
|
+
@test:scoreboard="handleScoreboardTest"
|
|
11
|
+
@update:ringChange="handleRingChange"
|
|
11
12
|
@update:selectedStaff="handleAssignmentStaff"
|
|
12
13
|
@update:selectedEvent="handleAssignmentEvent"
|
|
13
14
|
@update:selectedType="handleSelectedType"
|
|
14
15
|
@update:assignToMe="handleAssignToMe"
|
|
15
16
|
@submit:kiosk="handleSubmit"
|
|
16
17
|
/>
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
import emptyDesertIcon from '../../../../assets/empty_desert_icon.png';
|
|
24
|
-
import EditEventsTopMenu from "../../Menus/EditEventsTopMenu/EditEventsTopMenu.vue";
|
|
25
|
-
import KioskContainer from "../../../Organisms/Containers/KioskContainer/KioskContainer.vue"
|
|
18
|
+
</section>
|
|
19
|
+
</template>
|
|
20
|
+
|
|
21
|
+
<script>
|
|
22
|
+
import EditEventsTopMenu from "../../Menus/EditEventsTopMenu/EditEventsTopMenu.vue";
|
|
23
|
+
import KioskContainer from "../../../Organisms/Containers/KioskContainer/KioskContainer.vue"
|
|
26
24
|
|
|
27
25
|
import { tabs } from '../../../Util/tabs.js';
|
|
28
26
|
|
|
@@ -33,7 +31,7 @@ export default {
|
|
|
33
31
|
EditEventsTopMenu
|
|
34
32
|
|
|
35
33
|
},
|
|
36
|
-
emits: ['remove:kiosk', 'update:selectedStaff', 'update:selectedEvent', 'update:selectedType', 'update:ringChange', 'submit:kiosk', 'update:assignToMe','tab:menu-click'],
|
|
34
|
+
emits: ['remove:kiosk', 'test:scoreboard', 'update:selectedStaff', 'update:selectedEvent', 'update:selectedType', 'update:ringChange', 'submit:kiosk', 'update:assignToMe','tab:menu-click'],
|
|
37
35
|
props: {
|
|
38
36
|
displays: {
|
|
39
37
|
type: Array,
|
|
@@ -52,19 +50,18 @@ export default {
|
|
|
52
50
|
default: 'Director'
|
|
53
51
|
}
|
|
54
52
|
},
|
|
55
|
-
data() {
|
|
56
|
-
return {
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
windowWidth: window.innerWidth,
|
|
53
|
+
data() {
|
|
54
|
+
return {
|
|
55
|
+
tabs,
|
|
56
|
+
localDisplays: [...this.displays],
|
|
57
|
+
windowWidth: window.innerWidth,
|
|
61
58
|
}
|
|
62
59
|
},
|
|
63
60
|
watch: {
|
|
64
|
-
displays: {
|
|
65
|
-
handler(newDisplays) {
|
|
66
|
-
this.localDisplays = newDisplays
|
|
67
|
-
},
|
|
61
|
+
displays: {
|
|
62
|
+
handler(newDisplays) {
|
|
63
|
+
this.localDisplays = [...newDisplays]
|
|
64
|
+
},
|
|
68
65
|
deep: true
|
|
69
66
|
}
|
|
70
67
|
},
|
|
@@ -79,8 +76,11 @@ export default {
|
|
|
79
76
|
return this.windowWidth <= 748;
|
|
80
77
|
},
|
|
81
78
|
},
|
|
82
|
-
methods: {
|
|
83
|
-
|
|
79
|
+
methods: {
|
|
80
|
+
handleScoreboardTest(display) {
|
|
81
|
+
this.$emit('test:scoreboard', display);
|
|
82
|
+
},
|
|
83
|
+
handleTabMenuClick(value) {
|
|
84
84
|
this.$emit('tab:menu-click', value);
|
|
85
85
|
},
|
|
86
86
|
handleRingChange(item){
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import
|
|
2
|
-
import getPenaltiesByEvent from '../../../../mocks/getPenaltiesByEvent.js';
|
|
3
|
-
|
|
4
|
-
export default {
|
|
5
|
-
title: 'Templates/EventManagement/
|
|
6
|
-
component:
|
|
7
|
-
args: {
|
|
8
|
-
event: getPenaltiesByEvent.Event,
|
|
9
|
-
penalties: getPenaltiesByEvent.Penalties,
|
|
10
|
-
},
|
|
11
|
-
argTypes: {
|
|
12
|
-
event: {
|
|
13
|
-
control:
|
|
14
|
-
},
|
|
15
|
-
penalties: {
|
|
16
|
-
control:
|
|
17
|
-
},
|
|
18
|
-
},
|
|
19
|
-
};
|
|
1
|
+
import PenaltyReport from './PenaltyReport.vue';
|
|
2
|
+
import getPenaltiesByEvent from '../../../../mocks/getPenaltiesByEvent.js';
|
|
3
|
+
|
|
4
|
+
export default {
|
|
5
|
+
title: 'Templates/EventManagement/PenaltyReport',
|
|
6
|
+
component: PenaltyReport,
|
|
7
|
+
args: {
|
|
8
|
+
event: getPenaltiesByEvent.Event,
|
|
9
|
+
penalties: getPenaltiesByEvent.Penalties,
|
|
10
|
+
},
|
|
11
|
+
argTypes: {
|
|
12
|
+
event: {
|
|
13
|
+
control: { type: 'object' },
|
|
14
|
+
},
|
|
15
|
+
penalties: {
|
|
16
|
+
control: { type: 'array' },
|
|
17
|
+
},
|
|
18
|
+
},
|
|
19
|
+
};
|
|
20
20
|
|
|
21
21
|
export const Default = {
|
|
22
22
|
args: {
|
|
@@ -26,8 +26,9 @@ export const Default = {
|
|
|
26
26
|
};
|
|
27
27
|
|
|
28
28
|
|
|
29
|
-
export const NoPenalties = {
|
|
30
|
-
args: {
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
}
|
|
29
|
+
export const NoPenalties = {
|
|
30
|
+
args: {
|
|
31
|
+
event: getPenaltiesByEvent.Event,
|
|
32
|
+
penalties: [],
|
|
33
|
+
},
|
|
34
|
+
};
|