Skip to content

Commit

Permalink
fix(wms): transactionzones db schema
Browse files Browse the repository at this point in the history
  • Loading branch information
rikdepeuter authored Jan 21, 2025
1 parent 4827540 commit 1d86285
Show file tree
Hide file tree
Showing 5 changed files with 376 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ public class OverlappingTransactionZonesRecordConfiguration : IEntityTypeConfigu

public void Configure(EntityTypeBuilder<OverlappingTransactionZonesRecord> b)
{
b.ToTable(TableName, WellKnownSchemas.WmsMetaSchema)
b.ToTable(TableName, WellKnownSchemas.WmsSchema)
.HasKey(p => new { p.DownloadId1, p.DownloadId2 })
.IsClustered();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ public class TransactionZoneRecordConfiguration : IEntityTypeConfiguration<Trans

public void Configure(EntityTypeBuilder<TransactionZoneRecord> b)
{
b.ToTable(TableName, WellKnownSchemas.WmsMetaSchema)
b.ToTable(TableName, WellKnownSchemas.WmsSchema)
.HasKey(p => p.DownloadId)
.IsClustered();

Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
using Microsoft.EntityFrameworkCore.Migrations;

#nullable disable

namespace RoadRegistry.Wms.Schema.Migrations
{
/// <inheritdoc />
public partial class FixTransactionZonesSchema : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.RenameTable(
name: "OverlappendeBijwerkingszones",
schema: "RoadRegistryWmsMeta",
newName: "OverlappendeBijwerkingszones",
newSchema: "RoadRegistryWms");

migrationBuilder.RenameTable(
name: "Bijwerkingszones",
schema: "RoadRegistryWmsMeta",
newName: "Bijwerkingszones",
newSchema: "RoadRegistryWms");
}

/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.RenameTable(
name: "OverlappendeBijwerkingszones",
schema: "RoadRegistryWms",
newName: "OverlappendeBijwerkingszones",
newSchema: "RoadRegistryWmsMeta");

migrationBuilder.RenameTable(
name: "Bijwerkingszones",
schema: "RoadRegistryWms",
newName: "Bijwerkingszones",
newSchema: "RoadRegistryWmsMeta");
}
}
}
Loading

0 comments on commit 1d86285

Please sign in to comment.