@RajuDhami wrote:
Im trying to save the button states on page reload.
Right now Im able to show hide checkin and checkout button.On page load checkin button is showing, but I would like to know if I clicked checkin it shows me checkout.
If i refresh when the button checkout was active, I want it to be on checkout.Anyway I can do this, thanks.
home.html
<ion-button *ngIf=“buttonShow” class=“buttons” color=“tertiary” type=“submit” (click)=“checkedin()”>
Check In<ion-button *ngIf=“buttonHide” class=“buttons” color=“tertiary” type=“submit”(click)=“checkedout()”>
Check OutNote: not sure why the ion-button close is not showing up in the above section while writing here.
hote.ts
buttonShow: boolean = true;
buttonHide: boolean = false;checkedin() {
let dathis.buttonShow = !this.buttonShow;
this.buttonHide = !this.buttonHide;
}checkedout() {
this.buttonShow = !this.buttonShow;
this.buttonHide = !this.buttonHide;
}
Posts: 1
Participants: 1