27 Commits

Author SHA1 Message Date
e336a50c4e Merge branch 'release/EditingDatabase' 2025-10-10 10:46:02 +02:00
e63be6e1f1 Merge branch 'feature/EditingDatabase' into develop 2025-10-10 10:37:37 +02:00
5a36c0ff2f Migration 2025-10-10 10:37:13 +02:00
014646d35c Migration 2025-10-10 10:36:58 +02:00
8371423b16 Editing Product.cs 2025-10-10 10:35:23 +02:00
f7931fbed6 Merge branch 'feature/CreatingQuotationProductDTO' into develop 2025-10-09 19:12:18 +01:00
feb12b8c3b Merge branch 'feature/CreatingPurchaseProductDTO' into develop 2025-10-09 19:11:30 +01:00
5ea5edaea6 Merge branch 'feature/CreatingProductDTO' into develop 2025-10-09 19:10:29 +01:00
aa65139b69 Merge branch 'feature/CreatingSupplierDTO' into develop 2025-10-09 19:10:03 +01:00
9be4fa67e6 Merge branch 'feature/CreatingWareHouseProductDTO' into develop 2025-10-09 19:09:25 +01:00
e69ca1898d delete productsellingprice 2025-10-09 19:06:11 +01:00
15526d1589 delete productsellingprice 2025-10-09 19:04:22 +01:00
a27cb5cf2a fix an error 2025-10-09 19:03:09 +01:00
ddbd662c2a fix an error in product attribute 2025-10-09 19:02:09 +01:00
464869e3ca Creating of all price dto 2025-10-09 19:00:55 +01:00
25d1407bd2 Creating of all product dto 2025-10-09 17:54:28 +02:00
a262fb094c Creating all supplier dto 2025-10-09 17:47:12 +02:00
f0ec7cd4d4 Fix 2025-10-09 17:43:32 +02:00
d0f20e08f0 Fix an error in Setting directory 2025-10-09 17:34:46 +02:00
b1d2d3d1a1 Creating all QuotationProductDTO 2025-10-09 17:25:48 +02:00
64fd223a63 Fix an error in PatchPurchaseProductQuantityDto.cs 2025-10-09 17:09:33 +02:00
59ddb9f7b2 Creating all WareHouseProduct DTO 2025-10-09 17:08:01 +02:00
2d42fa1017 Creating all PurchaseProduct DTO 2025-10-09 16:46:22 +02:00
b859e53f95 Creating all setting Dto 2025-10-09 16:34:12 +02:00
3cc96c4ebf Creating user Dto 2025-10-09 16:25:04 +02:00
6a813fc35a Ajouter README.md 2025-10-08 14:44:42 +02:00
a93d399942 Merge branch 'release/V1' 2025-10-08 11:47:34 +01:00
36 changed files with 2547 additions and 7 deletions

View File

@@ -0,0 +1,27 @@
namespace PyroFetes.DTO.Price.Request;
public class CreatePriceDto
{
public decimal SellingPrice { get; set; }
public int SupplierId { get; set; }
public string? SupplierName { get; set; }
public string? SupplierEmail { get; set; }
public string? SupplierPhone { get; set; }
public string? SupplierAddress { get; set; }
public int SupplierZipCode { get; set; }
public string? SupplierCity { get; set; }
public int SupplierDeliveryDelay { get; set; }
public int ProductId { get; set; }
public int ProductReferences { get; set; }
public string? ProductName { get; set; }
public decimal ProductDuration {get; set;}
public decimal ProductCaliber { get; set; }
public int ProductApprovalNumber { get; set; }
public decimal ProductWeight { get; set; }
public decimal ProductNec { get; set; }
public string? ProductImage { get; set; }
public string? ProductLink { get; set; }
public int ProductMinimalQuantity { get; set; }
}

View File

@@ -0,0 +1,7 @@
namespace PyroFetes.DTO.Price.Request;
public class PatchPriceSellingPriceDto
{
public int Id { get; set; }
public decimal SellingPrice { get; set; }
}

View File

