Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
AlekSIS-App-Paweljong
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Service Desk
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Teckids
Projekt Hack-n-Fun
AlekSIS-App-Paweljong
Commits
f5be7af9
Commit
f5be7af9
authored
1 month ago
by
Hangzhi Yu
Browse files
Options
Downloads
Patches
Plain Diff
Fix validation mechanism
parent
c76ea69a
No related branches found
No related tags found
1 merge request
!78
Resolve "Rewrite registration wizard"
Pipeline
#195967
passed
1 month ago
Stage: prepare
Stage: test
Stage: build
Stage: publish
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
aleksis/apps/paweljong/frontend/components/event_registration/EventRegistrationForm.vue
+24
-15
24 additions, 15 deletions
...d/components/event_registration/EventRegistrationForm.vue
with
24 additions
and
15 deletions
aleksis/apps/paweljong/frontend/components/event_registration/EventRegistrationForm.vue
+
24
−
15
View file @
f5be7af9
...
...
@@ -36,7 +36,7 @@ import SecondaryActionButton from "aleksis.core/components/generic/buttons/Secon
<v-stepper-content
v-if=
"isStepEnabled('email')"
:step=
"getStepIndex('email')"
>
<h2
class=
"text-h6 mb-4"
>
{{ $t(getStepTitleKey('email')) }}
</h2>
<div
class=
"mb-4"
>
<v-form
v-if=
"emailMode"
v-model=
"valid
"
>
<v-form
v-if=
"emailMode"
@
input=
"setValidationStatus('email', $event)
"
>
<v-row
v-if=
"emailMode == 'postbuero'"
>
<v-col>
<div
aria-required=
"true"
>
...
...
@@ -114,14 +114,14 @@ import SecondaryActionButton from "aleksis.core/components/generic/buttons/Secon
<control-row
:step=
"step"
@
set-step=
"setStep"
:next-disabled=
"!
valid
"
:next-disabled=
"!
getValidationStatus('email')
"
/>
</v-stepper-content>
<v-stepper-content
v-if=
"isStepEnabled('register')"
:step=
"getStepIndex('register')"
>
<h2
class=
"text-h6 mb-4"
>
{{ $t(getStepTitleKey("register")) }}
</h2>
<div
class=
"mb-4"
>
<v-form
v-model=
"valid
"
>
<v-form
@
input=
"setValidationStatus('register', $event)
"
>
<v-row>
<v-col>
<div
aria-required=
"true"
>
...
...
@@ -192,14 +192,14 @@ import SecondaryActionButton from "aleksis.core/components/generic/buttons/Secon
<control-row
:step=
"step"
@
set-step=
"setStep"
:next-disabled=
"!
valid
"
:next-disabled=
"!
getValidationStatus('register')
"
/>
</v-stepper-content>
<v-stepper-content
v-if=
"isStepEnabled('contact_details')"
:step=
"getStepIndex('contact_details')"
>
<h2
class=
"text-h6 mb-4"
>
{{ $t(getStepTitleKey('contact_details')) }}
</h2>
<div
class=
"mb-4"
>
<v-form
v-model=
"valid
"
>
<v-form
@
input=
"setValidationStatus('contact_details', $event)
"
>
<v-row>
<v-col
v-if=
"isFieldVisible('date_of_birth')"
>
<div
aria-required=
"true"
>
...
...
@@ -331,14 +331,14 @@ import SecondaryActionButton from "aleksis.core/components/generic/buttons/Secon
<control-row
:step=
"step"
@
set-step=
"setStep"
:next-disabled=
"!
valid
"
:next-disabled=
"!
getValidationStatus('contact_details')
"
/>
</v-stepper-content>
<v-stepper-content
:step=
"getStepIndex('guardians')"
>
<h2
class=
"text-h6 mb-4"
>
{{ $t(getStepTitleKey('guardians')) }}
</h2>
<div
class=
"mb-4"
>
<v-form
v-model=
"valid
"
>
<v-form
@
input=
"setValidationStatus('guardians', $event)
"
>
<v-card
v-for=
"(guardian, index) in data.person.guardians"
:key=
"index"
class=
"mb-4"
>
<v-card-title>
{{ $tc("paweljong.event_registration.form.steps.guardians.counter", { i: index+1 }) }}
...
...
@@ -413,14 +413,14 @@ import SecondaryActionButton from "aleksis.core/components/generic/buttons/Secon
<control-row
:step=
"step"
@
set-step=
"setStep"
:next-disabled=
"!
valid
"
:next-disabled=
"!
getValidationStatus('guardians')
"
/>
</v-stepper-content>
<v-stepper-content
:step=
"getStepIndex('additional')"
>
<h2
class=
"text-h6 mb-4"
>
{{ $t(getStepTitleKey('additional')) }}
</h2>
<div
class=
"mb-4"
>
<v-form
v-model=
"valid
"
>
<v-form
@
input=
"setValidationStatus('additional', $event)
"
>
<v-row>
<v-col>
<v-text-field
...
...
@@ -453,7 +453,7 @@ import SecondaryActionButton from "aleksis.core/components/generic/buttons/Secon
<control-row
:step=
"step"
@
set-step=
"setStep"
:next-disabled=
"!
valid
"
:next-disabled=
"!
getValidationStatus('additional')
"
/>
</v-stepper-content>
...
...
@@ -481,7 +481,7 @@ import SecondaryActionButton from "aleksis.core/components/generic/buttons/Secon
<
/tbody
>
<
/template
>
<
/v-simple-table
>
<
v
-
form
v
-
model
=
"
valid
"
>
<
v
-
form
@
input
=
"
setValidationStatus('financial', $event)
"
>
<
v
-
row
>
<
v
-
col
>
<
div
aria
-
required
=
"
true
"
>
...
...
@@ -527,7 +527,7 @@ import SecondaryActionButton from "aleksis.core/components/generic/buttons/Secon
<
control
-
row
:
step
=
"
step
"
@
set
-
step
=
"
setStep
"
:
next
-
disabled
=
"
!
valid
"
:
next
-
disabled
=
"
!
getValidationStatus('financial')
"
/>
<
/v-stepper-content
>
...
...
@@ -540,7 +540,7 @@ import SecondaryActionButton from "aleksis.core/components/generic/buttons/Secon
<
/v-card-title
>
<
v
-
card
-
text
v
-
html
=
"
term.term
"
/>
<
/v-card
>
<
v
-
form
v
-
model
=
"
valid
"
>
<
v
-
form
@
input
=
"
setValidationStatus('consent', $event)
"
>
<
div
v
-
for
=
"
term in event.terms
"
:
key
=
"
`term-checkbox-${term.id
}
`
"
aria
-
required
=
"
true
"
>
<
v
-
checkbox
required
...
...
@@ -564,7 +564,7 @@ import SecondaryActionButton from "aleksis.core/components/generic/buttons/Secon
<
control
-
row
:
step
=
"
step
"
@
set
-
step
=
"
setStep
"
:
next
-
disabled
=
"
!
valid
"
:
next
-
disabled
=
"
!
getValidationStatus('consent')
"
/>
<
/v-stepper-content
>
...
...
@@ -667,6 +667,15 @@ import SecondaryActionButton from "aleksis.core/components/generic/buttons/Secon
getStepTitleKey
(
stepName
)
{
return
this
.
steps
.
find
((
s
)
=>
s
.
name
===
stepName
)?.
titleKey
;
}
,
setValidationStatus
(
stepName
,
validationStatus
)
{
this
.
validationStatuses
[
stepName
]
=
validationStatus
;
}
,
getValidationStatus
(
stepName
)
{
if
(
this
.
validationStatuses
[
stepName
])
{
return
this
.
validationStatuses
[
stepName
];
}
return
false
;
}
,
}
,
props
:
{
slug
:
{
...
...
@@ -773,7 +782,7 @@ import SecondaryActionButton from "aleksis.core/components/generic/buttons/Secon
}
,
data
()
{
return
{
valid
:
false
,
valid
ationStatuses
:
{
}
,
eventRegistrationSent
:
false
,
step
:
1
,
emailMode
:
null
,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment