Ajout de fichier modif Mathys

This commit is contained in:
2025-10-16 16:28:22 +02:00
parent 6f3c9a5fac
commit 70d47eb82b
2 changed files with 2002 additions and 0 deletions

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);
}
}
}