@@ -0,0 +1,28 @@
namespace PyroFetes.DTO.Price.Request;
public class UpdatePriceDto
{
public int Id { get; set; }
public decimal SellingPrice { get; set; }
public int SupplierId { get; set; }
public string? SupplierName { get; set; }
public string? SupplierEmail { get; set; }
public string? SupplierPhone { get; set; }
public string? SupplierAddress { get; set; }
public int SupplierZipCode { get; set; }
public string? SupplierCity { get; set; }
public int SupplierDeliveryDelay { get; set; }
public int ProductId { get; set; }
public int ProductReferences { get; set; }
public string? ProductName { get; set; }
public decimal ProductDuration {get; set;}
public decimal ProductCaliber { get; set; }
public int ProductApprovalNumber { get; set; }
public decimal ProductWeight { get; set; }
public decimal ProductNec { get; set; }
public string? ProductImage { get; set; }
public string? ProductLink { get; set; }
public int ProductMinimalQuantity { get; set; }
}

View File

@@ -0,0 +1,28 @@
namespace PyroFetes.DTO.Price.Response;
public class GetPriceDto
{
public int Id { get; set; }
public decimal SellingPrice { get; set; }
public int SupplierId { get; set; }
public string? SupplierName { get; set; }
public string? SupplierEmail { get; set; }
public string? SupplierPhone { get; set; }
public string? SupplierAddress { get; set; }
public int SupplierZipCode { get; set; }
public string? SupplierCity { get; set; }
public int SupplierDeliveryDelay { get; set; }
public int ProductId { get; set; }
public int ProductReferences { get; set; }
public string? ProductName { get; set; }
public decimal ProductDuration {get; set;}
public decimal ProductCaliber { get; set; }
public int ProductApprovalNumber { get; set; }
public decimal ProductWeight { get; set; }
public decimal ProductNec { get; set; }
public string? ProductImage { get; set; }
public string? ProductLink { get; set; }
public int ProductMinimalQuantity { get; set; }
}

View File

@@ -0,0 +1,15 @@
namespace PyroFetes.DTO.Product.Request;
public class CreateProductDto
{
public int References { get; set; }
public string? Name { get; set; }
public decimal Duration {get; set;}
public decimal Caliber { get; set; }
public int ApprovalNumber { get; set; }
public decimal Weight { get; set; }
public decimal Nec { get; set; }
public string? Image { get; set; }
public string? Link { get; set; }
public int MinimalQuantity { get; set; }
}

View File

@@ -0,0 +1,7 @@
namespace PyroFetes.DTO.Product.Request;
public class PatchProductMinimalStockDto
{
public int Id { get; set; }
public int MinimalQuantity { get; set; }
}

View File

@@ -0,0 +1,16 @@
namespace PyroFetes.DTO.Product.Request;
public class UpdateProductDto
{
public int Id { get; set; }
public int References { get; set; }
public string? Name { get; set; }
public decimal Duration {get; set;}
public decimal Caliber { get; set; }
public int ApprovalNumber { get; set; }
public decimal Weight { get; set; }
public decimal Nec { get; set; }
public string? Image { get; set; }
public string? Link { get; set; }
public int MinimalQuantity { get; set; }
}

View File

@@ -0,0 +1,16 @@
namespace PyroFetes.DTO.Product.Response;
public class GetProductDto
{
public int Id { get; set; }
public int References { get; set; }
public string? Name { get; set; }
public decimal Duration {get; set;}
public decimal Caliber { get; set; }
public int ApprovalNumber { get; set; }
public decimal Weight { get; set; }
public decimal Nec { get; set; }
public string? Image { get; set; }
public string? Link { get; set; }
public int MinimalQuantity { get; set; }
}

View File

@@ -0,0 +1,22 @@
namespace PyroFetes.DTO.PurchaseProduct.Request;
public class CreatePurchaseProductDto
{
public int Quantity { get; set; }
public int ProductId { get; set; }
public int ProductReferences { get; set; }
public string? ProductName { get; set; }
public decimal ProductDuration {get; set;}
public decimal ProductCaliber { get; set; }
public int ProductApprovalNumber { get; set; }
public decimal ProductWeight { get; set; }
public decimal ProductNec { get; set; }
public string? ProductImage { get; set; }
public string? ProductLink { get; set; }
public int ProductMinimalQuantity { get; set; }
public int PurchaseOrderId { get; set; }
public string? PurchaseOrderPurchaseConditions { get; set; }
}

