Merge branch '1200-editing-a-creation-is-not-displayed-in-formular' into 1197-admin-interface-created-transactions-list

This commit is contained in:
elweyn 2021-12-20 10:47:11 +01:00
commit 9bc13c39a6

View File

@ -40,8 +40,8 @@
<b-button
variant="info"
size="md"
:class="'details_' + row.detailsShowing"
@click="editCreationUserTable(row)"
:ref="'details_edit_' + row.detailsShowing"
@click="editCreationUserTable(row, row.detailsShowing)"
class="mr-2"
>
<b-icon v-if="row.detailsShowing" icon="x" aria-label="Help"></b-icon>
@ -245,9 +245,6 @@ export default {
}
if (details) {
row.toggleDetails()
this.showCreationFormular = null
this.showConfirmRegisterMailFormular = null
this.showCreationTransactionListFormular = null
}
if (!details) {
row.toggleDetails()
@ -267,9 +264,6 @@ export default {
}
if (details) {
row.toggleDetails()
this.showCreationFormular = null
this.showConfirmRegisterMailFormular = null
this.showCreationTransactionListFormular = null
}
if (!details) {
row.toggleDetails()
@ -288,9 +282,6 @@ export default {
}
if (details) {
row.toggleDetails()
this.showCreationFormular = null
this.showConfirmRegisterMailFormular = null
this.showCreationTransactionListFormular = null
}
if (!details) {
row.toggleDetails()
@ -362,13 +353,27 @@ export default {
this.$toasted.error(error.message)
})
},
editCreationUserTable(row, rowItem) {
if (!row.detailsShowing) {
this.creationUserData = rowItem
} else {
this.creationUserData = {}
editCreationUserTable(row, details) {
if (
this.showConfirmRegisterMailFormular === true ||
this.showCreationTransactionListFormular === true
) {
this.showCreationFormular = true
this.showConfirmRegisterMailFormular = false
this.showCreationTransactionListFormular = false
return
}
if (details) {
row.toggleDetails()
}
if (!details) {
row.toggleDetails()
this.showCreationFormular = true
this.creationUserData = row.item
if (this.$refs.details_edit_true !== undefined) {
this.$refs.details_edit_true.click()
}
}
row.toggleDetails()
},
updateCreationData(data) {
this.creationUserData.amount = data.amount