forked from sanchezvem/PyroFetes
MAJ ajout produit
This commit is contained in:
@@ -46,5 +46,7 @@ namespace PyroFetes.DTO.Product.Request
|
|||||||
|
|
||||||
// Liste des entrepôts liés au produit venant du DTO CreateProductWarehouseDto
|
// Liste des entrepôts liés au produit venant du DTO CreateProductWarehouseDto
|
||||||
public List<CreateProductWarehouseDto>? Warehouses { get; set; }
|
public List<CreateProductWarehouseDto>? Warehouses { get; set; }
|
||||||
|
|
||||||
|
public int MovementId { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -28,7 +28,8 @@ public class CreateProductEndpoint(PyroFetesDbContext db)
|
|||||||
Image = req.Image!,
|
Image = req.Image!,
|
||||||
Link = req.Link!,
|
Link = req.Link!,
|
||||||
ProductCategoryId = req.ProductCategoryId,
|
ProductCategoryId = req.ProductCategoryId,
|
||||||
ClassificationId = req.ClassificationId
|
ClassificationId = req.ClassificationId,
|
||||||
|
MovementId = req.MovementId
|
||||||
};
|
};
|
||||||
|
|
||||||
db.Products.Add(product);
|
db.Products.Add(product);
|
||||||
|
|||||||
@@ -36,6 +36,5 @@ namespace PyroFetes.Models
|
|||||||
public List<WarehouseProduct>? WarehouseProducts { get; set; }
|
public List<WarehouseProduct>? WarehouseProducts { get; set; }
|
||||||
public List<ProductTimecode>? ProductTimecodes { get; set; }
|
public List<ProductTimecode>? ProductTimecodes { get; set; }
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -55,9 +55,9 @@ public class PyroFetesDbContext : DbContext
|
|||||||
{
|
{
|
||||||
string connectionString =
|
string connectionString =
|
||||||
"Server=romaric-thibault.fr;" +
|
"Server=romaric-thibault.fr;" +
|
||||||
"Database=PyroFetes;" +
|
"Database=Pyromana;" +
|
||||||
"User Id=pyrofetes;" +
|
"User Id=matheo;" +
|
||||||
"Password=Crablike8-Fringe-Swimmable;" +
|
"Password=Onto9-Cage-Afflicted;" +
|
||||||
"TrustServerCertificate=true;";
|
"TrustServerCertificate=true;";
|
||||||
|
|
||||||
optionsBuilder.UseSqlServer(connectionString);
|
optionsBuilder.UseSqlServer(connectionString);
|
||||||
|
|||||||
Reference in New Issue
Block a user