mirror of
https://github.com/IT4Change/gradido.git
synced 2026-02-06 09:56:05 +00:00
fix some bugs
This commit is contained in:
parent
a36f8962e6
commit
4d69e39b57
@ -36,7 +36,7 @@
|
||||
<b-form-textarea
|
||||
id="textarea"
|
||||
v-model="form.text"
|
||||
:placeholder="$t('contributionLink.memo')"
|
||||
:placeholder="$t('moderator.notice')"
|
||||
rows="3"
|
||||
></b-form-textarea>
|
||||
</b-tab>
|
||||
@ -138,7 +138,6 @@ export default {
|
||||
this.loading = true
|
||||
let mutation
|
||||
const variables = {
|
||||
id: this.contributionId,
|
||||
resubmissionAt: this.showResubmissionDate
|
||||
? this.combineResubmissionDateAndTime().toString()
|
||||
: null,
|
||||
@ -146,6 +145,7 @@ export default {
|
||||
// update only resubmission date?
|
||||
if (this.form.text === '' && this.form.memo === this.contributionMemo) {
|
||||
mutation = adminUpdateContribution
|
||||
variables.id = this.contributionId
|
||||
}
|
||||
// update tabindex 0 = dialog or 1 = moderator
|
||||
else if (this.tabindex !== 2) {
|
||||
@ -153,10 +153,12 @@ export default {
|
||||
variables.message = this.form.text
|
||||
variables.messageType =
|
||||
this.tabindex === 0 ? this.messageType.DIALOG : this.messageType.MODERATOR
|
||||
variables.contributionId = this.contributionId
|
||||
// update contribution memo
|
||||
} else {
|
||||
mutation = adminUpdateContribution
|
||||
variables.memo = this.form.memo
|
||||
variables.id = this.contributionId
|
||||
}
|
||||
this.$apollo
|
||||
.mutate({ mutation, variables })
|
||||
|
||||
@ -119,7 +119,7 @@
|
||||
"notice-tooltip": "Die Notiz ist nur für Moderatoren sichtbar",
|
||||
"memo": "Text ändern",
|
||||
"memo-tooltip": "Den Beitragstext bearbeiten",
|
||||
"memo-modified": "Memo vom Moderator bearbeitet",
|
||||
"memo-modified": "Text vom Moderator bearbeitet.",
|
||||
"message": "Nachricht",
|
||||
"message-tooltip": "Nachricht an Benutzer schreiben",
|
||||
"request": "Diese Nachricht ist nur für die Moderatoren sichtbar!"
|
||||
|
||||
@ -119,7 +119,7 @@
|
||||
"notice-tooltip": "The note is only visible to moderators",
|
||||
"memo": "Edit text",
|
||||
"memo-tooltip": "Edit the text of the contribution",
|
||||
"memo-modified": "Memo edited by moderator",
|
||||
"memo-modified": "Text edited by moderator",
|
||||
"message": "Message",
|
||||
"message-tooltip": "Write message to user",
|
||||
"request": "This message is only visible to the moderators!"
|
||||
|
||||
@ -157,7 +157,7 @@ export class ContributionMessageResolver {
|
||||
)
|
||||
}
|
||||
if (contributionMessage) {
|
||||
await transactionalEntityManager.insert(ContributionMessage, contributionMessage)
|
||||
await transactionalEntityManager.insert(DbContributionMessage, contributionMessage)
|
||||
}
|
||||
finalContribution = contribution
|
||||
finalContributionMessage = contributionMessage
|
||||
|
||||
@ -25,7 +25,7 @@ export class UnconfirmedContributionAdminRole extends AbstractUnconfirmedContrib
|
||||
|
||||
/**
|
||||
*
|
||||
* @returns true if memo, amount and creation date are not changed at all
|
||||
* @returns true if memo, amount or creation date are changed
|
||||
*/
|
||||
private isContributionChanging(): boolean {
|
||||
if (this.wasUpdateAlreadyCalled()) {
|
||||
@ -80,7 +80,7 @@ export class UnconfirmedContributionAdminRole extends AbstractUnconfirmedContrib
|
||||
|
||||
// creation date is currently not changeable
|
||||
if (
|
||||
this.isContributionChanging() &&
|
||||
!this.isContributionChanging() &&
|
||||
((this.self.resubmissionAt === null && newResubmissionDate === null) ||
|
||||
resubmissionNotChanged)
|
||||
) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user