Hi, On Jul 28, 7:56 pm, Albert Pi <[email protected]> wrote: > Thank you, Izantal. Very responsive. > > I've been wondering what's the best way to do this properly. Just > adding an m2m field to the Product itself, extending it, is not > enough. It becomes hardly usable. >
You are right it's not the perfect solution. But it would be a good start since you would have a custom product(bike) and you could attach other products to it(saddle etc). > My conclusion being that I need to extend Option, or to make a new > OptionProduct class tailored to this scenario. Option with fk to > Product I have not used the Option feature much, so I don't have too much experience with it. Yes it's definetly have to be custom to this scenario. > > For example: > (CustomProduct) ... > OptionProduct (Option) ... product = models.ForeignKey(Product) ... > > CustomBike1 > -OptionGroup1: saddle > OptionProduct A: Saddle Product X > OptionProduct B: Saddle Product Y > OptionProduct C: Saddle Product Z > -OptionGroup2: wheels > ... > In that case CustomOptionGroup should have a manytomany field to product and make it an inline for CustomProduct. > How hard would it be to do this with satchmo? Which are the > implications of this, regarding other parts of satchmo code? I guess > it requires a lot of work, but I'm new to satchmo, so I don't know. > Again since this will be very unique it would not be that difficult. You need to write the views and templates for it so it would not affect the rest of the satchmo store. The complication I can see is with the checkout process. Since orderitem has a foreignkey to product. One way I can think of it(as usual the quick hack way) is that when your customer finished building the bike your view creates a new product with the total calculated from the parts he/she picked and all the products attached to this product through the manytomany field. Then it would just become an other product for the checkout system and it would go through without any issue. Again I am just brainstorming here so take it with a grain of salt. > PS: And by the way, why aren't Option and OptionGroup, let's say in > apps/product/modules/product_options/models.py with product_options/ > custom/, product_options/configurable/ ... It feels it doesn't belong, > right now, with "regular" products. Just saying. > No idea on this, may be one of the core devs could comment on this. > Thanks again for your interest and congrats for your hard work, you, > satchmo devs. > Congrats goes to the core devs and everyone who contributes:) Satchmo is a breath of fresh air for me compare to the other frameworks I have worked with.:):) I hope you'll find satchmo the right fit for your needs and even if there is something that's missing satchmo is just django... :-D lzantal > On Jul 28, 3:47 am, lzantal <[email protected]> wrote: > > > Hi, > > > That sounds very interesting. This would be my first prototype for > > this:: > > Create a custom product by inheriting product, add a manytomany field > > to product. > > I would also add an automatic discount for this product, so the price > > drops since they buy a lot > > of parts. Create a custom view to handle the product customization. > > This is where you would display > > the different parts and they could pick which one to add to their > > product. > > Have a link like "Build your own Bike". > > It sounds like fun, and I don''t think it would that complicated to > > implement it. > > And you will be Much happier with satchmo:) > > I have done my fair share of coding/theming with osCommerce. > > > Hope it helps > > > lzantal > > > On Jul 27, 1:59 pm, Albert Pi <[email protected]> wrote: > > > > I meant something like this:http://addons.oscommerce.com/info/6328 > > > > On Jul 27, 9:54 pm, Albert Pi <[email protected]> wrote: > > > > > I'd like to sell a Product made of parts which are also sold > > > > separately. So I need an Option class with something more than a key > > > > value pairs (2 CharFields), say maybe an OptionProduct class with fk > > > > to Product and to OptionGroup (besides price_change, and so on). > > > > > This is the scenario, to make this clear: I want to sell custom bikes > > > > made of parts which are also sold separately. Customers have to choose > > > > what saddle, frame, wheels, etc, do they want, but they also can buy > > > > them separately. If they decide to buy the custom bike, 1 single > > > > Product goes to the cart (Custom bike), with all the selected options > > > > and price changes due to each one of them. > > > > > OptionGroup (Options) seems a bit limited to simpler cases (size/ > > > > color). I think this is a pretty common scenario for example, for > > > > selling, let's say, a customized computer or its graphic card. > > > > > Questions: > > > > > 1. Can Satchmo do this out of the box? I guess not. > > > > 2. If not, what's the direction to follow, extending CustomProduct, > > > > Option, OptionGroup... > > > > 3. Do you think it'll require a lot of work? (stock control, cart, > > > > etc.) > > > > > Thanks in advance, I'm still considering Satchmo as my option, it > > > > seems great, and I've been using django lately. > > > > > And thanks for you hard work. -- You received this message because you are subscribed to the Google Groups "Satchmo users" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/satchmo-users?hl=en.
