20260605114546_ExpandMemberIpAddressColumn.cs 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148
  1. using Microsoft.EntityFrameworkCore.Migrations;
  2. #nullable disable
  3. namespace Infrastructure.Migrations.AppDb
  4. {
  5. /// <inheritdoc />
  6. public partial class ExpandMemberIpAddressColumn : Migration
  7. {
  8. /// <inheritdoc />
  9. protected override void Up(MigrationBuilder migrationBuilder)
  10. {
  11. migrationBuilder.AlterColumn<string>(
  12. name: "IpAddress",
  13. table: "MemberSummaryChangeLog",
  14. type: "nvarchar(45)",
  15. maxLength: 45,
  16. nullable: true,
  17. comment: "IP Address (IPv6 호환)",
  18. oldClrType: typeof(string),
  19. oldType: "nvarchar(15)",
  20. oldMaxLength: 15,
  21. oldNullable: true,
  22. oldComment: "IP Address");
  23. migrationBuilder.AlterColumn<string>(
  24. name: "IpAddress",
  25. table: "MemberNameChangeLog",
  26. type: "nvarchar(45)",
  27. maxLength: 45,
  28. nullable: true,
  29. comment: "IP Address (IPv6 호환)",
  30. oldClrType: typeof(string),
  31. oldType: "nvarchar(15)",
  32. oldMaxLength: 15,
  33. oldNullable: true,
  34. oldComment: "IP Address");
  35. migrationBuilder.AlterColumn<string>(
  36. name: "IpAddress",
  37. table: "MemberIntroChangeLog",
  38. type: "nvarchar(45)",
  39. maxLength: 45,
  40. nullable: true,
  41. comment: "IP Address (IPv6 호환)",
  42. oldClrType: typeof(string),
  43. oldType: "nvarchar(15)",
  44. oldMaxLength: 15,
  45. oldNullable: true,
  46. oldComment: "IP Address");
  47. migrationBuilder.AlterColumn<string>(
  48. name: "SignupIP",
  49. table: "Member",
  50. type: "nvarchar(45)",
  51. maxLength: 45,
  52. nullable: true,
  53. comment: "회원가입 시 IP (IPv6 호환 — 최대 45 char)",
  54. oldClrType: typeof(string),
  55. oldType: "nvarchar(15)",
  56. oldMaxLength: 15,
  57. oldNullable: true,
  58. oldComment: "회원가입 시 IP");
  59. migrationBuilder.AlterColumn<string>(
  60. name: "LastLoginIp",
  61. table: "Member",
  62. type: "nvarchar(45)",
  63. maxLength: 45,
  64. nullable: true,
  65. comment: "마지막 로그인 IP (IPv6 호환 — 최대 45 char)",
  66. oldClrType: typeof(string),
  67. oldType: "nvarchar(15)",
  68. oldMaxLength: 15,
  69. oldNullable: true,
  70. oldComment: "마지막 로그인 IP");
  71. }
  72. /// <inheritdoc />
  73. protected override void Down(MigrationBuilder migrationBuilder)
  74. {
  75. migrationBuilder.AlterColumn<string>(
  76. name: "IpAddress",
  77. table: "MemberSummaryChangeLog",
  78. type: "nvarchar(15)",
  79. maxLength: 15,
  80. nullable: true,
  81. comment: "IP Address",
  82. oldClrType: typeof(string),
  83. oldType: "nvarchar(45)",
  84. oldMaxLength: 45,
  85. oldNullable: true,
  86. oldComment: "IP Address (IPv6 호환)");
  87. migrationBuilder.AlterColumn<string>(
  88. name: "IpAddress",
  89. table: "MemberNameChangeLog",
  90. type: "nvarchar(15)",
  91. maxLength: 15,
  92. nullable: true,
  93. comment: "IP Address",
  94. oldClrType: typeof(string),
  95. oldType: "nvarchar(45)",
  96. oldMaxLength: 45,
  97. oldNullable: true,
  98. oldComment: "IP Address (IPv6 호환)");
  99. migrationBuilder.AlterColumn<string>(
  100. name: "IpAddress",
  101. table: "MemberIntroChangeLog",
  102. type: "nvarchar(15)",
  103. maxLength: 15,
  104. nullable: true,
  105. comment: "IP Address",
  106. oldClrType: typeof(string),
  107. oldType: "nvarchar(45)",
  108. oldMaxLength: 45,
  109. oldNullable: true,
  110. oldComment: "IP Address (IPv6 호환)");
  111. migrationBuilder.AlterColumn<string>(
  112. name: "SignupIP",
  113. table: "Member",
  114. type: "nvarchar(15)",
  115. maxLength: 15,
  116. nullable: true,
  117. comment: "회원가입 시 IP",
  118. oldClrType: typeof(string),
  119. oldType: "nvarchar(45)",
  120. oldMaxLength: 45,
  121. oldNullable: true,
  122. oldComment: "회원가입 시 IP (IPv6 호환 — 최대 45 char)");
  123. migrationBuilder.AlterColumn<string>(
  124. name: "LastLoginIp",
  125. table: "Member",
  126. type: "nvarchar(15)",
  127. maxLength: 15,
  128. nullable: true,
  129. comment: "마지막 로그인 IP",
  130. oldClrType: typeof(string),
  131. oldType: "nvarchar(45)",
  132. oldMaxLength: 45,
  133. oldNullable: true,
  134. oldComment: "마지막 로그인 IP (IPv6 호환 — 최대 45 char)");
  135. }
  136. }
  137. }