Fixed errors with price in all documents
This commit is contained in:
@@ -1,10 +0,0 @@
|
|||||||
import {Component} from '@angular/core';
|
|
||||||
|
|
||||||
@Component({
|
|
||||||
selector: 'app-product-table',
|
|
||||||
imports: [],
|
|
||||||
templateUrl: './product-table.html',
|
|
||||||
styleUrl: './product-table.css',
|
|
||||||
})
|
|
||||||
export class ProductTable {
|
|
||||||
}
|
|
||||||
@@ -16,7 +16,7 @@
|
|||||||
<tr>
|
<tr>
|
||||||
<td>{{ purchaseOrder.id }}</td>
|
<td>{{ purchaseOrder.id }}</td>
|
||||||
<td>{{ purchaseOrder.purchaseConditions }}</td>
|
<td>{{ purchaseOrder.purchaseConditions }}</td>
|
||||||
<td>Fournisseur ???</td>
|
<td>{{ purchaseOrder.supplierName }}</td>
|
||||||
<td>
|
<td>
|
||||||
<app-modal-button type="link" name="Voir les produits" size="45%">
|
<app-modal-button type="link" name="Voir les produits" size="45%">
|
||||||
<div style="max-height: 400px; overflow-y: auto;">
|
<div style="max-height: 400px; overflow-y: auto;">
|
||||||
@@ -36,7 +36,7 @@
|
|||||||
<tr>
|
<tr>
|
||||||
<td>{{ product.productName }}</td>
|
<td>{{ product.productName }}</td>
|
||||||
<td>{{ product.productReference }}</td>
|
<td>{{ product.productReference }}</td>
|
||||||
<td>{{ product.productPrice }}</td>
|
<td>{{ product.productPrice }} €</td>
|
||||||
<td>{{ product.quantity }}</td>
|
<td>{{ product.quantity }}</td>
|
||||||
<td>
|
<td>
|
||||||
<div style="justify-content: center; display: flex">
|
<div style="justify-content: center; display: flex">
|
||||||
|
|||||||
@@ -36,7 +36,7 @@
|
|||||||
<tr>
|
<tr>
|
||||||
<td>{{ product.productReference }}</td>
|
<td>{{ product.productReference }}</td>
|
||||||
<td>{{ product.productName }}</td>
|
<td>{{ product.productName }}</td>
|
||||||
<td>Price ???</td>
|
<td>{{ product.productPrice }} €</td>
|
||||||
<td>{{ product.quantity }}</td>
|
<td>{{ product.quantity }}</td>
|
||||||
<td>
|
<td>
|
||||||
<div style="justify-content: center; display: flex">
|
<div style="justify-content: center; display: flex">
|
||||||
|
|||||||
@@ -2,7 +2,6 @@ import {Component, inject, viewChild} from '@angular/core';
|
|||||||
import {StockTable} from "../../components/stock-table/stock-table";
|
import {StockTable} from "../../components/stock-table/stock-table";
|
||||||
import {Search} from "../../components/search/search";
|
import {Search} from "../../components/search/search";
|
||||||
import {ModalButton} from "../../components/modal-button/modal-button";
|
import {ModalButton} from "../../components/modal-button/modal-button";
|
||||||
import {QuotationForm} from "../../components/quotation-form/quotation-form";
|
|
||||||
import {PurchaseordersService, QuotationsService} from "../../services/api";
|
import {PurchaseordersService, QuotationsService} from "../../services/api";
|
||||||
import {NzNotificationService} from "ng-zorro-antd/notification";
|
import {NzNotificationService} from "ng-zorro-antd/notification";
|
||||||
import {firstValueFrom} from "rxjs";
|
import {firstValueFrom} from "rxjs";
|
||||||
@@ -113,12 +112,14 @@ export class Stock {
|
|||||||
);
|
);
|
||||||
this.notificationService.success('Succès', 'Devis créé');
|
this.notificationService.success('Succès', 'Devis créé');
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
console.log(this.createQuotation());
|
||||||
this.notificationService.error('Erreur', 'Erreur lors de la création du devis.');
|
this.notificationService.error('Erreur', 'Erreur lors de la création du devis.');
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
async onModalQuotationOk() {
|
async onModalQuotationOk() {
|
||||||
|
console.log(this.createQuotation().createQuotationForm.getRawValue());
|
||||||
await this.addQuotation();
|
await this.addQuotation();
|
||||||
this.createQuotation().createQuotationForm.reset();
|
this.createQuotation().createQuotationForm.reset();
|
||||||
this.modalButtonQuotation().isVisible = false;
|
this.modalButtonQuotation().isVisible = false;
|
||||||
|
|||||||
@@ -59,9 +59,9 @@ In your Angular project:
|
|||||||
|
|
||||||
```typescript
|
```typescript
|
||||||
|
|
||||||
import {ApplicationConfig} from '@angular/core';
|
import { ApplicationConfig } from '@angular/core';
|
||||||
import {provideHttpClient} from '@angular/common/http';
|
import { provideHttpClient } from '@angular/common/http';
|
||||||
import {provideApi} from '';
|
import { provideApi } from '';
|
||||||
|
|
||||||
export const appConfig: ApplicationConfig = {
|
export const appConfig: ApplicationConfig = {
|
||||||
providers: [
|
providers: [
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ import {GetPurchaseProductDto} from './get-purchase-product-dto';
|
|||||||
export interface GetPurchaseOrderDto {
|
export interface GetPurchaseOrderDto {
|
||||||
id?: number;
|
id?: number;
|
||||||
purchaseConditions?: string | null;
|
purchaseConditions?: string | null;
|
||||||
supplierId?: number;
|
supplierName?: string | null;
|
||||||
products?: Array<GetPurchaseProductDto> | null;
|
products?: Array<GetPurchaseProductDto> | null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -22,6 +22,7 @@ export interface GetQuotationProductDto {
|
|||||||
productImage?: string | null;
|
productImage?: string | null;
|
||||||
productLink?: string | null;
|
productLink?: string | null;
|
||||||
productMinimalQuantity?: number;
|
productMinimalQuantity?: number;
|
||||||
|
productPrice?: number;
|
||||||
quotationId?: number;
|
quotationId?: number;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user