When i create my modal i get a error "argument type is not assignable to parameter type ModalOptions
My code
import {Component, OnInit} from '@angular/core';
import {LoadingController, ModalController, NavParams, ToastController} from "@ionic/angular";
import {NegociosServiceService} from "../negocios-service.service";
import {ActivatedRoute} from "@angular/router";
import {ModalCalificarPage} from "../modal/modal-calificar/modal-calificar.page";
import {ModalCalificarPageModule} from "../modal/modal-calificar/modal-calificar.module";
@Component({
selector: 'app-negocio',
templateUrl: './negocio.page.html',
styleUrls: ['./negocio.page.scss'],
})
export class NegocioPage implements OnInit {
id: any;
promos: any = [];
nombre: any;
menu: any = [];
seleccion: string = "promociones";
cuponesT: any = [];
calificacion: any = {
id: "",
puntuacion: 1,
comentario: ""
}
puntuacion: any;
comentarios: any = [];
miId: any;
constructor(private negProv: NegociosServiceService,private loader:LoadingController,
private toast:ToastController,private modalController:ModalController,private activeRoute:ActivatedRoute) {
this.id=this.activeRoute.snapshot.paramMap.get('id');
this.miId = localStorage.getItem('id');
this.buscarP();
}
buscarP() {
const loader = this.loader.create({
message: "Obteniendo resultados...",
duration:300
});
this.negProv.promociones(this.id).subscribe((result) => {
if (result.estado) {
this.promos = result.promociones;
this.nombre = result.negocio;
}
});
}
buscarM() {
const loader = this.loader.create({
message: "Obteniendo resultados...",
duration:300
});
this.negProv.menu(this.id).subscribe((result) => {
if (result.estado) {
this.menu = result.menu;
}
});
}
cupones() {
const loader = this.loader.create({
message: "Obteniendo resultados...",
duration:300
});
this.negProv.cupones(this.id).subscribe((result) => {
this.cuponesT = result;
})
}
verComentarios() {
const loader = this.loader.create({
message: "Obteniendo resultados...",
duration:300
});
this.negProv.comentarios(this.id).subscribe((result) => {
this.comentarios = result.comentarios;
this.puntuacion = Number(result.promedio.toFixed(2));
})
}
async presentModal() {
const modal = await this.modalController.create({
component: ModalCalificarPage
});
}