20241210094124_alteContractfixedPay.cs 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. using System;
  2. using Microsoft.EntityFrameworkCore.Migrations;
  3. #nullable disable
  4. namespace MTWorkHR.Infrastructure.Migrations
  5. {
  6. /// <inheritdoc />
  7. public partial class alteContractfixedPay : Migration
  8. {
  9. /// <inheritdoc />
  10. protected override void Up(MigrationBuilder migrationBuilder)
  11. {
  12. migrationBuilder.AddColumn<decimal>(
  13. name: "FirstPatchAmount",
  14. table: "Contracts",
  15. type: "decimal(18,2)",
  16. nullable: true);
  17. migrationBuilder.AddColumn<DateTime>(
  18. name: "FirstPatchDateFrom",
  19. table: "Contracts",
  20. type: "datetime2",
  21. nullable: true);
  22. migrationBuilder.AddColumn<DateTime>(
  23. name: "FirstPatchDateTo",
  24. table: "Contracts",
  25. type: "datetime2",
  26. nullable: true);
  27. migrationBuilder.AddColumn<decimal>(
  28. name: "LastPatchAmount",
  29. table: "Contracts",
  30. type: "decimal(18,2)",
  31. nullable: true);
  32. migrationBuilder.AddColumn<DateTime>(
  33. name: "LastPatchDateFrom",
  34. table: "Contracts",
  35. type: "datetime2",
  36. nullable: true);
  37. migrationBuilder.AddColumn<DateTime>(
  38. name: "LastPatchDateTo",
  39. table: "Contracts",
  40. type: "datetime2",
  41. nullable: true);
  42. }
  43. /// <inheritdoc />
  44. protected override void Down(MigrationBuilder migrationBuilder)
  45. {
  46. migrationBuilder.DropColumn(
  47. name: "FirstPatchAmount",
  48. table: "Contracts");
  49. migrationBuilder.DropColumn(
  50. name: "FirstPatchDateFrom",
  51. table: "Contracts");
  52. migrationBuilder.DropColumn(
  53. name: "FirstPatchDateTo",
  54. table: "Contracts");
  55. migrationBuilder.DropColumn(
  56. name: "LastPatchAmount",
  57. table: "Contracts");
  58. migrationBuilder.DropColumn(
  59. name: "LastPatchDateFrom",
  60. table: "Contracts");
  61. migrationBuilder.DropColumn(
  62. name: "LastPatchDateTo",
  63. table: "Contracts");
  64. }
  65. }
  66. }