This makes it easier for developers new to the codebase to easily get important information on the model's table in the same file as the model code. To ensure the model annotations stay accurate, run them on test_up/test_down. In CI, regenerate the annotations, and check for no changes, similar to how the linters work.
16 lines
486 B
Ruby
16 lines
486 B
Ruby
# frozen_string_literal: true
|
|
|
|
require_relative "../model"
|
|
|
|
class DeletedRecord < Sequel::Model
|
|
end
|
|
|
|
# Table: deleted_record
|
|
# Columns:
|
|
# id | uuid | PRIMARY KEY DEFAULT gen_random_uuid()
|
|
# deleted_at | timestamp with time zone | NOT NULL DEFAULT CURRENT_TIMESTAMP
|
|
# model_name | text | NOT NULL
|
|
# model_values | jsonb | NOT NULL DEFAULT '{}'::jsonb
|
|
# Indexes:
|
|
# deleted_record_pkey | PRIMARY KEY btree (id)
|