@dcrackel/hematournamentui 1.0.566 → 1.0.568
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/dist/HemaTournamentUI-lib.es.js +17 -7
- package/dist/HemaTournamentUI-lib.umd.js +1 -1
- package/package.json +1 -1
- package/src/mocks/tournamentMock.js +181 -744
- package/src/stories/Organisms/Grids/GridContainer.vue +16 -12
- package/src/stories/Templates/OldTournamentMangement/AddTournament/PageOne/AddTournamentPageOne.stories.js +0 -60
- package/src/stories/Templates/OldTournamentMangement/AddTournament/PageOne/AddTournamentPageOne.vue +0 -230
- package/src/stories/Templates/OldTournamentMangement/AddTournament/PageTwo/AddTournamentPageTwo.stories.js +0 -26
- package/src/stories/Templates/OldTournamentMangement/AddTournament/PageTwo/AddTournamentPageTwo.vue +0 -150
- package/src/stories/Templates/OldTournamentMangement/EditTournament/EditBasic/EditTournamentBasicInfo.stories.js +0 -35
- package/src/stories/Templates/OldTournamentMangement/EditTournament/EditBasic/EditTournamentBasicInfo.vue +0 -235
- package/src/stories/Templates/OldTournamentMangement/EditTournament/EditDetails/EditTournamentDetails.stories.js +0 -22
- package/src/stories/Templates/OldTournamentMangement/EditTournament/EditDetails/EditTournamentDetails.vue +0 -165
|
@@ -11561,6 +11561,18 @@ const ww = /* @__PURE__ */ oe(Iw, [["render", vw]]), yw = {
|
|
|
11561
11561
|
filteredItems: this.items
|
|
11562
11562
|
};
|
|
11563
11563
|
},
|
|
11564
|
+
watch: {
|
|
11565
|
+
items: {
|
|
11566
|
+
handler(n) {
|
|
11567
|
+
this.filteredItems = [...n], this.applyFilters();
|
|
11568
|
+
},
|
|
11569
|
+
deep: !0,
|
|
11570
|
+
immediate: !0
|
|
11571
|
+
}
|
|
11572
|
+
},
|
|
11573
|
+
mounted() {
|
|
11574
|
+
this.applyFilters();
|
|
11575
|
+
},
|
|
11564
11576
|
computed: {
|
|
11565
11577
|
getTitle() {
|
|
11566
11578
|
switch (this.component) {
|
|
@@ -11608,17 +11620,15 @@ const ww = /* @__PURE__ */ oe(Iw, [["render", vw]]), yw = {
|
|
|
11608
11620
|
methods: {
|
|
11609
11621
|
applyFilters() {
|
|
11610
11622
|
let n = [...this.items];
|
|
11611
|
-
n = this.applySearchFilter(n),
|
|
11623
|
+
n = this.applySearchFilter(n), this.component === "TournamentAdminCard" && (n = this.filterByTimeFrame(n)), n = this.applySorting(n), this.filteredItems = n;
|
|
11612
11624
|
},
|
|
11613
11625
|
applySearchFilter(n) {
|
|
11614
11626
|
if (!this.filterOn.trim()) return n;
|
|
11615
|
-
console.log("applySearchFilter on:", this.filterOn);
|
|
11616
11627
|
const e = this.filterOn.toLowerCase();
|
|
11617
|
-
|
|
11618
|
-
var o, i, A
|
|
11619
|
-
return this.component === "TournamentAdminCard" ? ((
|
|
11628
|
+
return n.filter((t) => {
|
|
11629
|
+
var r, o, i, A;
|
|
11630
|
+
return this.component === "TournamentAdminCard" ? ((r = t.Name) == null ? void 0 : r.toLowerCase().includes(e)) ?? !1 : this.component === "FencerFinalResultCard" ? ((i = (o = t.Person) == null ? void 0 : o.DisplayName) == null ? void 0 : i.toLowerCase().includes(e)) ?? !1 : this.component === "ClubCard" ? ((A = t.Name) == null ? void 0 : A.toLowerCase().includes(e)) ?? !1 : !1;
|
|
11620
11631
|
});
|
|
11621
|
-
return console.log("Filtered items:", t), t;
|
|
11622
11632
|
},
|
|
11623
11633
|
filterByTimeFrame(n) {
|
|
11624
11634
|
const e = /* @__PURE__ */ new Date();
|
|
@@ -11675,7 +11685,7 @@ const ww = /* @__PURE__ */ oe(Iw, [["render", vw]]), yw = {
|
|
|
11675
11685
|
this.sortCriteria = n.text;
|
|
11676
11686
|
},
|
|
11677
11687
|
handleTimeFrameChange(n) {
|
|
11678
|
-
this.selectedTimeFrame = n;
|
|
11688
|
+
this.selectedTimeFrame = n, this.applyFilters();
|
|
11679
11689
|
},
|
|
11680
11690
|
handleClick(n) {
|
|
11681
11691
|
this.$emit("update:edit", n.TournamentId);
|