Skip to content
GitLab
Menu
Why GitLab
Pricing
Contact Sales
Explore
Why GitLab
Pricing
Contact Sales
Explore
Sign in
Get free trial
Primary navigation
Search or go to…
Project
G
GuestInfoFrontend
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Privacy statement
Keyboard shortcuts
?
What's new
6
Snippets
Groups
Projects
Show more breadcrumbs
LibreFoodPantry
Client Solutions
Theas Pantry
GuestInfoSystem
GuestInfoFrontend
Commits
3d6e549f
Commit
3d6e549f
authored
3 years ago
by
Michale Friedrich
Browse files
Options
Downloads
Patches
Plain Diff
Register Form Cleanup
parent
7f95c18c
No related branches found
No related tags found
1 merge request
!7
Integration
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/components/register-form.vue
+8
-5
8 additions, 5 deletions
src/components/register-form.vue
with
8 additions
and
5 deletions
src/components/register-form.vue
+
8
−
5
View file @
3d6e549f
...
@@ -13,11 +13,11 @@
...
@@ -13,11 +13,11 @@
<br>
<br>
<h2>
Income Sources
</h2>
<h2>
Income Sources
</h2>
<p>
Does the student receive unemployemnt benefits?
</p>
<p>
Does the student receive unemployemnt benefits?
</p>
<input
type=
"radio"
id=
"yes"
value=
"yes"
name=
"unemployementBenefit"
v-model=
"unemploymentBenefit"
required
>
<input
type=
"radio"
id=
"yes"
value=
"yes"
name=
"unemployementBenefit"
v-model=
"unemploy
e
mentBenefit"
required
>
<label
for=
"yes"
>
Yes
</label>
<label
for=
"yes"
>
Yes
</label>
<br>
<br>
<input
type=
"radio"
id=
"no"
value=
"no"
name=
"unemploymentBenefit"
v-model=
"unemploymentBenefit"
required
>
<input
type=
"radio"
id=
"no"
value=
"no"
name=
"unemploy
e
mentBenefit"
v-model=
"unemploy
e
mentBenefit"
required
>
<label
for=
"no"
>
n
o
</label>
<label
for=
"no"
>
N
o
</label>
<br>
<br>
<p>
Does the student receive any of the following? (check as many as apply):
</p>
<p>
Does the student receive any of the following? (check as many as apply):
</p>
<input
type=
"checkbox"
id=
"social_security"
value=
"social_security"
v-model=
"studentBenefits"
>
<input
type=
"checkbox"
id=
"social_security"
value=
"social_security"
v-model=
"studentBenefits"
>
...
@@ -54,7 +54,7 @@
...
@@ -54,7 +54,7 @@
<button
@
click.prevent=
"addMember"
>
Add Household Member
</button>
<button
@
click.prevent=
"addMember"
>
Add Household Member
</button>
<br>
<br>
<div
class=
"household"
v-for=
"(member,counter) in household"
v-bind:key=
"counter"
>
<div
class=
"household"
v-for=
"(member,counter) in household"
v-bind:key=
"counter"
>
<span
@
click.prevent=
"deleteMember(counter)"
></span>
<span
@
click.prevent=
"deleteMember(counter)"
>
[Click to delete]
</span>
<br>
<br>
<label
for=
"age"
>
Age of household member:
</label>
<label
for=
"age"
>
Age of household member:
</label>
<select
name=
"age"
v-model=
"member.age"
>
<select
name=
"age"
v-model=
"member.age"
>
...
@@ -79,7 +79,7 @@ export default {
...
@@ -79,7 +79,7 @@ export default {
return
{
return
{
campusStatus
:
''
,
campusStatus
:
''
,
zipCode
:
''
,
zipCode
:
''
,
unemploymentBenefit
:
''
,
unemploy
e
mentBenefit
:
''
,
studentBenefits
:
[],
studentBenefits
:
[],
assistance
:
[],
assistance
:
[],
household
:
[{
household
:
[{
...
@@ -88,15 +88,18 @@ export default {
...
@@ -88,15 +88,18 @@ export default {
}
}
},
},
methods
:
{
methods
:
{
// Send Guest Information to Backend
async
submitForm
(){
async
submitForm
(){
let
newGuestInfo
=
{
campusStatus
:
this
.
campusStatus
,
zipCode
:
this
.
zipCode
,
householdStatus
:
this
.
householdStatus
,
studentAge
:
this
.
studentAge
,
employmentStatus
:
this
.
employmentStatus
,
studentBenefits
:
this
.
studentBenifets
,
snapAssistance
:
this
.
snapAssistance
,
pounds
:
this
.
pounds
};
let
newGuestInfo
=
{
campusStatus
:
this
.
campusStatus
,
zipCode
:
this
.
zipCode
,
householdStatus
:
this
.
householdStatus
,
studentAge
:
this
.
studentAge
,
employmentStatus
:
this
.
employmentStatus
,
studentBenefits
:
this
.
studentBenifets
,
snapAssistance
:
this
.
snapAssistance
,
pounds
:
this
.
pounds
};
axios
.
post
(
"
http://localhost:10001/v0
"
,
newGuestInfo
);
axios
.
post
(
"
http://localhost:10001/v0
"
,
newGuestInfo
);
},
},
// Add household memeber to household array
addMember
()
{
addMember
()
{
this
.
household
.
push
({
this
.
household
.
push
({
age
:
''
age
:
''
})
})
},
},
// Delete household memeber from household memebr array
deleteMember
(
counter
){
deleteMember
(
counter
){
this
.
household
.
splice
(
counter
,
1
);
this
.
household
.
splice
(
counter
,
1
);
}
}
...
...
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