View File

@@ -0,0 +1,7 @@
namespace PyroFetes.DTO.PurchaseProduct.Request;
public class PatchPurchaseProductQuantityDto
{
public int Id { get; set; }
public int Quantity { get; set; }
}

View File

@@ -0,0 +1,23 @@
namespace PyroFetes.DTO.PurchaseProduct.Request;
public class UpdatePurchaseProductDto
{
public int Id { get; set; }
public int Quantity { get; set; }
public int ProductId { get; set; }
public int ProductReferences { get; set; }
public string? ProductName { get; set; }
public decimal ProductDuration {get; set;}
public decimal ProductCaliber { get; set; }
public int ProductApprovalNumber { get; set; }
public decimal ProductWeight { get; set; }
public decimal ProductNec { get; set; }
public string? ProductImage { get; set; }
public string? ProductLink { get; set; }
public int ProductMinimalQuantity { get; set; }
public int PurchaseOrderId { get; set; }
public string? PurchaseOrderPurchaseConditions { get; set; }
}

View File

@@ -0,0 +1,24 @@
namespace PyroFetes.DTO.PurchaseProduct.Response;
public class GetPurchaseProductDto
{
public int Id { get; set; }
public int Quantity { get; set; }
public int ProductId { get; set; }
public int ProductReferences { get; set; }
public string? ProductName { get; set; }
public decimal ProductDuration {get; set;}
public decimal ProductCaliber { get; set; }
public int ProductApprovalNumber { get; set; }
public decimal ProductWeight { get; set; }
public decimal ProductNec { get; set; }
public decimal ProductSellingPrice { get; set; }
public string? ProductImage { get; set; }
public string? ProductLink { get; set; }
public int ProductMinimalQuantity { get; set; }
public int PurchaseOrderId { get; set; }
public string? PurchaseOrderPurchaseConditions { get; set; }
}

View File

@@ -0,0 +1,22 @@
namespace PyroFetes.DTO.QuotationProduct.Request;
public class CreateQuotationProductDto
{
public int Quantity { get; set; }
public int QuotationId { get; set; }
public string? QuotationMessage { get; set; }
public string? QuotationConditionsSale { get; set; }
public int ProductId { get; set; }
public int ProductReferences { get; set; }
public string? ProductName { get; set; }
public decimal ProductDuration {get; set;}
public decimal ProductCaliber { get; set; }
public int ProductApprovalNumber { get; set; }
public decimal ProductWeight { get; set; }
public decimal ProductNec { get; set; }
public string? ProductImage { get; set; }
public string? ProductLink { get; set; }
public int ProductMinimalQuantity { get; set; }
}

View File

@@ -0,0 +1,7 @@
namespace PyroFetes.DTO.QuotationProduct.Request;
public class PatchQuotationProductQuantityDto
{
public int Id { get; set; }
public int Quantity { get; set; }
}

View File

@@ -0,0 +1,23 @@
namespace PyroFetes.DTO.QuotationProduct.Request;
public class UpdateQuotationProductDto
{
public int Id { get; set; }
public int Quantity { get; set; }
public int QuotationId { get; set; }
public string? QuotationMessage { get; set; }
public string? QuotationConditionsSale { get; set; }
public int ProductId { get; set; }
public int ProductReferences { get; set; }
public string? ProductName { get; set; }
public decimal ProductDuration {get; set;}
public decimal ProductCaliber { get; set; }
public int ProductApprovalNumber { get; set; }
public decimal ProductWeight { get; set; }
public decimal ProductNec { get; set; }
public string? ProductImage { get; set; }
public string? ProductLink { get; set; }
public int ProductMinimalQuantity { get; set; }
}

View File

