Client - reset user sport preferences - fix #123
This commit is contained in:
@ -138,6 +138,12 @@
|
||||
<button :disabled="loading" @click="updateSportInEdition(null)">
|
||||
{{ $t('buttons.CANCEL') }}
|
||||
</button>
|
||||
<button
|
||||
:disabled="loading"
|
||||
@click="(e) => resetSport(e, sport.id)"
|
||||
>
|
||||
{{ $t('buttons.RESET') }}
|
||||
</button>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
@ -234,6 +240,13 @@
|
||||
sportPayload
|
||||
)
|
||||
}
|
||||
function resetSport(event: Event, sportId: number) {
|
||||
event.preventDefault()
|
||||
store.dispatch(
|
||||
AUTH_USER_STORE.ACTIONS.RESET_USER_SPORT_PREFERENCES,
|
||||
sportId
|
||||
)
|
||||
}
|
||||
|
||||
watch(
|
||||
() => loading.value,
|
||||
@ -287,6 +300,11 @@
|
||||
min-width: 80px;
|
||||
}
|
||||
}
|
||||
.sport-btn {
|
||||
display: flex;
|
||||
background: yellow;
|
||||
gap: $default-padding;
|
||||
}
|
||||
.threshold-input {
|
||||
padding: $default-padding * 0.5;
|
||||
width: 50px;
|
||||
|
Reference in New Issue
Block a user