#5 dummy displays 'All' players and 'All' weapons on load

This commit is contained in:
2021-11-07 07:45:50 +01:00
committed by Giovanni Harting
parent e37b0c9141
commit 7659b84451

View File

@@ -2,7 +2,6 @@
<div class="hitgroup pt-2">
<div class="select-group mb-4">
<select v-if="store.state.playersArr" v-model="data.selectPlayer" class="form-select">
<option disabled value="">Select a Player</option>
<option value="All">All</option>
<option value="Team 1">Team 1</option>
<option value="Team 2">Team 2</option>
@@ -16,7 +15,6 @@
</select>
<select v-if="data.selectPlayer !== ''" :key="data.selectPlayer" v-model="data.selectWeapon" class="form-select">
<option disabled value="">Select a Weapon</option>
<option class="select-hr" value="All">All</option>
<option disabled></option>
<option v-for="(value, index) in processPlayerWeapon()" :key="index" :value="value">
@@ -55,8 +53,8 @@ export default {
const store = useStore()
const data = reactive({
selectPlayer: '',
selectWeapon: '',
selectPlayer: 'All',
selectWeapon: 'All',
eq_map: []
})
@@ -377,6 +375,11 @@ export default {
]);
buildCharts()
watch(() => props.stats, () => {
processDmg()
processPlayerWeapon()
})
}
})
@@ -394,7 +397,7 @@ export default {
}
watch(() => data.selectPlayer, () => {
data.selectWeapon = ''
data.selectWeapon = 'All'
processPlayerWeapon()
})