From 1de9d1a12695d97679c64b403c32256a4abf6ec1 Mon Sep 17 00:00:00 2001 From: maki Date: Thu, 14 Mar 2024 12:02:37 -0300 Subject: [PATCH 1/3] =?UTF-8?q?feat:=20breadcrumbs=20en=20Actividades=20de?= =?UTF-8?q?=20Moderaci=C3=B3n=20#15578?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/moderation_queue_controller.rb | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/app/controllers/moderation_queue_controller.rb b/app/controllers/moderation_queue_controller.rb index eec0c70f..ca99d95b 100644 --- a/app/controllers/moderation_queue_controller.rb +++ b/app/controllers/moderation_queue_controller.rb @@ -2,6 +2,11 @@ # Cola de moderación de ActivityPub class ModerationQueueController < ApplicationController + before_action :authenticate_usuarie! + + breadcrumb -> { current_usuarie.email }, :edit_usuarie_registration_path + breadcrumb 'sites.index', :sites_path, match: :exact + # Cola de moderación viendo todo el sitio def index dummy_data From 33cfdd199513221c8b4bf30f64fbe0b454c4be7a Mon Sep 17 00:00:00 2001 From: maki Date: Thu, 14 Mar 2024 12:21:50 -0300 Subject: [PATCH 2/3] fix: breadcrumbs en todas las acciones --- app/controllers/moderation_queue_controller.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/controllers/moderation_queue_controller.rb b/app/controllers/moderation_queue_controller.rb index ca99d95b..cbf2cec5 100644 --- a/app/controllers/moderation_queue_controller.rb +++ b/app/controllers/moderation_queue_controller.rb @@ -6,7 +6,7 @@ class ModerationQueueController < ApplicationController breadcrumb -> { current_usuarie.email }, :edit_usuarie_registration_path breadcrumb 'sites.index', :sites_path, match: :exact - + # Cola de moderación viendo todo el sitio def index dummy_data @@ -15,11 +15,13 @@ class ModerationQueueController < ApplicationController # Perfil remoto de usuarie def remote_profile dummy_data + breadcrumb post.title.value, '' end # todon.nl está usando /api/v2/instance # mauve.moe usa /api/v1/instance def instances dummy_data + breadcrumb post.title.value, '' end end From 8473927ceed6ea7dc8d01c30856499fcd200e998 Mon Sep 17 00:00:00 2001 From: maki Date: Fri, 15 Mar 2024 12:23:04 -0300 Subject: [PATCH 3/3] fix: breadcrumbs --- app/controllers/moderation_queue_controller.rb | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/app/controllers/moderation_queue_controller.rb b/app/controllers/moderation_queue_controller.rb index cbf2cec5..5e501329 100644 --- a/app/controllers/moderation_queue_controller.rb +++ b/app/controllers/moderation_queue_controller.rb @@ -10,18 +10,17 @@ class ModerationQueueController < ApplicationController # Cola de moderación viendo todo el sitio def index dummy_data + breadcrumb I18n.t('moderation_queue.index.title'), '' end # Perfil remoto de usuarie def remote_profile dummy_data - breadcrumb post.title.value, '' end # todon.nl está usando /api/v2/instance # mauve.moe usa /api/v1/instance def instances dummy_data - breadcrumb post.title.value, '' end end