Add tabnav, dedicated auths view to RS service page

Includes a nicer view and illustration for when no auths exist yet
This commit is contained in:
2024-08-14 13:34:32 +02:00
parent 54b01dd282
commit 171b84ee81
7 changed files with 86 additions and 13 deletions

View File

@@ -8,8 +8,7 @@ class Services::RemotestorageController < Services::BaseController
# unless current_user.service_enabled?(:remotestorage)
# redirect_to service_remotestorage_info_path
# end
@rs_auths = current_user.remote_storage_authorizations
# TODO sort by app name
# @rs_apps_connected = current_user.remote_storage_authorizations.any?
end
private

View File

@@ -3,7 +3,12 @@ class Services::RsAuthsController < Services::BaseController
before_action :require_feature_enabled
before_action :require_service_available
# before_action :require_service_enabled
before_action :find_rs_auth
before_action :find_rs_auth, only: [:destroy, :launch_app]
def index
@rs_auths = current_user.remote_storage_authorizations
# TODO sort by app name?
end
def destroy
@auth.destroy!