Ionic Modal when toggle is switched


#1

m used my university project for Ionic 3, Im added ion-toogle and im try to added ionic-toogle switched to set open modal view, but its not work please help me o fix that issue , look my code

home.html

<ion-item class="rooms-toogle" item-right > <ion-toggle value="foo" checked="true" (click)="openModal({charNum: 0})" ></ion-toggle></ion-item>
home.ts

openModal(characterNum) {
        let modal = this.modalCtrl.create(AddnewroomsopenalertPage, characterNum);
        modal.present();
      }