using System;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace JiShe.CollectBus.EntityFrameworkCore.Migrations
{
///
public partial class Init : Migration
{
///
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.AlterDatabase()
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.CreateTable(
name: "Devices",
columns: table => new
{
Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"),
DeviceNo = table.Column(type: "longtext", nullable: false)
.Annotation("MySql:CharSet", "utf8mb4"),
DeviceStatus = table.Column(type: "int", nullable: false),
CreatorId = table.Column(type: "bigint", nullable: true),
CreationTime = table.Column(type: "datetime(6)", nullable: false),
LastModifierId = table.Column(type: "bigint", nullable: true),
LastModificationTime = table.Column(type: "datetime(6)", nullable: true)
},
constraints: table =>
{
table.PrimaryKey("PK_Devices", x => x.Id);
})
.Annotation("MySql:CharSet", "utf8mb4");
}
///
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropTable(
name: "Devices");
}
}
}