lib/scrivito/ui_config.rb in scrivito_sdk-1.9.1 vs lib/scrivito/ui_config.rb in scrivito_sdk-1.10.0.rc1

- old
+ new

@@ -12,12 +12,10 @@ backend_endpoint: Configuration.endpoint, tenant: Configuration.tenant, i18n: i18n_config, is_development_mode: Rails.env.development?, resource_dialog: resource_dialog_config, - user: user_config, - user_permissions: user_permissions_config, class_datas: obj_class_config + widget_class_config, useRailsEngine: true, }.to_json end @@ -42,26 +40,9 @@ def resource_dialog_config return {} unless resource { obj: Configuration.obj_formats.fetch('_default').call(resource, editor), return_to: return_to, - } - end - - def user_permissions_config - { - create_workspace: editor.can?(:create, :workspace), - rename_workspace: editor.can?(:write, selected_workspace), - invite_to_workspace: editor.can?(:invite_to, selected_workspace), - rebase_workspace: editor.can?(:write, selected_workspace), - delete_workspace: editor.can?(:delete, selected_workspace), - publish_workspace: editor.can?(:publish, selected_workspace), - } - end - - def user_config - { - current: editor.as_json, } end def editor editing_context.editor