It would be nice to present the user with a page that shows the just-created products (and only those) right after bulk creation, allowing them to go through the products and do by-product alterations quickly (e.g. assign a different image to each of the newly-created products).

This could be easily done with a view, allowing people to step through the products with a `save and edit next' button (in addition to a `save' button) on each product-edit page.

A question is whether this page should be shown before or after the `create display node' step.

Thoughts?

Comments

summit’s picture

Interested in discussion, just looking into commerce to replace ubercart.
greetings, Martijn

michielbosch’s picture

Not so sure if images are needed at product level. Probably images are going to be attached to the product display when you have multiple product variations.

What would be very helpful is be to be able to modify the prices of each generated product. This could be in a "review & update page", but even better would be to have same approach as attributes in Ubercart. Having a price variation field with each option in the Bulk Product Creation Form makes this very efficient. It should be possible to enter a price variation as +value or -value, and add that to the base price.

Not related to this. Can we have a "Bulk delete"? I am having over 300 product variations for each product. Would very much appreciate a "Bulk delete" to delete a set of related products.

sven.lauer’s picture

Not so sure if images are needed at product level. Probably images are going to be attached to the product display when you have multiple product variations.

That really depends. Think of things like different colors for which you might have different images. True, you could just attach them, gallery style, to the display, but it may me more convenient to have them attached to the products (with the right display formatter to display them on a display).

In any case, it is easy to think of other fields that just may be different by variation, so I think this could be useful.

Also:

Not related to this. Can we have a "Bulk delete"? I am having over 300 product variations for each product. Would very much appreciate a "Bulk delete" to delete a set of related products.

For this, we need to keep track on which products have been bulk-created together, something that is not currently done. I have been thinking about finding a way to do this, probably by introducing a new entity "product set" that gets created automatically on bulk creation. Once we have that in place, it will be easy to have a "review & edit" screen (or a general "edit" screen for product sets that lists all products in the set. This is not really high on my agenda right now.

sven.lauer’s picture

And:

What would be very helpful is be to be able to modify the prices of each generated product. This could be in a "review & update page", but even better would be to have same approach as attributes in Ubercart. Having a price variation field with each option in the Bulk Product Creation Form makes this very efficient. It should be possible to enter a price variation as +value or -value, and add that to the base price.

I see how this could be very convenient. I would have thought that things like that get handled via pricing Rules, but I see that it could be really nice to be able to do one-off adjustments on the bulk creation page. Again, not necessarily something that is on the top of my list for a 1.0 release, but certainly something to think about (& that I would consider patches for).

That said, as I mentioned in #1169384: Multilanguage website ?:

The upcoming alpha will include a small API that allows modules to intervene at various points in the bpc cycle (so as to allow modules to make other fields besides list.module fields 'bulkable' (i.e. used to generate combinations)). One such point will be after saving on submission, so as to allow modules to redirect/display some page before handing control back to bpc. It should then be easy to write a module that checks, at this point, whether there are fields to be translated and displays a form allowing you to do that.

Another use for this (and the one I originally started to think about this) would be to allow to have a page that allows you to supply "by variation" values for a particular field---think having a different image for each variation. The idea would be to have a page were all variations are shown and you can quickly attach an image to each of those---once this is in place, one could easily make the price field behave like this, too. Which is not quite what you asked for, but might be a good interim solution.

rfay’s picture

IMO the ability to manage created variations is fundamental. So you should be able to edit a created product variation set globally.

I also think that image-per-product is probably a base idea.

Also... Don't know how this would be done, but obviously there will be price variations (extra large is $5 more, for example). Again, that's a basic thing that isn't yet addressed (and I don't exactly know how to address it.)

@michielbosch, for bulk delete, you should try Views Bulk Operations and see if it meets your needs.

sven.lauer’s picture

Reviewing the outstanding issues here ... @rfay:

IMO the ability to manage created variations is fundamental. So you should be able to edit a created product variation set globally.

I'll soon add a 2.x branch to start working on this. Actually, bulk editing, at least in terms of "static values" is not that hard to implement once we keep track of groups of products created in bulk. Well, after the fundamental design choices are made, which is non-trivial.

I also think that image-per-product is probably a base idea.

You mean, that would be a basic idea and should be done, or is this an old-fashioned way to say its a bad idea? ;)

Also... Don't know how this would be done, but obviously there will be price variations (extra large is $5 more, for example). Again, that's a basic thing that isn't yet addressed (and I don't exactly know how to address it.)

There is #1251214: Price Value Changes dependent on the attribute. addressing this. There are two features here, both of which are necessary, I think: Setting a price delta on the attribute level (e.g. "For all products, an XL is +$5/ +5%") and setting a price delta at the time of bulk creation ("For this set of products, an XL is +$5").

The former could be done rather nicely with the just-committed functionality allowing to use taxonomy terms as attributes in bulk creation---we could just provide a "price delta" field that can be attached to a taxonomy bundle and alter the price if it has a value. Not sure what is the best way to handle the second case. being able to specify the delta on the bpc form would surely be nice, but is not trivial to implement. Having a wizard-page after the first bpc screen that shows all variations along with a price field would be easier to implement, but surely quite useless if you have large numbers of variations (think conservatively 5 colors times 4 sizes times 2 cuts = 40 variations).

sven.lauer’s picture

Version: 7.x-1.x-dev » 7.x-2.x-dev

Commerce bpc will use a "core like" release management, meaning that new features will go into the 2.x branch (but might be backported).

bones’s picture

Bulk editing of product values would be extremely useful. Either during the bulk creation process or at a later time.

The use I see it for is adjusting stock levels, or individual prices, for the group of products. They could be displayed in a views table with the (chosen) static fields open to be edited. Far more efficient than editing each individually.

I implemented something similar with a custom module for Drupal 5 and E-Commerce, now switching to Drupal 7 and Commerce this module seems a good place for it to happen.

rfay’s picture

Priority: Normal » Major

This probably is the most important (and I imagine most difficult) improvement for this module.

sven.lauer’s picture

@rfay: Agreed, on both counts. Given my limited (time) resources, I keep oscillating between taking the time to Do It Right and to quickly introduce some functionality that allows some rough editing.

One of the main issues in terms of functionality is how to handle products that have been changed individually after bulk creation: What should happen to those on a "bulk edit"? Ultimately, it would be nice to have these be in an "overridden" state (like Views etc in code vs. modifications in the database). Except it would be nice to even have this on the field level. The latter is probably to complex to do soon, but there should be at least some provision to prevent clobbering of individual-product changes on bulk edit.

bbjay’s picture

As an option for "After successful bulk creation, send the user to ...", there could be a view that displays all products with a filter that uses "created date", and set time frame to current time minus 1 hour or 1 day or whatever time variable the user chooses and sorted by most recent first. This view could be a tab view (/admin/commerce/products/recent) next to /admin/commerce/products/list. This would allow you to bulk create several products and review/edit when you have finished creating how ever many products.

3rdLOF’s picture

bbjay Funny, that is just that idea I worked out, except that I would like to have that view to only show the ONLY the products just create. in my case, rather then create a products view I created a product display view, which list the products created plus the product display they belong to with edit for both. Sort of like a DIsplay Manager view. The problem with trying to filter the view to just the products created using TIME SINCE filter ONLY is that -of course- if you have someone creating many products in a row, it will show prior products, and if you limit it too much, if the user is clicking the edit links, when it comes back to view, time may have passed and shows nothing.

One option would be to allow the use of tokens in the CUSTOM DESTINATION URL and then provide something like NID, which could be appended as a filter parameter in the url. On the view side you create a NID filter, hide it with CSS and that cold work.

For now I am setting the view to filter by "new content" un til I can figure out something smoother.

dubs’s picture

A reasonable workaround I use now is to edit the view and include editable fields (http://drupal.org/project/editablefields). This works well for the prices and anything else that editable fields are compatible with.