Skip to content

Commit

Permalink
[frontend] Introduce bootstrap feature switch
Browse files Browse the repository at this point in the history
because this is what we already exactly do.
We enable all features for Staff or Admin users.
  • Loading branch information
ChrisBr committed Jun 21, 2018
1 parent 2b05d09 commit 58f3655
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/api/app/controllers/webui/webui_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,7 @@ def render_dialog(dialog_init = nil)
end

def switch_to_webui2?
User.current && (User.current.is_admin? || User.current.is_staff?)
Feature.active?(:bootstrap)
end

def choose_layout
Expand Down
3 changes: 3 additions & 0 deletions src/api/config/feature.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,20 @@ production:
kiwi_image_editor: false
cloud_upload: false
cloud_upload_azure: false
bootstrap: false

development:
features:
<<: *default
kiwi_image_editor: true
cloud_upload: true
cloud_upload_azure: true
bootstrap: false

test:
features:
<<: *default
kiwi_image_editor: true
cloud_upload: true
cloud_upload_azure: true
bootstrap: false

0 comments on commit 58f3655

Please sign in to comment.