From d19dad3b28885137039a88d8845d80eb75615bce Mon Sep 17 00:00:00 2001 From: Jeremy Friesen Date: Tue, 8 Feb 2022 13:41:22 -0500 Subject: [PATCH] Ensuring optionally rendering dashboard listings (#16467) Relates to forem/rfcs#291, #16420, #16437, #16423, and #16461. --- app/views/dashboards/_actions.html.erb | 2 ++ app/views/dashboards/_analytics.html.erb | 2 ++ 2 files changed, 4 insertions(+) diff --git a/app/views/dashboards/_actions.html.erb b/app/views/dashboards/_actions.html.erb index 981d9fa7b..ccf285c24 100644 --- a/app/views/dashboards/_actions.html.erb +++ b/app/views/dashboards/_actions.html.erb @@ -63,12 +63,14 @@ + <%- if Listing.feature_enabled? %>
  • <%= t("views.dashboard.actions.listings") %> <%= crayons_icon_tag("external-link", class: "ml-1") %>
  • + <%- end %>
  • diff --git a/app/views/dashboards/_analytics.html.erb b/app/views/dashboards/_analytics.html.erb index 7bc18d9f3..3436bb7c9 100644 --- a/app/views/dashboards/_analytics.html.erb +++ b/app/views/dashboards/_analytics.html.erb @@ -11,10 +11,12 @@ <%= t("views.dashboard.summary.views") %> + <%- if Listing.feature_enabled? %>
    <%= @user.listings.size %> <%= t("views.dashboard.summary.listings") %>
    + <%- end %>
    <%= @user.unspent_credits_count %>