From 45fdef9da73373d918014e32d778e068998c3599 Mon Sep 17 00:00:00 2001 From: erio Date: Wed, 4 Mar 2026 20:20:40 +0800 Subject: [PATCH] fix: remove duplicate IdempotencyRecords declarations in ent/migrate/schema.go --- backend/ent/migrate/schema.go | 38 ----------------------------------- 1 file changed, 38 deletions(-) diff --git a/backend/ent/migrate/schema.go b/backend/ent/migrate/schema.go index 9e4bc92a..981c31d3 100644 --- a/backend/ent/migrate/schema.go +++ b/backend/ent/migrate/schema.go @@ -484,44 +484,6 @@ var ( }, }, } - // IdempotencyRecordsColumns holds the columns for the "idempotency_records" table. - IdempotencyRecordsColumns = []*schema.Column{ - {Name: "id", Type: field.TypeInt64, Increment: true}, - {Name: "created_at", Type: field.TypeTime, SchemaType: map[string]string{"postgres": "timestamptz"}}, - {Name: "updated_at", Type: field.TypeTime, SchemaType: map[string]string{"postgres": "timestamptz"}}, - {Name: "scope", Type: field.TypeString, Size: 128}, - {Name: "idempotency_key_hash", Type: field.TypeString, Size: 64}, - {Name: "request_fingerprint", Type: field.TypeString, Size: 64}, - {Name: "status", Type: field.TypeString, Size: 32}, - {Name: "response_status", Type: field.TypeInt, Nullable: true}, - {Name: "response_body", Type: field.TypeString, Nullable: true}, - {Name: "error_reason", Type: field.TypeString, Nullable: true, Size: 128}, - {Name: "locked_until", Type: field.TypeTime, Nullable: true}, - {Name: "expires_at", Type: field.TypeTime}, - } - // IdempotencyRecordsTable holds the schema information for the "idempotency_records" table. - IdempotencyRecordsTable = &schema.Table{ - Name: "idempotency_records", - Columns: IdempotencyRecordsColumns, - PrimaryKey: []*schema.Column{IdempotencyRecordsColumns[0]}, - Indexes: []*schema.Index{ - { - Name: "idempotencyrecord_scope_idempotency_key_hash", - Unique: true, - Columns: []*schema.Column{IdempotencyRecordsColumns[3], IdempotencyRecordsColumns[4]}, - }, - { - Name: "idempotencyrecord_expires_at", - Unique: false, - Columns: []*schema.Column{IdempotencyRecordsColumns[11]}, - }, - { - Name: "idempotencyrecord_status_locked_until", - Unique: false, - Columns: []*schema.Column{IdempotencyRecordsColumns[6], IdempotencyRecordsColumns[10]}, - }, - }, - } // PromoCodesColumns holds the columns for the "promo_codes" table. PromoCodesColumns = []*schema.Column{ {Name: "id", Type: field.TypeInt64, Increment: true},