updated modal-button for choice between all types of button at the initialization of the modal
This commit is contained in:
@@ -11,7 +11,7 @@
|
||||
<tr>
|
||||
<td>{{data.transporter}}</td>
|
||||
<td>
|
||||
<app-modal-button name="Voir tout les bons de livraison">
|
||||
<app-modal-button type="link" name="Voir tout les bons de livraison">
|
||||
<div style="max-height: 400px; overflow-y: auto;">
|
||||
<nz-table [nzData]="data.deliveryNote">
|
||||
<thead>
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
<td>{{data.estimateDeliveryDate | date: 'dd/MM/yyyy'}}</td>
|
||||
<td>{{data.realDeliveryDate | date: 'dd/MM/yyyy'}}</td>
|
||||
<td>
|
||||
<app-modal-button name="Voir les produits">
|
||||
<app-modal-button type="link" name="Voir les produits">
|
||||
<div style="max-height: 400px; overflow-y: auto;">
|
||||
<nz-table [nzData]="data.productDelivery">
|
||||
<thead>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<button nz-button nzType="primary" (click)="showModal()">{{name()}}</button>
|
||||
<button nz-button [nzType]="type()" (click)="showModal()">{{name()}}</button>
|
||||
|
||||
<ng-template #modalContent>
|
||||
<ng-content></ng-content>
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
import {Component, input, Input} from '@angular/core';
|
||||
import {NzIconDirective} from "ng-zorro-antd/icon";
|
||||
import {NzModalComponent} from "ng-zorro-antd/modal";
|
||||
import {NzButtonComponent} from "ng-zorro-antd/button";
|
||||
|
||||
@@ -15,6 +14,7 @@ import {NzButtonComponent} from "ng-zorro-antd/button";
|
||||
|
||||
export class ModalButton {
|
||||
name = input.required<string>()
|
||||
type = input<"primary" | "default" | "dashed" | "link" | "text">()
|
||||
|
||||
isVisible = false;
|
||||
isOkLoading = false;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<app-modal-button name="Ajouter un transporteur">
|
||||
<app-modal-button type="primary" name="Ajouter un transporteur">
|
||||
<app-deliverer-form></app-deliverer-form>
|
||||
</app-modal-button>
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<app-modal-button name="Créer un devis">
|
||||
<app-modal-button type="primary" name="Créer un devis">
|
||||
<app-deliverery-note-form></app-deliverery-note-form>
|
||||
</app-modal-button>
|
||||
<div class="mt-4">
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<app-modal-button name="Ajouter un utilisateur">
|
||||
<app-modal-button type="primary" name="Ajouter un utilisateur">
|
||||
<app-profil-form></app-profil-form>
|
||||
</app-modal-button>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user