mh_jy_safe/APT.Data.Migrations/Migrations/20260410064633_wyw2026041001.cs
wyw 7b755b522e 培训计划 加 触发日期
培训角色
跑批 根据 配置获取信息 如果未获取到 按原来的方式 再没获取到就跳过
触发日期 培训角色 必填
2026-04-10 16:36:17 +08:00

46 lines
1.6 KiB
C#

using System;
using Microsoft.EntityFrameworkCore.Migrations;
namespace APT.Data.Migrations.Migrations
{
public partial class wyw2026041001 : Migration
{
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.AddColumn<Guid>(
name: "APPROVAL_ROLE_ID",
table: "T_SE_TRAIN_PLAN_DETAIL",
type: "uniqueidentifier",
nullable: true);
migrationBuilder.CreateIndex(
name: "IX_T_SE_TRAIN_PLAN_DETAIL_APPROVAL_ROLE_ID",
table: "T_SE_TRAIN_PLAN_DETAIL",
column: "APPROVAL_ROLE_ID");
migrationBuilder.AddForeignKey(
name: "FK_T_SE_TRAIN_PLAN_DETAIL_T_PF_APPROVAL_ROLE_APPROVAL_ROLE_ID",
table: "T_SE_TRAIN_PLAN_DETAIL",
column: "APPROVAL_ROLE_ID",
principalTable: "T_PF_APPROVAL_ROLE",
principalColumn: "ID",
onDelete: ReferentialAction.Restrict);
}
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropForeignKey(
name: "FK_T_SE_TRAIN_PLAN_DETAIL_T_PF_APPROVAL_ROLE_APPROVAL_ROLE_ID",
table: "T_SE_TRAIN_PLAN_DETAIL");
migrationBuilder.DropIndex(
name: "IX_T_SE_TRAIN_PLAN_DETAIL_APPROVAL_ROLE_ID",
table: "T_SE_TRAIN_PLAN_DETAIL");
migrationBuilder.DropColumn(
name: "APPROVAL_ROLE_ID",
table: "T_SE_TRAIN_PLAN_DETAIL");
}
}
}