Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Products] Column 'Display as' can't be hidden in the table #10500

Closed
drummer83 opened this issue Mar 1, 2023 · 5 comments
Closed

[Products] Column 'Display as' can't be hidden in the table #10500

drummer83 opened this issue Mar 1, 2023 · 5 comments
Labels
blocked bug-s5 We can live with it... Few users are impacted.

Comments

@drummer83
Copy link
Contributor

drummer83 commented Mar 1, 2023

Description

Every column in the product list can be shown or hidden using the 'columns' dropdown menu - except for 'display as'. This column is not listed in the dropdown. This applies to the old as well as the new columns dropdown menu (see screenshots).

Expected Behavior

All the columns should be available for hiding and showing.

Actual Behaviour

Column 'display as' is missing in the dropdown menu.

Steps to Reproduce

  1. Open the product list /admin/products.
  2. Look at the columns dropdown menu.

Animated Gif/Screenshot

Old dropdown:
image

New dropdown:
image

Workaround

Severity

bug-s5: we can live with it, only a few users impacted

Your Environment

  • Version used: v4.2.36
  • Browser name and version: Firefox 110.0.1 (64-bit)
  • Operating System and version (desktop or mobile): Desktop Ubuntu 20.04 LTS

Possible Fix

@drummer83 drummer83 added the bug-s5 We can live with it... Few users are impacted. label Mar 1, 2023
@vviekk
Copy link
Contributor

vviekk commented Mar 8, 2023

Seems like Display as is mapped to the same check box as Unit .

image

image

@drummer83
Copy link
Contributor Author

Ahhh, thanks @vviekk! That's a great finding.
So the question is if we really need or want it that way. It caused some confusion to me obviously. Also I see no compelling reason to link the two. Even when looking at variants instead of products:

image

Let's hear what @openfoodfoundation/train-drivers-product-owners think about this.

My proposal would be
A: to list both columns independently in the dropdown. And if there are reasons to keep the link we could maybe
B: add the 'display as' in the name of the columns dropdown:
image

@RachL
Copy link
Contributor

RachL commented Mar 8, 2023

Nice catch!

FYI this view of the product list is soon going to be legacy in favor of the new product listing see #7198

I have to dive again into this to answer properly, but I think that the new product page introduces a simplification and we won't have the "display as" column as we do now. But maybe I'm wrong and it was not made on purpose to leave this out of the design.

@mariocarabotta any chance you remember? We can have a call about it. In the meantime the user guide link to the current system: https://guide.openfoodnetwork.org/basic-features/products-1/products#adding-products

It's a powerful field, to be able to customize what the tool has done automatically but often users are confused about it.

I'm adding this issue to the BUU epic as blocked until we figure the proper solution.

@RachL RachL added the blocked label Mar 8, 2023
@vviekk
Copy link
Contributor

vviekk commented Mar 11, 2023

Also Just another side note: (perhaps this was deliberately omitted)
We don't have the translate key for 'display_as' as we have for other columns like here:

SELECTABLE_COLUMNS = [
{ label: I18n.t("admin.products_page.columns_selector.price"), value: "price" },
{ label: I18n.t("admin.products_page.columns_selector.unit"), value: "unit" },
{ label: I18n.t("admin.products_page.columns_selector.producer"), value: "producer" },
{ label: I18n.t("admin.products_page.columns_selector.category"), value: "category" },
{ label: I18n.t("admin.products_page.columns_selector.sku"), value: "sku" },
{ label: I18n.t("admin.products_page.columns_selector.on_hand"), value: "on_hand" },
{ label: I18n.t("admin.products_page.columns_selector.on_demand"), value: "on_demand" },
{ label: I18n.t("admin.products_page.columns_selector.tax_category"), value: "tax_category" },
{
label: I18n.t("admin.products_page.columns_selector.inherits_properties"),
value: "inherits_properties"
},
{ label: I18n.t("admin.products_page.columns_selector.available_on"), value: "available_on" },
{ label: I18n.t("admin.products_page.columns_selector.import_date"), value: "import_date" }
].sort do |a, b|

There are no keys:

  • admin.products_page.columns_selector.display_as
  • admin.products_page.columns.display_as

columns:
name: Name
unit: Unit
price: Price
producer: Producer
category: Category
sku: SKU
on_hand: "On Hand"
on_demand: "On Demand"
tax_category: "Tax Category"
inherits_properties: "Inherits Properties?"
available_on: "Available On"
import_date: "Import Date"
columns_selector:
unit: Unit
price: Price
producer: Producer
category: Category
sku: SKU
on_hand: "On Hand"
on_demand: "On Demand"
tax_category: "Tax Category"
inherits_properties: "Inherits Properties?"
available_on: "Available On"
import_date: "Import Date"

But there are other keys like admin.products.index.display_as.

@RachL
Copy link
Contributor

RachL commented Feb 15, 2024

I think this issue will be closed with the new design as "display as" won't be a separate column anymore, closing!

@RachL RachL closed this as completed Feb 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked bug-s5 We can live with it... Few users are impacted.
Projects
Archived in project
Development

No branches or pull requests

3 participants