The list of commerce product attributes needs to display the machine names for each product attribute entity in the list (see illustration images), as is provided on the other admin UI commerce entity list pages.
All the various lists need to display the entity label/title and the entity machine name consistently. Most do currently but not all, such as the product attribute list page, where they are missing. This is particularly important for product attributes since a product catalog might include dozens/hundreds of "color" attribute lists for different products, where each product has a unique list of available colors. Similarly a product catalog might have dozens/hundreds of "size" attribute lists, clothing: s,m,l shoes: american shoe sizes, European shoe sizes, mens clothing sizes "misses" clothing sizes, "juniors" clothing sizes, tech devices with unique size lists, and on and on, which are all unique lists. Each of these requires a unique attribute list that needs individual theming as well.

Most of the other commerce entity lists show the machine names of the entities in the lists (see illustration images below), correctly. This probably needs thoroughly review across all admin GUI pages to check for consistency.
(product type list - shows machine names)

(product variation type list - shows machine names)

Please check that entity machine names are displayed in all admin GUI list pages.
| Comment | File | Size | Author |
|---|---|---|---|
| #17 | 2912910-17.patch | 809 bytes | rpayanm |
| #15 | commerce-2912910-display_name_on_product_attribute_list_page_15.patch | 804 bytes | icurk |
| #12 | Product_attributes___My_Store.png | 89.86 KB | mglaman |
| #9 | Screenshot from 2017-10-12 18-18-11.png | 107.14 KB | sorabh.v6 |
| #7 | commerce-2912910-display_name_on_product_attribute_list_page_7.patch | 821 bytes | icurk |
Comments
Comment #2
drugan commentedpossible solution:
https://patch-diff.githubusercontent.com/raw/drupalcommerce/commerce/pul...
Comment #3
mglamanThis is more of a "feature" request than bug report (improves usability, but there is nothing broken.)
Comment #4
mglamanComment #5
websiteworkspace commentedIMO, the lack of product attribute machine names is something that is very "broken"/missing, and therefore a bug.
Consequently, this thread truly is a bug report about something missed during development, that seems intended by the existence of this essential feature elsewhere in the admin GUI.
The moment one has a large quantity of product attribute sets, all called "Color", or all called "Size", with no way to distinguish between them on the - {site}/admin/commerce/product-attributes - list except by clicking "edit" on each of them in turn to discover which is which, it is clear that this omission is a bug, and a problem of a bug, even if not a bug that causes a code crash.
--
Commerce 2.x needs details like this implemented in order to be a hoped for first class tool.
Comment #6
websiteworkspace commentedBased on the existing code, it seems like it would only require changing a few lines of code to include machines names in the product attribute list builder code to be similar to lists like product type list builder (see code below):
modules\commerce\modules\product\src\ProductAttributeListBuilder.php
modules\commerce\modules\product\src\ProductTypeListBuilder.php
Comment #7
icurk commentedWrote a patch which adds attribute machine name on Product attribute list page.
Comment #8
sorabh.v6Comment #9
sorabh.v6I can confirm that the product attribute page shows machine name also, therefore setting it to RTBC. Attaching screenshot on my site -
Thanks for the patch.
Comment #10
drugan commentedJust FYI:
Absolutely the same changes were suggested by @b_sharpe on Jan 30:
https://github.com/drupalcommerce/commerce/pull/621/files#diff-5645bf553...
But later it was decided by @boyanz to continue here:
#2842961: Add a customer-facing label to ProductAttribute
If you've noticed that is exactly the same issue marked as related on the #2 comment.
Comment #12
mglamanThanks, now added.
Comment #14
bojanz commentedReverted the commit.
1) Why would the array key be "type" for an ID column.
2) "Machine name" seems commonly used in the UI, but I'd like us to firmly decide on "ID" vs "Machine name", cause my initial assumption was that we'd use "ID" everywhere.
Comment #15
icurk commentedUpdated the patch and replaced "type" with "id" and "Machine name" with "ID".
Comment #17
rpayanmrerolled
Comment #18
drugan commentedThis feature is now included into Commerce Extended Attributes module.
Please, do the module review if you find it as a useful one.
Comment #19
lukasss commented+1 for that, but already 2.21 ... and 3 years have passed. But this is an elementary thing that is 100% required
Comment #20
lukasss commented#working for me
Comment #22
jsacksick commentedCommitted.