Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Rolf Erik Sesseng Aas
tdt4242-base
Commits
1147b2e9
Commit
1147b2e9
authored
Apr 19, 2021
by
ibooking-sigurd
Browse files
Merge branch 'Refactor' of gitlab.stud.idi.ntnu.no:reaas/tdt4242-base into Refactor
parents
e2d7b5dd
1111868e
Changes
2
Hide whitespace changes
Inline
Side-by-side
frontend/www/myathletes.html
View file @
1147b2e9
...
...
@@ -52,7 +52,7 @@
</div>
<div
class=
"row"
>
<div
id=
"list-diets-div"
class=
"col"
>
<i
class=
"fas fa-utensils"
></i>
<i
class=
"fas fa-utensils"
aria-hidden=
"true"
></i>
<label
for=
"list-diet-tab"
class=
"form-label"
>
Diets
</label>
</div>
</div>
...
...
@@ -71,7 +71,7 @@
<div
class=
"entry input-group"
>
<input
class=
"form-control"
name=
"athlete"
type=
"text"
/>
<button
class=
"btn btn-danger btn-remove"
type=
"button"
>
<i
class=
"fas fa-minus"
></i>
<i
class=
"fas fa-minus"
aria-hidden=
"true"
></i>
</button>
</span>
</div>
...
...
@@ -81,7 +81,7 @@
<div
class=
"entry input-group"
>
<input
class=
"form-control"
name=
"athlete"
type=
"text"
/>
<button
class=
"btn btn-success btn-add"
type=
"button"
>
<i
class=
"fas fa-plus"
></i>
<i
class=
"fas fa-plus"
aria-hidden=
"true"
></i>
</button>
</span>
</div>
...
...
@@ -139,7 +139,7 @@
<div
class=
"entry input-group"
>
<input
class=
"form-control"
name=
"athlete-no-diet"
type=
"text"
/>
<button
class=
"btn btn-success btn-add-diet"
type=
"button"
>
<i
class=
"fas fa-utensils"
></i>
<i
class=
"fas fa-utensils"
aria-hidden=
"true"
></i>
</button>
<div
class=
"tab-pane fade"
role=
"tabpanel"
>
...
...
frontend/www/scripts/mealtype.js
View file @
1147b2e9
...
...
@@ -132,8 +132,8 @@ window.addEventListener("DOMContentLoaded", async () => {
await
retrieveMealtype
(
mealtypeId
);
editButton
.
addEventListener
(
"
click
"
,
handleEditMealtypeButtonClick
);
deleteButton
.
addEventListener
(
"
click
"
,
(
async
(
id
)
=>
await
deleteMealtype
(
id
)).
bind
(
undefined
,
mealtypeId
));
okButton
.
addEventListener
(
"
click
"
,
(
async
(
id
)
=>
await
updateMealtype
(
id
)).
bind
(
undefined
,
mealtypeId
));
deleteButton
.
addEventListener
(
"
click
"
,
(
async
(
id
)
=>
deleteMealtype
(
id
)).
bind
(
undefined
,
mealtypeId
));
okButton
.
addEventListener
(
"
click
"
,
(
async
(
id
)
=>
updateMealtype
(
id
)).
bind
(
undefined
,
mealtypeId
));
}
//create
else
{
...
...
@@ -143,7 +143,7 @@ window.addEventListener("DOMContentLoaded", async () => {
okButton
.
className
=
okButton
.
className
.
replace
(
"
hide
"
,
""
);
cancelButton
.
className
=
cancelButton
.
className
.
replace
(
"
hide
"
,
""
);
okButton
.
addEventListener
(
"
click
"
,
async
()
=>
await
createMealtype
());
okButton
.
addEventListener
(
"
click
"
,
async
()
=>
createMealtype
());
cancelButton
.
addEventListener
(
"
click
"
,
handleCancelButtonDuringCreate
);
}
});
\ No newline at end of file
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment