i want these..!
-
when i click on submit button than get following type of data: {
"name": "bhavesh", "sttus": "true or false" }
in above object status is true if check box is checked otherwise false.
object :
tabledsta = [ { "id": "1", "name": "bhavesh", "number": "9104198297" }, { "id": "2", "name": "mihir", "number": "9154178297" } ];
<table class="table">
<thead>
<tr>
<th>id</th>
<th>name</th>
<th>number</th>
<th>select</th>
</tr>
</thead>
<tbody>
<tr *ngFor="let data of tabledsta">
<td></td>
<td ></td>
<td></td>
<td>
<input type="checkbox" class="form-check-input" (change)="handleSelected($event, data.name)"> Select
</td>
</tr>
</tbody>
</table>
<button type="button" class="btn btn-primary" (click)="submitBtn()">Submit</button>
Aucun commentaire:
Enregistrer un commentaire