Add group and system colors
This commit is contained in:
@@ -19,7 +19,7 @@ namespace PluralKit.Core
|
||||
internal class Database: IDatabase
|
||||
{
|
||||
private const string RootPath = "PluralKit.Core.Database"; // "resource path" root for SQL files
|
||||
private const int TargetSchemaVersion = 12;
|
||||
private const int TargetSchemaVersion = 13;
|
||||
|
||||
private readonly CoreConfig _config;
|
||||
private readonly ILogger _logger;
|
||||
|
7
PluralKit.Core/Database/Migrations/13.sql
Normal file
7
PluralKit.Core/Database/Migrations/13.sql
Normal file
@@ -0,0 +1,7 @@
|
||||
-- SCHEMA VERSION 13: 2021-03-28 --
|
||||
-- Add system and group colors --
|
||||
|
||||
alter table systems add column color char(6);
|
||||
alter table groups add column color char(6);
|
||||
|
||||
update info set schema_version = 13;
|
@@ -13,6 +13,7 @@ namespace PluralKit.Core
|
||||
public string? DisplayName { get; private set; }
|
||||
public string? Description { get; private set; }
|
||||
public string? Icon { get; private set; }
|
||||
public string? Color { get; private set; }
|
||||
|
||||
public PrivacyLevel DescriptionPrivacy { get; private set; }
|
||||
public PrivacyLevel IconPrivacy { get; private set; }
|
||||
|
@@ -14,6 +14,7 @@ namespace PluralKit.Core {
|
||||
public string Description { get; }
|
||||
public string Tag { get; }
|
||||
public string AvatarUrl { get; }
|
||||
public string Color { get; }
|
||||
public string Token { get; }
|
||||
public Instant Created { get; }
|
||||
public string UiTz { get; set; }
|
||||
|
@@ -7,6 +7,7 @@ namespace PluralKit.Core
|
||||
public Partial<string?> DisplayName { get; set; }
|
||||
public Partial<string?> Description { get; set; }
|
||||
public Partial<string?> Icon { get; set; }
|
||||
public Partial<string?> Color { get; set; }
|
||||
|
||||
public Partial<PrivacyLevel> DescriptionPrivacy { get; set; }
|
||||
public Partial<PrivacyLevel> IconPrivacy { get; set; }
|
||||
@@ -18,6 +19,7 @@ namespace PluralKit.Core
|
||||
.With("display_name", DisplayName)
|
||||
.With("description", Description)
|
||||
.With("icon", Icon)
|
||||
.With("color", Color)
|
||||
.With("description_privacy", DescriptionPrivacy)
|
||||
.With("icon_privacy", IconPrivacy)
|
||||
.With("list_privacy", ListPrivacy)
|
||||
|
@@ -7,6 +7,7 @@ namespace PluralKit.Core
|
||||
public Partial<string?> Description { get; set; }
|
||||
public Partial<string?> Tag { get; set; }
|
||||
public Partial<string?> AvatarUrl { get; set; }
|
||||
public Partial<string?> Color { get; set; }
|
||||
public Partial<string?> Token { get; set; }
|
||||
public Partial<string> UiTz { get; set; }
|
||||
public Partial<PrivacyLevel> DescriptionPrivacy { get; set; }
|
||||
@@ -22,6 +23,7 @@ namespace PluralKit.Core
|
||||
.With("description", Description)
|
||||
.With("tag", Tag)
|
||||
.With("avatar_url", AvatarUrl)
|
||||
.With("color", Color)
|
||||
.With("token", Token)
|
||||
.With("ui_tz", UiTz)
|
||||
.With("description_privacy", DescriptionPrivacy)
|
||||
|
Reference in New Issue
Block a user