20220518022317_16.cs 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. using System;
  2. using Microsoft.EntityFrameworkCore.Migrations;
  3. #nullable disable
  4. namespace WCS.Service.Migrations
  5. {
  6. public partial class _16 : Migration
  7. {
  8. protected override void Up(MigrationBuilder migrationBuilder)
  9. {
  10. migrationBuilder.CreateTable(
  11. name: "WCS_TASK_OLD",
  12. columns: table => new
  13. {
  14. ID = table.Column<int>(type: "int", nullable: false)
  15. .Annotation("SqlServer:Identity", "1, 1"),
  16. BARCODE = table.Column<string>(type: "nvarchar(50)", maxLength: 50, nullable: true),
  17. TYPE = table.Column<int>(type: "int", nullable: false),
  18. STATUS = table.Column<int>(type: "int", nullable: false),
  19. ADDRFROM = table.Column<string>(type: "nvarchar(20)", maxLength: 20, nullable: true),
  20. ADDRTO = table.Column<string>(type: "nvarchar(20)", maxLength: 20, nullable: true),
  21. ADDRNEXT = table.Column<string>(type: "nvarchar(20)", maxLength: 20, nullable: true),
  22. TUNNEL = table.Column<string>(type: "nvarchar(10)", maxLength: 10, nullable: true),
  23. FLOOR = table.Column<int>(type: "int", nullable: false),
  24. DEVICE = table.Column<string>(type: "nvarchar(20)", maxLength: 20, nullable: true),
  25. SRMSTATION = table.Column<string>(type: "nvarchar(20)", maxLength: 20, nullable: true),
  26. CREATETIME = table.Column<DateTime>(type: "datetime2", nullable: false),
  27. STARTTIME = table.Column<DateTime>(type: "datetime2", nullable: true),
  28. ENDTIME = table.Column<DateTime>(type: "datetime2", nullable: true),
  29. DOCID = table.Column<int>(type: "int", nullable: false),
  30. PALLETTYPE = table.Column<short>(type: "smallint", nullable: false),
  31. PRODLINE = table.Column<short>(type: "smallint", nullable: false),
  32. FULLQTY = table.Column<short>(type: "smallint", nullable: false),
  33. HEIGHT = table.Column<short>(type: "smallint", nullable: false),
  34. WMSTASK = table.Column<int>(type: "int", nullable: false),
  35. TaskGroupKey = table.Column<string>(type: "nvarchar(max)", nullable: true),
  36. UPLOADED = table.Column<int>(type: "int", nullable: false),
  37. AgvTask = table.Column<int>(type: "int", nullable: false),
  38. Priority = table.Column<int>(type: "int", nullable: false),
  39. ManualRemarks = table.Column<string>(type: "nvarchar(max)", nullable: true),
  40. Length = table.Column<decimal>(type: "decimal(18,2)", nullable: false),
  41. ENABLED = table.Column<bool>(type: "bit", nullable: false),
  42. UPDATEUSER = table.Column<string>(type: "nvarchar(50)", maxLength: 50, nullable: false),
  43. UPDATETIME = table.Column<DateTime>(type: "datetime2", nullable: false),
  44. VER = table.Column<byte[]>(type: "rowversion", rowVersion: true, nullable: true)
  45. },
  46. constraints: table =>
  47. {
  48. table.PrimaryKey("PK_WCS_TASK_OLD", x => x.ID);
  49. });
  50. }
  51. protected override void Down(MigrationBuilder migrationBuilder)
  52. {
  53. migrationBuilder.DropTable(
  54. name: "WCS_TASK_OLD");
  55. }
  56. }
  57. }