| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203 |
- using Microsoft.EntityFrameworkCore.Migrations;
- #nullable disable
- namespace Infrastructure.Migrations.AppDb
- {
- /// <inheritdoc />
- public partial class UpdateDonateAlert : Migration
- {
- /// <inheritdoc />
- protected override void Up(MigrationBuilder migrationBuilder)
- {
- migrationBuilder.RenameColumn(
- name: "ThumbnailUrl",
- table: "DonationAlertConfig",
- newName: "SoundUrl");
- migrationBuilder.RenameColumn(
- name: "Sound",
- table: "DonationAlertConfig",
- newName: "ImageUrl");
- migrationBuilder.RenameColumn(
- name: "EnableThumbnail",
- table: "DonationAlertConfig",
- newName: "EnableSound");
- migrationBuilder.AddColumn<string>(
- name: "AmountFontColor",
- table: "DonationAlertConfig",
- type: "nvarchar(20)",
- maxLength: 20,
- nullable: false,
- defaultValue: "");
- migrationBuilder.AddColumn<string>(
- name: "AmountFontFamily",
- table: "DonationAlertConfig",
- type: "nvarchar(100)",
- maxLength: 100,
- nullable: true);
- migrationBuilder.AddColumn<int>(
- name: "AmountFontSize",
- table: "DonationAlertConfig",
- type: "int",
- nullable: false,
- defaultValue: 0);
- migrationBuilder.AddColumn<bool>(
- name: "EnableImage",
- table: "DonationAlertConfig",
- type: "bit",
- nullable: false,
- defaultValue: false);
- migrationBuilder.AddColumn<int>(
- name: "MatchType",
- table: "DonationAlertConfig",
- type: "int",
- nullable: false,
- defaultValue: 0);
- migrationBuilder.AddColumn<string>(
- name: "MessageFontColor",
- table: "DonationAlertConfig",
- type: "nvarchar(20)",
- maxLength: 20,
- nullable: false,
- defaultValue: "");
- migrationBuilder.AddColumn<string>(
- name: "MessageFontFamily",
- table: "DonationAlertConfig",
- type: "nvarchar(100)",
- maxLength: 100,
- nullable: true);
- migrationBuilder.AddColumn<int>(
- name: "MessageFontSize",
- table: "DonationAlertConfig",
- type: "int",
- nullable: false,
- defaultValue: 0);
- migrationBuilder.AddColumn<string>(
- name: "NicknameFontColor",
- table: "DonationAlertConfig",
- type: "nvarchar(20)",
- maxLength: 20,
- nullable: false,
- defaultValue: "");
- migrationBuilder.AddColumn<string>(
- name: "NicknameFontFamily",
- table: "DonationAlertConfig",
- type: "nvarchar(100)",
- maxLength: 100,
- nullable: true);
- migrationBuilder.AddColumn<int>(
- name: "NicknameFontSize",
- table: "DonationAlertConfig",
- type: "int",
- nullable: false,
- defaultValue: 0);
- migrationBuilder.AddColumn<string>(
- name: "PopupEffect",
- table: "DonationAlertConfig",
- type: "nvarchar(50)",
- maxLength: 50,
- nullable: true);
- migrationBuilder.AddColumn<string>(
- name: "TextEffect",
- table: "DonationAlertConfig",
- type: "nvarchar(50)",
- maxLength: 50,
- nullable: true);
- migrationBuilder.CreateIndex(
- name: "IX_DonationAlertConfig_ChannelID_MatchType_Amount",
- table: "DonationAlertConfig",
- columns: new[] { "ChannelID", "MatchType", "Amount" });
- }
- /// <inheritdoc />
- protected override void Down(MigrationBuilder migrationBuilder)
- {
- migrationBuilder.DropIndex(
- name: "IX_DonationAlertConfig_ChannelID_MatchType_Amount",
- table: "DonationAlertConfig");
- migrationBuilder.DropColumn(
- name: "AmountFontColor",
- table: "DonationAlertConfig");
- migrationBuilder.DropColumn(
- name: "AmountFontFamily",
- table: "DonationAlertConfig");
- migrationBuilder.DropColumn(
- name: "AmountFontSize",
- table: "DonationAlertConfig");
- migrationBuilder.DropColumn(
- name: "EnableImage",
- table: "DonationAlertConfig");
- migrationBuilder.DropColumn(
- name: "MatchType",
- table: "DonationAlertConfig");
- migrationBuilder.DropColumn(
- name: "MessageFontColor",
- table: "DonationAlertConfig");
- migrationBuilder.DropColumn(
- name: "MessageFontFamily",
- table: "DonationAlertConfig");
- migrationBuilder.DropColumn(
- name: "MessageFontSize",
- table: "DonationAlertConfig");
- migrationBuilder.DropColumn(
- name: "NicknameFontColor",
- table: "DonationAlertConfig");
- migrationBuilder.DropColumn(
- name: "NicknameFontFamily",
- table: "DonationAlertConfig");
- migrationBuilder.DropColumn(
- name: "NicknameFontSize",
- table: "DonationAlertConfig");
- migrationBuilder.DropColumn(
- name: "PopupEffect",
- table: "DonationAlertConfig");
- migrationBuilder.DropColumn(
- name: "TextEffect",
- table: "DonationAlertConfig");
- migrationBuilder.RenameColumn(
- name: "SoundUrl",
- table: "DonationAlertConfig",
- newName: "ThumbnailUrl");
- migrationBuilder.RenameColumn(
- name: "ImageUrl",
- table: "DonationAlertConfig",
- newName: "Sound");
- migrationBuilder.RenameColumn(
- name: "EnableSound",
- table: "DonationAlertConfig",
- newName: "EnableThumbnail");
- }
- }
- }
|