using System; using Microsoft.EntityFrameworkCore.Migrations; #nullable disable namespace FlexJobApi.Database.Migrations.Migrations { /// public partial class UpdateEnterpriseWallet : Migration { /// protected override void Up(MigrationBuilder migrationBuilder) { migrationBuilder.AddColumn( name: "IsFromForm", table: "Resource", type: "bit", nullable: false, defaultValue: false); migrationBuilder.CreateTable( name: "AlipayFundExpandindirectOrder", columns: table => new { Id = table.Column(type: "uniqueidentifier", nullable: false), ProductCode = table.Column(type: "nvarchar(max)", nullable: true), BizScene = table.Column(type: "nvarchar(max)", nullable: true), OutBizNo = table.Column(type: "nvarchar(max)", nullable: true), Identity = table.Column(type: "nvarchar(max)", nullable: true), IdentityType = table.Column(type: "nvarchar(max)", nullable: true), Name = table.Column(type: "nvarchar(max)", nullable: true), BizType = table.Column(type: "nvarchar(max)", nullable: true), OriginalOrderId = table.Column(type: "nvarchar(max)", nullable: true), SceneCode = table.Column(type: "nvarchar(max)", nullable: true), SceneDirections = table.Column(type: "nvarchar(max)", nullable: true), SceneImageOssUrl = table.Column(type: "nvarchar(max)", nullable: true), SceneImage = table.Column(type: "nvarchar(max)", nullable: true), SceneQualificationImageOssUrl = table.Column(type: "nvarchar(max)", nullable: true), SceneQualificationText = table.Column(type: "nvarchar(max)", nullable: true), SceneQualificationImage = table.Column(type: "nvarchar(max)", nullable: true), Sites = table.Column(type: "nvarchar(max)", nullable: true), OrderId = table.Column(type: "nvarchar(max)", nullable: true), Status = table.Column(type: "nvarchar(max)", nullable: true), TaskFinishTime = table.Column(type: "nvarchar(max)", nullable: true), RiskReviewRemark = table.Column(type: "nvarchar(max)", nullable: true), Sort = table.Column(type: "int", nullable: false), TraceId = table.Column(type: "nvarchar(max)", nullable: true), CreatedTime = table.Column(type: "datetimeoffset", nullable: false), CreatedUserId = table.Column(type: "uniqueidentifier", nullable: true), CreatedEnterpriseId = table.Column(type: "uniqueidentifier", nullable: true), UpdatedTime = table.Column(type: "datetimeoffset", nullable: true), UpdatedUserId = table.Column(type: "uniqueidentifier", nullable: true), IsDeleted = table.Column(type: "bit", nullable: false) }, constraints: table => { table.PrimaryKey("PK_AlipayFundExpandindirectOrder", x => x.Id); }); migrationBuilder.CreateTable( name: "EnterpriseWallet", columns: table => new { Id = table.Column(type: "uniqueidentifier", nullable: false), EnterpriseId = table.Column(type: "uniqueidentifier", nullable: false), Access = table.Column(type: "int", nullable: false), Sort = table.Column(type: "int", nullable: false), TraceId = table.Column(type: "nvarchar(max)", nullable: true), CreatedTime = table.Column(type: "datetimeoffset", nullable: false), CreatedUserId = table.Column(type: "uniqueidentifier", nullable: true), CreatedEnterpriseId = table.Column(type: "uniqueidentifier", nullable: true), UpdatedTime = table.Column(type: "datetimeoffset", nullable: true), UpdatedUserId = table.Column(type: "uniqueidentifier", nullable: true), IsDeleted = table.Column(type: "bit", nullable: false) }, constraints: table => { table.PrimaryKey("PK_EnterpriseWallet", x => x.Id); table.ForeignKey( name: "FK_EnterpriseWallet_Enterprise_EnterpriseId", column: x => x.EnterpriseId, principalTable: "Enterprise", principalColumn: "Id", onDelete: ReferentialAction.Cascade); }); migrationBuilder.CreateIndex( name: "IX_EnterpriseWallet_EnterpriseId", table: "EnterpriseWallet", column: "EnterpriseId"); } /// protected override void Down(MigrationBuilder migrationBuilder) { migrationBuilder.DropTable( name: "AlipayFundExpandindirectOrder"); migrationBuilder.DropTable( name: "EnterpriseWallet"); migrationBuilder.DropColumn( name: "IsFromForm", table: "Resource"); } } }