Skip to content

Commit

Permalink
chore(CE): Add chatbot component_type to vc (#539)
Browse files Browse the repository at this point in the history
Co-authored-by: afthab vp <[email protected]>
  • Loading branch information
github-actions[bot] and afthabvp authored Dec 17, 2024
1 parent 7b3ed2c commit 39932be
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion server/app/models/visual_component.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ class VisualComponent < ApplicationRecord
validates :model_id, presence: true
validates :data_app_id, presence: true

enum component_type: { doughnut: 0, bar: 1, data_table: 2, visual_text: 3, custom: 4 }
enum component_type: { doughnut: 0, bar: 1, data_table: 2, visual_text: 3, custom: 4, chat_bot: 5 }

belongs_to :workspace
belongs_to :data_app
Expand Down
3 changes: 2 additions & 1 deletion server/spec/models/visual_component_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
it { should validate_presence_of(:data_app_id) }

it {
should define_enum_for(:component_type).with_values(doughnut: 0, bar: 1, data_table: 2, visual_text: 3, custom: 4)
should define_enum_for(:component_type)
.with_values(doughnut: 0, bar: 1, data_table: 2, visual_text: 3, custom: 4, chat_bot: 5)
}

it { should belong_to(:workspace) }
Expand Down

0 comments on commit 39932be

Please sign in to comment.