mirror of
https://akkoma.dev/AkkomaGang/akkoma-fe.git
synced 2024-11-09 01:49:14 +00:00
fix changing reported status on same user
This commit is contained in:
parent
65dbf7b85d
commit
0ee0551a47
2 changed files with 9 additions and 3 deletions
|
@ -38,17 +38,23 @@ const UserReportingModal = {
|
|||
},
|
||||
statuses () {
|
||||
return this.$store.state.reports.statuses
|
||||
},
|
||||
preTickedIds () {
|
||||
return this.$store.state.reports.preTickedIds
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
userId: 'resetState'
|
||||
userId: 'resetState',
|
||||
preTickedIds (newValue) {
|
||||
this.statusIdsToReport = newValue
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
resetState () {
|
||||
// Reset state
|
||||
this.comment = ''
|
||||
this.forward = false
|
||||
this.statusIdsToReport = this.$store.state.reports.preTickedIds
|
||||
this.statusIdsToReport = this.preTickedIds
|
||||
this.processing = false
|
||||
this.error = false
|
||||
},
|
||||
|
|
|
@ -4,7 +4,7 @@ const reports = {
|
|||
state: {
|
||||
userId: null,
|
||||
statuses: [],
|
||||
preTicked: [],
|
||||
preTickedIds: [],
|
||||
modalActivated: false
|
||||
},
|
||||
mutations: {
|
||||
|
|
Loading…
Reference in a new issue