feat: update custom preferences endpoint
This commit is contained in:
		
							parent
							
								
									c4e39d4d59
								
							
						
					
					
						commit
						ef221b2c45
					
				
					 13 changed files with 820 additions and 20 deletions
				
			
		| 
						 | 
				
			
			@ -0,0 +1,32 @@
 | 
			
		|||
using System;
 | 
			
		||||
using System.Collections.Generic;
 | 
			
		||||
using Foxnouns.Backend.Database.Models;
 | 
			
		||||
using Microsoft.EntityFrameworkCore.Migrations;
 | 
			
		||||
 | 
			
		||||
#nullable disable
 | 
			
		||||
 | 
			
		||||
namespace Foxnouns.Backend.Database.Migrations
 | 
			
		||||
{
 | 
			
		||||
    /// <inheritdoc />
 | 
			
		||||
    public partial class AddCustomPreferences : Migration
 | 
			
		||||
    {
 | 
			
		||||
        /// <inheritdoc />
 | 
			
		||||
        protected override void Up(MigrationBuilder migrationBuilder)
 | 
			
		||||
        {
 | 
			
		||||
            migrationBuilder.AddColumn<Dictionary<Guid, User.CustomPreference>>(
 | 
			
		||||
                name: "custom_preferences",
 | 
			
		||||
                table: "users",
 | 
			
		||||
                type: "jsonb",
 | 
			
		||||
                nullable: false,
 | 
			
		||||
                defaultValueSql: "'{}'");
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        /// <inheritdoc />
 | 
			
		||||
        protected override void Down(MigrationBuilder migrationBuilder)
 | 
			
		||||
        {
 | 
			
		||||
            migrationBuilder.DropColumn(
 | 
			
		||||
                name: "custom_preferences",
 | 
			
		||||
                table: "users");
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue