Skip to content

Commit 1494156

Browse files
committed
fix search by uuid
1 parent ded1852 commit 1494156

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

web/src/components/Footer.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ export default {
2020
]),
2121
lastUpdate() {
2222
if (this.player && this.info) {
23-
return moment(this.player.data.lastUpdate || 0).format(this.info.timeFormat ? this.info.timeFormat.full : '');
23+
return moment(this.player.data.lastUpdate || 0).format(this.info.timeFormat ? this.info.timeFormat.full : '');
2424
} else if (this.info) {
2525
return moment(this.info.lastUpdate || 0).format(this.info.timeFormat ? this.info.timeFormat.full : '');
2626
}

web/src/components/PlayerList.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
</b-alert>
99
<b-progress v-show="loading" :value="100" :max="100" animated class="mb-3"></b-progress>
1010
<b-row class="searchbox">
11-
<b-col sm="12"><b-form-input id="input-none" type="text" :value="keyword" @input="updateKeyword" placeholder="Search user by Name/UUID"></b-form-input></b-col>
11+
<b-col sm="12"><b-form-input id="input-none" type="text" :value="keyword" @input="updateKeyword" placeholder="Search user by Name / UUID"></b-form-input></b-col>
1212
</b-row>
1313
<lazy-component class="row">
1414
<playerblock v-for="(player, key, index) in playerList" :key="index" :player="player" v-show="search(player)"></playerblock>
@@ -78,7 +78,7 @@ export default {
7878
return true;
7979
}
8080
const keyword = this.keyword.toLowerCase();
81-
if (player.uuid === keyword) {
81+
if (player.uuid.indexOf(keyword.replace('-', '')) !== -1) {
8282
return true;
8383
}
8484
if (player.playername.toLowerCase().indexOf(keyword) !== -1) {

0 commit comments

Comments
 (0)