Add timely reminder button*

* Add a check in Timely command that removes the reminder button if there already is a timely reminder in DB.
* Add ReminderType in db/models. As well as migrations.
* Set Normal reminders to be of `ReminderType.User`, and Timely reminders to be of `ReminderType.Timely`
This commit is contained in:
Cata
2023-08-20 13:28:16 +00:00
committed by Kwoth
parent 3c3d082112
commit cdf9adc8a4
15 changed files with 10478 additions and 19 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,29 @@
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace NadekoBot.Db.Migrations.Sqlite
{
/// <inheritdoc />
public partial class timelyremindertype : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.AddColumn<int>(
name: "Type",
table: "Reminders",
type: "INTEGER",
nullable: false,
defaultValue: 0);
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropColumn(
name: "Type",
table: "Reminders");
}
}
}

View File

@@ -1648,6 +1648,9 @@ namespace NadekoBot.Db.Migrations.Sqlite
b.Property<ulong>("ServerId")
.HasColumnType("INTEGER");
b.Property<int>("Type")
.HasColumnType("INTEGER");
b.Property<ulong>("UserId")
.HasColumnType("INTEGER");