@@ -0,0 +1,23 @@
namespace PyroFetes.DTO.QuotationProduct.Response;
public class GetQuotationProductDto
{
public int Id { get; set; }
public int Quantity { get; set; }
public int QuotationId { get; set; }
public string? QuotationMessage { get; set; }
public string? QuotationConditionsSale { get; set; }
public int ProductId { get; set; }
public int ProductReferences { get; set; }
public string? ProductName { get; set; }
public decimal ProductDuration {get; set;}
public decimal ProductCaliber { get; set; }
public int ProductApprovalNumber { get; set; }
public decimal ProductWeight { get; set; }
public decimal ProductNec { get; set; }
public string? ProductImage { get; set; }
public string? ProductLink { get; set; }
public int ProductMinimalQuantity { get; set; }
}

View File

@@ -0,0 +1,7 @@
namespace PyroFetes.DTO.SettingDTO.Request;
public class CreateSettingDto
{
public string? ElectronicSignature { get; set; }
public string? Logo { get; set; }
}

View File

@@ -0,0 +1,7 @@
namespace PyroFetes.DTO.SettingDTO.Request;
public class PatchSettingElectronicSignatureDto
{
public int Id { get; set; }
public string? ElectronicSignature { get; set; }
}

View File

@@ -0,0 +1,7 @@
namespace PyroFetes.DTO.SettingDTO.Request;
public class PatchSettingLogoDto
{
public int Id { get; set; }
public string? Logo { get; set; }
}

View File

@@ -0,0 +1,8 @@
namespace PyroFetes.DTO.SettingDTO.Response;
public class GetSettingDto
{
public int Id { get; set; }
public string? ElectronicSignature { get; set; }
public string? Logo { get; set; }
}

View File

@@ -0,0 +1,12 @@
namespace PyroFetes.DTO.Supplier.Request;
public class CreateSupplierDto
{
public string? Name { get; set; }
public string? Email { get; set; }
public string? Phone { get; set; }
public string? Address { get; set; }
public int ZipCode { get; set; }
public string? City { get; set; }
public int DeliveryDelay { get; set; }
}

View File

@@ -0,0 +1,7 @@
namespace PyroFetes.DTO.Supplier.Request;
public class PatchSupplierDeliveryDelayDto
{
public int Id { get; set; }
public int DeliveryDelay { get; set; }
}

View File

@@ -0,0 +1,13 @@
namespace PyroFetes.DTO.Supplier.Request;
public class UpdateSupplierDto
{
public int Id { get; set; }
public string? Name { get; set; }
public string? Email { get; set; }
public string? Phone { get; set; }
public string? Address { get; set; }
public int ZipCode { get; set; }
public string? City { get; set; }
public int DeliveryDelay { get; set; }
}

View File

@@ -0,0 +1,13 @@
namespace PyroFetes.DTO.Supplier.Response;
public class GetSupplierDto
{
public int Id { get; set; }
public string? Name { get; set; }
public string? Email { get; set; }
public string? Phone { get; set; }
public string? Address { get; set; }
public int ZipCode { get; set; }
public string? City { get; set; }
public int DeliveryDelay { get; set; }
}

View File

@@ -0,0 +1,10 @@
namespace PyroFetes.DTO.User.Request;
public class CreateUserDto
{
public string? Name { get; set; }
public string? Password { get; set; }
public string? Salt { get; set; }
public string? Fonction { get; set; }
public string? Email { get; set; }
}

View File

@@ -0,0 +1,10 @@
namespace PyroFetes.DTO.User.Request;
public class UpdateUserDto
{
public int Id { get; set; }
public string? Name { get; set; }
public string? Password { get; set; }
public string? Fonction { get; set; }
public string? Email { get; set; }
}

View File

@@ -0,0 +1,11 @@
namespace PyroFetes.DTO.User.Response;
public class GetUserDto
{
public int Id { get; set; }
public string? Name { get; set; }
public string? Password { get; set; }
public string? Salt { get; set; }
public string? Fonction { get; set; }
public string? Email { get; set; }
}

View File

