20230207162914_AddTable.cs 1.0 KB

1234567891011121314151617181920212223242526272829303132
  1. using System;
  2. using Microsoft.EntityFrameworkCore.Migrations;
  3. namespace Repository.Migrations
  4. {
  5. public partial class AddTable : Migration
  6. {
  7. protected override void Up(MigrationBuilder migrationBuilder)
  8. {
  9. migrationBuilder.CreateTable(
  10. name: "ProductResult",
  11. columns: table => new
  12. {
  13. Id = table.Column<Guid>(nullable: false),
  14. Result = table.Column<double>(nullable: false),
  15. Datetime = table.Column<DateTime>(nullable: false),
  16. Barcode = table.Column<string>(nullable: true),
  17. Juge = table.Column<int>(nullable: false)
  18. },
  19. constraints: table =>
  20. {
  21. table.PrimaryKey("PK_ProductResult", x => x.Id);
  22. });
  23. }
  24. protected override void Down(MigrationBuilder migrationBuilder)
  25. {
  26. migrationBuilder.DropTable(
  27. name: "ProductResult");
  28. }
  29. }
  30. }