1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
  2. Anuncie Aqui
    Anuncie aqui você Também: fdantas@4each.com.br

Angular PrimeNG p-confirmDialog display twice

Discussão em 'Angular' iniciado por L. Kvri, Agosto 3, 2025.

  1. L. Kvri

    L. Kvri Guest

    Which is that case when the confirmation dialog displayed twice? Or with other aspect, what is the cause when a confirm dialog shown twice?

    I have a simple dialog template

    <p-confirmDialog icon="fa fa-exclamation-triangle"
    width="444"
    [closable]="false"
    key="uniqueidofdialog"
    appendTo="body"
    #dialogref>
    <p-footer>
    <button id="gemini_consentLockedByAnotherUser_btnOk"
    type="button"
    pButton
    class="button-primary"
    label="OK"
    (click)="dialogref.accept()"></button>
    </p-footer>
    </p-confirmDialog>

    private showConfirmDialog() {
    this.confirmationService.confirm({
    message: `Warning! blah-blah.`,
    header: `Warning header`,
    key: 'uniqueidofdialog',
    accept: () => {
    // TODO
    }
    });
    }


    Of course the ComfirmationService included into the provider section of the module, and the ComfirmDialogModule is imported into the import section of the module. showConfirmDialog() called once.

    What I missed?

    Thank you in advance

    Continue reading...

Compartilhe esta Página