51 lines
1.4 KiB
C#
51 lines
1.4 KiB
C#
using Microsoft.EntityFrameworkCore.Migrations;
|
|
|
|
#nullable disable
|
|
|
|
namespace backend.Migrations
|
|
{
|
|
/// <inheritdoc />
|
|
public partial class AddKhatmItemUrl : Migration
|
|
{
|
|
/// <inheritdoc />
|
|
protected override void Up(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.AddColumn<string>(
|
|
name: "Url",
|
|
table: "KhatmItems",
|
|
type: "nvarchar(500)",
|
|
maxLength: 500,
|
|
nullable: true);
|
|
|
|
migrationBuilder.UpdateData(
|
|
table: "KhatmItems",
|
|
keyColumn: "Id",
|
|
keyValue: 1,
|
|
column: "Url",
|
|
value: "https://example.com/khatm/nadali");
|
|
|
|
migrationBuilder.UpdateData(
|
|
table: "KhatmItems",
|
|
keyColumn: "Id",
|
|
keyValue: 2,
|
|
column: "Url",
|
|
value: "https://example.com/khatm/ghadir");
|
|
|
|
migrationBuilder.UpdateData(
|
|
table: "KhatmItems",
|
|
keyColumn: "Id",
|
|
keyValue: 3,
|
|
column: "Url",
|
|
value: "https://example.com/khatm/tavassol");
|
|
}
|
|
|
|
/// <inheritdoc />
|
|
protected override void Down(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.DropColumn(
|
|
name: "Url",
|
|
table: "KhatmItems");
|
|
}
|
|
}
|
|
}
|