feat: Add APIs for custom attribute definitions (#2689)
This commit is contained in:
16
db/migrate/20210722095814_add_custom_attribute_definition.rb
Normal file
16
db/migrate/20210722095814_add_custom_attribute_definition.rb
Normal file
@@ -0,0 +1,16 @@
|
||||
class AddCustomAttributeDefinition < ActiveRecord::Migration[6.0]
|
||||
def change
|
||||
create_table :custom_attribute_definitions do |t|
|
||||
t.string :attribute_display_name
|
||||
t.string :attribute_key
|
||||
t.integer :attribute_display_type, default: 0
|
||||
t.integer :default_value
|
||||
t.integer :attribute_model, default: 0
|
||||
t.references :account, index: true
|
||||
|
||||
t.timestamps
|
||||
end
|
||||
|
||||
add_index :custom_attribute_definitions, [:attribute_key, :attribute_model], unique: true, name: 'attribute_key_model_index'
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user