Commit fc93bfe5 authored by xiaoye's avatar xiaoye

Update tournament.vue

parent bff9d8cb
Pipeline #38019 passed with stages
in 2 minutes and 6 seconds
...@@ -564,6 +564,7 @@ ...@@ -564,6 +564,7 @@
// @ts-ignore // @ts-ignore
if (await Tabulator.Participant.Create(Mycard.token, { name : participant.name, tournamentId : tournament.this.id}, participant.array)) { if (await Tabulator.Participant.Create(Mycard.token, { name : participant.name, tournamentId : tournament.this.id}, participant.array)) {
participant.name = ''; participant.name = '';
searcher.reset();
await tournament.search(); await tournament.search();
} }
}, },
...@@ -700,6 +701,7 @@ ...@@ -700,6 +701,7 @@
page.loading = true; page.loading = true;
participant.name = ''; participant.name = '';
participant.copyValue = 0; participant.copyValue = 0;
searcher.reset();
if (await tournament.search()) { if (await tournament.search()) {
if (match.round > match.maxRound) if (match.round > match.maxRound)
match.round = match.maxRound; match.round = match.maxRound;
...@@ -734,6 +736,10 @@ ...@@ -734,6 +736,10 @@
}, },
filterParticipant : (i : Participant) : boolean => { filterParticipant : (i : Participant) : boolean => {
return searcher.participant ? i.name.toUpperCase().includes(searcher.participant.toUpperCase()) : true; return searcher.participant ? i.name.toUpperCase().includes(searcher.participant.toUpperCase()) : true;
},
reset : () : void => {
searcher.participant = '';
searcher.match = '';
} }
}); });
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment