mirror of
https://github.com/docusealco/docuseal
synced 2026-11-05 06:42:32 -05:00
add revisions
This commit is contained in:
1 parent
04ec2f8260
commit
10fd624bec
16 files changed
+462
-17
No files matched your search
@@ -0,0 +1,16 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
class CreateTemplateVersions < ActiveRecord::Migration[8.1]
|
||||
def change
|
||||
create_table :template_versions do |t|
|
||||
t.references :template, null: false, foreign_key: true, index: false
|
||||
t.references :account, null: false, foreign_key: true, index: true
|
||||
t.references :author, null: false, foreign_key: { to_table: :users }, index: true
|
||||
t.text :data, null: false
|
||||
t.string :sha1, null: false
|
||||
t.timestamps
|
||||
end
|
||||
|
||||
add_index :template_versions, %i[template_id sha1], unique: true
|
||||
end
|
||||
end
|
||||
Reference in new issue
Block a user