diff options
author | benal01 <bja4245@rit.edu> | 2025-03-04 09:43:37 -0500 |
---|---|---|
committer | benal01 <bja4245@rit.edu> | 2025-03-04 09:43:37 -0500 |
commit | ab7aa87d3a6249352a14b5a9c3c3c9e08577657f (patch) | |
tree | 5cef39580ad1b6d8d5ca815ccf11549a76198e56 /ufund-ui/src/app/components/cupboard/cupboard.component.html | |
parent | 8e93fe31c81c4c36e66c48e7efcdbfedb1877385 (diff) | |
download | JellySolutions-ab7aa87d3a6249352a14b5a9c3c3c9e08577657f.tar.gz JellySolutions-ab7aa87d3a6249352a14b5a9c3c3c9e08577657f.tar.bz2 JellySolutions-ab7aa87d3a6249352a14b5a9c3c3c9e08577657f.zip |
cupboard component form creation and interfacing with the controller
Diffstat (limited to 'ufund-ui/src/app/components/cupboard/cupboard.component.html')
-rw-r--r-- | ufund-ui/src/app/components/cupboard/cupboard.component.html | 32 |
1 files changed, 18 insertions, 14 deletions
diff --git a/ufund-ui/src/app/components/cupboard/cupboard.component.html b/ufund-ui/src/app/components/cupboard/cupboard.component.html index ad8e60c..b87540e 100644 --- a/ufund-ui/src/app/components/cupboard/cupboard.component.html +++ b/ufund-ui/src/app/components/cupboard/cupboard.component.html @@ -1,17 +1,21 @@ <h1> Cupboard </h1> -<form> - <label for="name">Name:</label><br> - <input #name type="text" name="name"><br> - <label for="id">Id:</label><br> - <input #id type="number" name="id"><br> - <label for="max-goal">Max Goal:</label><br> - <input #maxgoal type="number" name="max-goal"><br> - <label>Type</label><br> - <input id="monetary" type="radio" name="type" value="MONETARY"> - <label for="monetary">Monetary</label><br> - <input #physical type="radio" name="type" value="PHYSICAL"> - <label for="physical">Physical</label><br> -</form> -<button (click)="submit(name.value, id.valueAsNumber, maxgoal.valueAsNumber, physical.value)">Submit</button> +<div id="create-form"> + <h1> Create a new need </h1> + <form #cupboardForm="ngForm" (ngSubmit)="submit(cupboardForm.value)"> + <label>Name:</label><br> + <input type="text" name="name" ngModel><br> + <label>Id:</label><br> + <input type="number" name="id" ngModel><br> + <label>Max Goal:</label><br> + <input type="number" name="maxGoal" ngModel><br> + <label>Type</label><br> + <input type="radio" name="type" value="MONETARY" ngModel> + <label>Monetary</label><br> + <input type="radio" name="type" value="PHYSICAL" ngModel> + <label>Physical</label><br> + <input type="submit" value="Submit"> + </form> +</div> + <app-need-list></app-need-list> |