mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
Merge pull request #2924 from gradido/fix-reset-send-coins
fix(frontend): reset button send coins
This commit is contained in:
commit
b6aa5983fe
@ -130,6 +130,7 @@ import InputEmail from '@/components/Inputs/InputEmail'
|
||||
import InputAmount from '@/components/Inputs/InputAmount'
|
||||
import InputTextarea from '@/components/Inputs/InputTextarea'
|
||||
import { user as userQuery } from '@/graphql/queries'
|
||||
import { isEmpty } from 'lodash'
|
||||
|
||||
export default {
|
||||
name: 'TransactionForm',
|
||||
@ -176,7 +177,8 @@ export default {
|
||||
this.form.amount = ''
|
||||
this.form.memo = ''
|
||||
this.$refs.formValidator.validate()
|
||||
if (this.$route.query && !this.$route.query === {}) this.$router.replace({ query: undefined })
|
||||
if (this.$route.query && !isEmpty(this.$route.query))
|
||||
this.$router.replace({ query: undefined })
|
||||
},
|
||||
},
|
||||
apollo: {
|
||||
|
||||
@ -8,11 +8,9 @@ const routerPushMock = jest.fn()
|
||||
const mocks = {
|
||||
$router: {
|
||||
push: routerPushMock,
|
||||
history: {
|
||||
current: {
|
||||
fullPath: '/transactions',
|
||||
},
|
||||
},
|
||||
},
|
||||
$route: {
|
||||
path: '/transactions',
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
@ -34,8 +34,8 @@ export default {
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
tunnelEmail() {
|
||||
if (this.$router.history.current.fullPath !== '/send') this.$router.push({ path: '/send' })
|
||||
async tunnelEmail() {
|
||||
if (this.$route.path !== '/send') await this.$router.push({ path: '/send' })
|
||||
this.$router.push({ query: { gradidoID: this.linkedUser.gradidoID } })
|
||||
},
|
||||
},
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user