@@ -0,0 +1,27 @@
namespace PyroFetes.DTO.WareHouseProduct.Request;
public class CreateWareHouseProductDto
{
public int Quantity { get; set; }
public int WareHouseId { get; set; }
public string? WareHouseName {get; set;}
public int WareHouseMaxWeight {get; set;}
public int WareHouseCurrent {get; set;}
public int WareHouseMinWeight {get; set;}
public string? WareHouseAddress { get; set; }
public int WareHouseZipCode { get; set; }
public string? WareHouseCity { get; set; }
public int ProductId { get; set; }
public int ProductReferences { get; set; }
public string? ProductName { get; set; }
public decimal ProductDuration {get; set;}
public decimal ProductCaliber { get; set; }
public int ProductApprovalNumber { get; set; }
public decimal ProductWeight { get; set; }
public decimal ProductNec { get; set; }
public string? ProductImage { get; set; }
public string? ProductLink { get; set; }
public int ProductMinimalQuantity { get; set; }
}

View File

@@ -0,0 +1,7 @@
namespace PyroFetes.DTO.WareHouseProduct.Request;
public class PatchWareHouseProductQuantityDto
{
public int Id { get; set; }
public int Quantity { get; set; }
}

View File

@@ -0,0 +1,28 @@
namespace PyroFetes.DTO.WareHouseProduct.Request;
public class UpdateWareHouseProductDto
{
public int Id { get; set; }
public int Quantity { get; set; }
public int WareHouseId { get; set; }
public string? WareHouseName {get; set;}
public int WareHouseMaxWeight {get; set;}
public int WareHouseCurrent {get; set;}
public int WareHouseMinWeight {get; set;}
public string? WareHouseAddress { get; set; }
public int WareHouseZipCode { get; set; }
public string? WareHouseCity { get; set; }
public int ProductId { get; set; }
public int ProductReferences { get; set; }
public string? ProductName { get; set; }
public decimal ProductDuration {get; set;}
public decimal ProductCaliber { get; set; }
public int ProductApprovalNumber { get; set; }
public decimal ProductWeight { get; set; }
public decimal ProductNec { get; set; }
public string? ProductImage { get; set; }
public string? ProductLink { get; set; }
public int ProductMinimalQuantity { get; set; }
}

View File

@@ -0,0 +1,28 @@
namespace PyroFetes.DTO.WareHouseProduct.Response;
public class GetWareHouseProductDto
{
public int Id { get; set; }
public int Quantity { get; set; }
public int WareHouseId { get; set; }
public string? WareHouseName {get; set;}
public int WareHouseMaxWeight {get; set;}
public int WareHouseCurrent {get; set;}
public int WareHouseMinWeight {get; set;}
public string? WareHouseAddress { get; set; }
public int WareHouseZipCode { get; set; }
public string? WareHouseCity { get; set; }
public int ProductId { get; set; }
public int ProductReferences { get; set; }
public string? ProductName { get; set; }
public decimal ProductDuration {get; set;}
public decimal ProductCaliber { get; set; }
public int ProductApprovalNumber { get; set; }
public decimal ProductWeight { get; set; }
public decimal ProductNec { get; set; }
public string? ProductImage { get; set; }
public string? ProductLink { get; set; }
public int ProductMinimalQuantity { get; set; }
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,52 @@
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace PyroFetes.Migrations
{
/// <inheritdoc />
public partial class FixingDatabase : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropColumn(
name: "References",
table: "Products");
migrationBuilder.DropColumn(
name: "SellingPrice",
table: "Products");
migrationBuilder.AddColumn<string>(
name: "Reference",
table: "Products",
type: "nvarchar(20)",
maxLength: 20,
nullable: false,
defaultValue: "");
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropColumn(
name: "Reference",
table: "Products");
migrationBuilder.AddColumn<int>(
name: "References",
table: "Products",
type: "int",
nullable: false,
defaultValue: 0);
migrationBuilder.AddColumn<decimal>(
name: "SellingPrice",
table: "Products",
type: "decimal(18,2)",
nullable: false,
defaultValue: 0m);
}
}
}

View File

