unchained icon indicating copy to clipboard operation
unchained copied to clipboard

Admin UI: Scaffolding of Variants

Open Mikearaya opened this issue 11 months ago • 1 comments

Discussed in https://github.com/unchainedshop/unchained/discussions/622

Originally posted by nonfungibletunji January 6, 2025 Are product variants auto generated based on on product variant options?

Mikearaya avatar Jan 06 '25 09:01 Mikearaya

@Mikearaya

We need some changes here:

  1. Only show exhaustive combinations, for ex. size:small&color:red. Don't show size:small&color:null cases (the first 5 in the screenshot below should be removed)
  2. Show a "wizard" button next to the dropdown. If clicked it should scaffold a new simple product out of the current configurable product and directly assign it to that vector combination. We need to specify what scaffolding exactly means during the process.
Image

Idea to scaffold from my perspective:

  • simple product but unpublished
  • has the same "texts" and media as the Configurable Product
  • has a new generated title: "title vector1_value vectorN_value", for example_:

"Cool T-Shirt" -> scaffolding on Size Medium & Color Red -> New title for scaffolded product: "Cool T-Shirt Medium Red"

  • has a new generated slug based on that title: "cool-t-shirt-medium-red"

The scaffolding can be done purely by using GraphQL mutations, there is no need for Engine extensions.

pozylon avatar May 09 '25 11:05 pozylon

2. Show a "wizard" button next to the dropdown. If clicked it should scaffold a new simple product out of the current configurable product and  directly assign it to that vector combination. We need to specify what scaffolding exactly means during the process.

what should be the title of the simple product, maybe derived from the configurable product title and vectors? for example if the configurable product title is "t-shirt" and vectors small + red then the simple product title scaffold be small-red t-shirt?

additionally do you think this is engine feature? i think it is more of a admin-ui feature

Mikearaya avatar Jul 24 '25 18:07 Mikearaya

@pozylon

Mikearaya avatar Jul 24 '25 18:07 Mikearaya

implemented in admin ui

Mikearaya avatar Jul 28 '25 06:07 Mikearaya