change text for fromular, change disable submit

This commit is contained in:
ogerly 2022-07-11 14:54:35 +02:00
parent 4d622ee52c
commit 280f386a35
3 changed files with 37 additions and 6 deletions

View File

@ -1,6 +1,18 @@
<template>
<div class="container contribution-form">
<b-form @submit.prevent="submit">
<div class="my-3">
<h3>{{ $t('contribution.formText.h3') }}</h3>
{{ $t('contribution.formText.text1') }}
<ul class="my-3">
<li>{{ $t('contribution.formText.lastMonth') }}</li>
<li>{{ $t('contribution.formText.thisMonth') }}</li>
</ul>
<div class="my-3">
<b>{{ $t('contribution.formText.text2') }}</b>
</div>
</div>
<b-form ref="form" @submit.prevent="submit">
<label>{{ $t('time.month') }}</label>
<b-form-datepicker
v-model="form.date"
@ -16,7 +28,6 @@
<b-form-textarea
id="textarea"
v-model="form.memo"
placeholder="Enter something..."
rows="3"
max-rows="6"
required
@ -63,12 +74,18 @@ export default {
methods: {
submit() {
this.$emit('set-contribution', this.form)
this.$refs.form.reset()
this.form.date = ''
},
},
computed: {
disable() {
if (this.form.memo.length < this.minlength) return true
if (this.form.amount < 1 && this.form.amount < 1000) return true
if (
this.form.memo.length < this.minlength ||
this.form.amount === 0 ||
this.form.amount > 1000
)
return true
return false
},
},

View File

@ -35,7 +35,14 @@
"contribution": {
"activity": "Tätigkeit",
"noDateSelected": "Kein Datum ausgewählt",
"submit": "Einreichen"
"submit": "Einreichen",
"formText": {
"h3": "Deine Bedingungslose Teilhabe!",
"text1": "Du hast das Recht, dich mit deiner ganz persönlichen Gaben in die Gemeinschaft einzubringen. Honoriert werden bis zu 50 Stunden im Monat zu je 20 Gradido pro Stunde. Daraus ergibt sich das aktive Grundeinkommen von 1.000 Gradido pro Monat welches für dich geschöpft werden kann.",
"lastMonth": "Für den letzten Monat kannst du noch 200 GDD Schöpfen",
"thisMonth": "In diesem Monat kannst du noch 500 GDD Schöpfen",
"text2": "Fülle das Formular aus und beschreibe deine gemeinschaftliche Tätigkeit. Nach dem ein Moderator deiner Community deinen Beitrag bestätigt hat kann der Betrag deinem Konto gut geschrieben werden."
}
},
"contribution-link": {
"thanksYouWith": "dankt dir mit"

View File

@ -35,7 +35,14 @@
"contribution": {
"activity": "Activity",
"noDateSelected": "No date selected",
"submit": "Submit"
"submit": "Submit",
"formText": {
"h3": "Your Unconditional Participation!",
"text1": "You have the right to contribute to the community with your personal gifts. You are paid up to 50 hours per month at 20 Gradido per hour. This results in an active basic income of 1,000 gradido per month, which can be drawn for you.",
"lastMonth": "For the last month you can still scoop up 200 GDD.",
"thisMonth": "This month you can still scoop 500 GDD",
"text2": "Fill out the form and describe your community activity. After a moderator of your community has confirmed your contribution, the amount can be credited to your account."
}
},
"contribution-link": {
"thanksYouWith": "thanks you with"