123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263 |
- using System;
- using Microsoft.EntityFrameworkCore.Migrations;
- #nullable disable
- namespace MTWorkHR.Infrastructure.Migrations
- {
- /// <inheritdoc />
- public partial class altrUserBD : Migration
- {
- /// <inheritdoc />
- protected override void Up(MigrationBuilder migrationBuilder)
- {
- migrationBuilder.AddColumn<DateTime>(
- name: "DateOfBirth",
- table: "AspNetUsers",
- type: "datetime2",
- nullable: false,
- defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified));
- migrationBuilder.AddColumn<string>(
- name: "IdNumber",
- table: "AspNetUsers",
- type: "nvarchar(max)",
- nullable: false,
- defaultValue: "");
- migrationBuilder.UpdateData(
- table: "AspNetUsers",
- keyColumn: "Id",
- keyValue: "ADMB3B92-2311-48F8-9DEC-F9FAEF1F21UA",
- columns: new[] { "DateOfBirth", "IdNumber" },
- values: new object[] { new DateTime(2000, 2, 10, 0, 0, 0, 0, DateTimeKind.Unspecified), "123" });
- migrationBuilder.UpdateData(
- table: "AspNetUsers",
- keyColumn: "Id",
- keyValue: "AL5B3B92-2311-48F8-9DEC-F9FAEF1F21UB",
- columns: new[] { "DateOfBirth", "IdNumber", "PhoneNumber" },
- values: new object[] { new DateTime(2001, 5, 13, 0, 0, 0, 0, DateTimeKind.Unspecified), "343434", "1234567888" });
- }
- /// <inheritdoc />
- protected override void Down(MigrationBuilder migrationBuilder)
- {
- migrationBuilder.DropColumn(
- name: "DateOfBirth",
- table: "AspNetUsers");
- migrationBuilder.DropColumn(
- name: "IdNumber",
- table: "AspNetUsers");
- migrationBuilder.UpdateData(
- table: "AspNetUsers",
- keyColumn: "Id",
- keyValue: "AL5B3B92-2311-48F8-9DEC-F9FAEF1F21UB",
- column: "PhoneNumber",
- value: "1234567890");
- }
- }
- }
|