You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

52 lines
2.9 KiB

using System;
using Microsoft.EntityFrameworkCore.Migrations;
namespace Win_in.Sfs.Basedata.Migrations
{
public partial class CustomerAddress : Migration
{
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.CreateTable(
name: "Basedata_CustomerAddress",
columns: table => new
{
Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false),
Code = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Name = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: true),
CustomerCode = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Address = table.Column<string>(type: "nvarchar(1024)", maxLength: 1024, nullable: true),
Contact = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: true),
WarehouseCode = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
City = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: true),
Locationcode = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
Desc = table.Column<string>(type: "nvarchar(1024)", maxLength: 1024, nullable: true),
ExtraProperties = table.Column<string>(type: "nvarchar(max)", nullable: true),
ConcurrencyStamp = table.Column<string>(type: "nvarchar(40)", maxLength: 40, nullable: true),
CreationTime = table.Column<DateTime>(type: "datetime2", nullable: false),
CreatorId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
LastModificationTime = table.Column<DateTime>(type: "datetime2", nullable: true),
LastModifierId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
TenantId = table.Column<Guid>(type: "uniqueidentifier", nullable: true),
Remark = table.Column<string>(type: "nvarchar(1024)", maxLength: 1024, nullable: true),
Company = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false)
},
constraints: table =>
{
table.PrimaryKey("PK_Basedata_CustomerAddress", x => x.Id);
});
migrationBuilder.CreateIndex(
name: "IX_Basedata_CustomerAddress_Company_Code_CustomerCode",
table: "Basedata_CustomerAddress",
columns: new[] { "Company", "Code", "CustomerCode" },
unique: true);
}
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropTable(
name: "Basedata_CustomerAddress");
}
}
}