From a5ae7f441960b8ff7f9a0875e2f5f5968fbbaeb2 Mon Sep 17 00:00:00 2001 From: ogerly Date: Thu, 15 Dec 2022 13:03:55 +0100 Subject: [PATCH] add time in contribution form --- .../Contributions/ContributionForm.vue | 14 +++++++-- .../src/components/Inputs/InputAmount.vue | 17 +++++++++- frontend/src/components/Inputs/InputTime.vue | 31 +++++++++++-------- frontend/src/validation-rules.js | 1 + 4 files changed, 47 insertions(+), 16 deletions(-) diff --git a/frontend/src/components/Contributions/ContributionForm.vue b/frontend/src/components/Contributions/ContributionForm.vue index 546e86d11..25f03812a 100644 --- a/frontend/src/components/Contributions/ContributionForm.vue +++ b/frontend/src/components/Contributions/ContributionForm.vue @@ -46,8 +46,15 @@ v-model="form.time" :name="$t('form.time')" :label="$t('form.time')" - placeholder="1" - :rules="{ required: true, gddCreationTime: [1, validMaxTime] }" + placeholder="0.5" + :rules="{ + required: true, + min: 0.5, + max: validMaxTime, + gddCreationTime: [0.5, validMaxTime], + }" + :validMaxTime="validMaxTime" + @updateAmount="updateAmount" >