Skip to content

Commit

Permalink
Remove metadata
Browse files Browse the repository at this point in the history
  • Loading branch information
dmirgaleev committed Aug 23, 2023
1 parent 7b9e620 commit b642c79
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 37 deletions.

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
Expand Up @@ -129,8 +129,7 @@ protected override void Up(MigrationBuilder migrationBuilder)
RawContent = table.Column<byte[]>(type: "bytea", nullable: true),
RawType = table.Column<byte[]>(type: "bytea", nullable: true),
JsonContent = table.Column<string>(type: "jsonb", nullable: true),
JsonType = table.Column<string>(type: "jsonb", nullable: true),
Metadata = table.Column<string>(type: "jsonb", nullable: true)
JsonType = table.Column<string>(type: "jsonb", nullable: true)
},
constraints: table =>
{
Expand Down Expand Up @@ -221,13 +220,6 @@ protected override void Up(MigrationBuilder migrationBuilder)
table: "Tickets",
column: "LastLevel");

migrationBuilder.CreateIndex(
name: "IX_Tickets_Metadata",
table: "Tickets",
column: "Metadata")
.Annotation("Npgsql:IndexMethod", "gin")
.Annotation("Npgsql:IndexOperators", new[] { "jsonb_path_ops" });

migrationBuilder.CreateIndex(
name: "IX_Tickets_TicketerId",
table: "Tickets",
Expand Down
8 changes: 0 additions & 8 deletions Tzkt.Data/Migrations/TzktContextModelSnapshot.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3612,9 +3612,6 @@ protected override void BuildModel(ModelBuilder modelBuilder)
b.Property<int>("LastLevel")
.HasColumnType("integer");
b.Property<string>("Metadata")
.HasColumnType("jsonb");
b.Property<byte[]>("RawContent")
.HasColumnType("bytea");
Expand Down Expand Up @@ -3648,11 +3645,6 @@ protected override void BuildModel(ModelBuilder modelBuilder)
b.HasIndex("LastLevel");
b.HasIndex("Metadata");
NpgsqlIndexBuilderExtensions.HasMethod(b.HasIndex("Metadata"), "gin");
NpgsqlIndexBuilderExtensions.HasOperators(b.HasIndex("Metadata"), new[] { "jsonb_path_ops" });
b.HasIndex("TicketerId");
b.ToTable("Tickets");
Expand Down
11 changes: 0 additions & 11 deletions Tzkt.Data/Models/Scripts/Ticket.cs
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,6 @@ public static void BuildTicketModel(this ModelBuilder modelBuilder)
#endregion

#region props
// shadow property
modelBuilder.Entity<Ticket>()
.Property<string>("Metadata")
.HasColumnType("jsonb");

modelBuilder.Entity<Ticket>()
.Property(x => x.JsonContent)
.HasColumnType("jsonb");
Expand Down Expand Up @@ -84,12 +79,6 @@ public static void BuildTicketModel(this ModelBuilder modelBuilder)

modelBuilder.Entity<Ticket>()
.HasIndex(x => x.LastLevel);

// shadow property
modelBuilder.Entity<Ticket>()
.HasIndex("Metadata")
.HasMethod("gin")
.HasOperators("jsonb_path_ops");
#endregion
}
}
Expand Down

0 comments on commit b642c79

Please sign in to comment.