@@ -541,11 +541,10 @@ namespace PyroFetes.Migrations
b.Property<int>("ProductCategoryId") b.Property<int>("ProductCategoryId")
.HasColumnType("int"); .HasColumnType("int");
b.Property<int>("References") b.Property<string>("Reference")
.HasColumnType("int"); .IsRequired()
.HasMaxLength(20)
b.Property<decimal>("SellingPrice") .HasColumnType("nvarchar(20)");
.HasColumnType("decimal(18,2)");
b.Property<decimal>("Weight") b.Property<decimal>("Weight")
.HasColumnType("decimal(18,2)"); .HasColumnType("decimal(18,2)");

View File

@@ -5,14 +5,13 @@ namespace PyroFetes.Models
public class Product public class Product
{ {
[Key] public int Id { get; set; } [Key] public int Id { get; set; }
[Required] public int References { get; set; } [Required, MaxLength(20)] public string? Reference { get; set; }
[Required, MaxLength(100)] public string? Name { get; set; } [Required, MaxLength(100)] public string? Name { get; set; }
[Required] public decimal Duration {get; set;} [Required] public decimal Duration {get; set;}
[Required] public decimal Caliber { get; set; } [Required] public decimal Caliber { get; set; }
[Required] public int ApprovalNumber { get; set; } [Required] public int ApprovalNumber { get; set; }
[Required] public decimal Weight { get; set; } [Required] public decimal Weight { get; set; }
[Required] public decimal Nec { get; set; } [Required] public decimal Nec { get; set; }
[Required] public decimal SellingPrice { get; set; }
[Required] public string? Image { get; set; } [Required] public string? Image { get; set; }
[Required, MaxLength(200)] public string? Link { get; set; } [Required, MaxLength(200)] public string? Link { get; set; }
[Required] public int MinimalQuantity { get; set; } [Required] public int MinimalQuantity { get; set; }

50
README.md Normal file
View File

@@ -0,0 +1,50 @@
# Gestionnaire de Stocks et Commandes
Cette application web permet de **suivre les stocks**, **automatiser les commandes fournisseurs** et **gérer le cycle complet dapprovisionnement**.
Elle est conçue pour simplifier le travail des entreprises en offrant une vue en temps réel sur les produits, leurs fournisseurs et létat des livraisons.
---
## ✨ Fonctionnalités principales
### 1⃣ Suivi et réapprovisionnement des stocks
- Définissez un **niveau minimal de stock** pour chaque produit.
- Surveillez les **niveaux en temps réel** grâce à une interface claire.
- Lorsquun produit atteint ou descend sous son seuil minimal, le système **génère automatiquement un bon de commande** pour le réapprovisionner.
### 2⃣ Gestion des fournisseurs
- Enregistrez les informations complètes des fournisseurs : nom, adresse, coordonnées, produits fournis, délais de livraison.
- **Associez un ou plusieurs fournisseurs** à chaque produit.
- Lorsquun bon de commande est créé, le système **propose automatiquement les fournisseurs appropriés**.
### 3⃣ Devis et bons de commande
- Créez des **devis personnalisés** : sélection des produits, quantités, prix, ajout dun logo, message ou conditions de vente.
- **Imprimez ou exportez** vos devis au format PDF.
- Générez des **bons de commande** en quelques clics, avec personnalisation (logo, conditions dachat) et exportation en PDF.
### 4⃣ Suivi des livraisons
- **Transformez un bon de commande en bon de livraison** dès lexpédition des produits par le fournisseur.
- Enregistrez toutes les informations importantes : date dexpédition, transporteur, numéro de suivi, date prévue et date effective de livraison.
- Recevez des **alertes en cas de retard**.
- Gérez la **réception des produits** et vérifiez leur conformité.
---
## 🗂️ Livrables prévus
- **Modèle de données** : diagramme de classes commun à tous les groupes.
- **Interface utilisateur** : maquettes ou prototypes interactifs.
- **Code source commenté** pour une meilleure compréhension.
- **Documentation technique** : description des fonctionnalités, architecture de lapplication et API.
---
## 👥 Équipe
- **Mathys**
- **Enzo**
- **Cristiano**
- **Arsène**
---
## 🚀 Objectif
Fournir un outil complet pour automatiser la gestion des stocks et des commandes, réduisant les erreurs humaines, améliorant le suivi des livraisons et facilitant la communication avec les fournisseurs.