mirror of
https://github.com/bitwarden/server.git
synced 2025-04-24 22:32:22 -05:00
Cascade deletion for organization integration configurations (#5695)
* Cascade deletion for organization integration configurations * I always forget to format
This commit is contained in:
parent
2644efc2b7
commit
f336d959c7
@ -12,6 +12,12 @@ public class OrganizationIntegrationConfigurationEntityTypeConfiguration : IEnti
|
|||||||
.Property(oic => oic.Id)
|
.Property(oic => oic.Id)
|
||||||
.ValueGeneratedNever();
|
.ValueGeneratedNever();
|
||||||
|
|
||||||
|
builder
|
||||||
|
.HasOne(oic => oic.OrganizationIntegration)
|
||||||
|
.WithMany()
|
||||||
|
.HasForeignKey(oic => oic.OrganizationIntegrationId)
|
||||||
|
.OnDelete(DeleteBehavior.Cascade);
|
||||||
|
|
||||||
builder.ToTable(nameof(OrganizationIntegrationConfiguration));
|
builder.ToTable(nameof(OrganizationIntegrationConfiguration));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
3110
util/MySqlMigrations/Migrations/20250422201106_OICCascadeDelete.Designer.cs
generated
Normal file
3110
util/MySqlMigrations/Migrations/20250422201106_OICCascadeDelete.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,21 @@
|
|||||||
|
using Microsoft.EntityFrameworkCore.Migrations;
|
||||||
|
|
||||||
|
#nullable disable
|
||||||
|
|
||||||
|
namespace Bit.MySqlMigrations.Migrations;
|
||||||
|
|
||||||
|
/// <inheritdoc />
|
||||||
|
public partial class OICCascadeDelete : Migration
|
||||||
|
{
|
||||||
|
/// <inheritdoc />
|
||||||
|
protected override void Up(MigrationBuilder migrationBuilder)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <inheritdoc />
|
||||||
|
protected override void Down(MigrationBuilder migrationBuilder)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
3116
util/PostgresMigrations/Migrations/20250422201054_OICCascadeDelete.Designer.cs
generated
Normal file
3116
util/PostgresMigrations/Migrations/20250422201054_OICCascadeDelete.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,21 @@
|
|||||||
|
using Microsoft.EntityFrameworkCore.Migrations;
|
||||||
|
|
||||||
|
#nullable disable
|
||||||
|
|
||||||
|
namespace Bit.PostgresMigrations.Migrations;
|
||||||
|
|
||||||
|
/// <inheritdoc />
|
||||||
|
public partial class OICCascadeDelete : Migration
|
||||||
|
{
|
||||||
|
/// <inheritdoc />
|
||||||
|
protected override void Up(MigrationBuilder migrationBuilder)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <inheritdoc />
|
||||||
|
protected override void Down(MigrationBuilder migrationBuilder)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
3099
util/SqliteMigrations/Migrations/20250422201100_OICCascadeDelete.Designer.cs
generated
Normal file
3099
util/SqliteMigrations/Migrations/20250422201100_OICCascadeDelete.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,21 @@
|
|||||||
|
using Microsoft.EntityFrameworkCore.Migrations;
|
||||||
|
|
||||||
|
#nullable disable
|
||||||
|
|
||||||
|
namespace Bit.SqliteMigrations.Migrations;
|
||||||
|
|
||||||
|
/// <inheritdoc />
|
||||||
|
public partial class OICCascadeDelete : Migration
|
||||||
|
{
|
||||||
|
/// <inheritdoc />
|
||||||
|
protected override void Up(MigrationBuilder migrationBuilder)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <inheritdoc />
|
||||||
|
protected override void Down(MigrationBuilder migrationBuilder)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user