From 29bd71cd93b03248254f341aff9252374abc74ec Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 7 Aug 2019 17:38:56 +0800 Subject: Add script to convert encoding and eof. And of course run it. --- .../20190412153003_MakeColumnsInUserNotNull.cs | 104 ++++++++++----------- 1 file changed, 52 insertions(+), 52 deletions(-) (limited to 'Timeline/Migrations/20190412153003_MakeColumnsInUserNotNull.cs') diff --git a/Timeline/Migrations/20190412153003_MakeColumnsInUserNotNull.cs b/Timeline/Migrations/20190412153003_MakeColumnsInUserNotNull.cs index 0b7b5f08..12053906 100644 --- a/Timeline/Migrations/20190412153003_MakeColumnsInUserNotNull.cs +++ b/Timeline/Migrations/20190412153003_MakeColumnsInUserNotNull.cs @@ -1,52 +1,52 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -namespace Timeline.Migrations -{ - public partial class MakeColumnsInUserNotNull : Migration - { - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.AlterColumn( - name: "roles", - table: "user", - nullable: false, - oldClrType: typeof(string), - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "name", - table: "user", - nullable: false, - oldClrType: typeof(string), - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "password", - table: "user", - nullable: false, - oldClrType: typeof(string), - oldNullable: true); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.AlterColumn( - name: "roles", - table: "user", - nullable: true, - oldClrType: typeof(string)); - - migrationBuilder.AlterColumn( - name: "name", - table: "user", - nullable: true, - oldClrType: typeof(string)); - - migrationBuilder.AlterColumn( - name: "password", - table: "user", - nullable: true, - oldClrType: typeof(string)); - } - } -} +using Microsoft.EntityFrameworkCore.Migrations; + +namespace Timeline.Migrations +{ + public partial class MakeColumnsInUserNotNull : Migration + { + protected override void Up(MigrationBuilder migrationBuilder) + { + migrationBuilder.AlterColumn( + name: "roles", + table: "user", + nullable: false, + oldClrType: typeof(string), + oldNullable: true); + + migrationBuilder.AlterColumn( + name: "name", + table: "user", + nullable: false, + oldClrType: typeof(string), + oldNullable: true); + + migrationBuilder.AlterColumn( + name: "password", + table: "user", + nullable: false, + oldClrType: typeof(string), + oldNullable: true); + } + + protected override void Down(MigrationBuilder migrationBuilder) + { + migrationBuilder.AlterColumn( + name: "roles", + table: "user", + nullable: true, + oldClrType: typeof(string)); + + migrationBuilder.AlterColumn( + name: "name", + table: "user", + nullable: true, + oldClrType: typeof(string)); + + migrationBuilder.AlterColumn( + name: "password", + table: "user", + nullable: true, + oldClrType: typeof(string)); + } + } +} -- cgit v1.2.3