• Welcome to KonaKart Community Forum. Please login or sign up.
 

Creating order product record for each product in order

Started by Iker, April 19, 2008, 05:49:20 am

Previous topic - Next topic

Iker

Hi,

I have two questions and I would like to mention some things that appear to be bugs:

1. I would need to get a record for each and every product in the order (i.e. if customer orders 3 products of the same kind, I need 3 records with qty=1 each). How can this be achieved?

2. I have some free products/service request among the products, where instead of adding product to basket, I would rather redirect user to another page to input some data needed for the free service. How can this be achieved?


3. Appearent bugs:
- When My account is displayed and language is changed, in header on the left side (after homepage) My account doesn't take new language.
- Buttons Continue Shopping and Sign In don't take Spanish labels.
- Contents of categories tile doesn't refresh when language is changed (only title of tile gets refreshed)
- On UI manufacturers page in the categories combo the last category is not shown ('All categories' + all but last one is displayed only)

Thank you

pete

QuoteI would need to get a record for each and every product in the order (i.e. if customer orders 3 products of the same kind, I need 3 records with qty=1 each). How can this be achieved?

I'm not sure at what point in the process you require this. However the way you could do it is to edit the Order object and add OrderProducts when you see that they exist with quantities > 1. i.e. change the quantity to 1 and add extra ones.

QuoteI have some free products/service request among the products, where instead of adding product to basket, I would rather redirect user to another page to input some data needed for the free service. How can this be achieved?

If a product has options, you will automatically be redirected to the details page to select the options. This is determined by the action class. Maybe you can do something similar in the action class by looking at a custom attribute of your product.

Apparent bugs.

Note that the buttons are normally images so you need Spanish versions
The category contents are defined in the DB so you need translated versions in the DB.


Iker

Hi Pete,

Thanks for the answer. About the bugs:

Categories tile: Of course, they are translated in the DB, so let me rephrase what the problem is: when you change the language on the language tile, the page gets refreshed and displayed in the chosen language. Except for the content of the Categories tile, which only gets updated when clicked on one of its categories (so eventually it does get translated, but not with the language change click, so I guess it's not included in the list of events of what should be updated when language is changed)

Buttons: Indeed, I didn't investigate that thoroughly, assumed it's done similarly to the Buy Now button

Saving Order: Can you please point out which file needs to be modified?

Thanks

pete

Quote
Saving Order: Can you please point out which file needs to be modified?


If you aren't using the GWT based one page checkout, you should look at the Checkout* Action Classes where you'll see that the order gets created in CheckoutDeliveryAction and eventually saved in CheckoutConfirmationSubmitAction. Maybe just after creation you could edit it to add extra order products.

pete

Quote
Categories tile: Of course, they are translated in the DB, so let me rephrase what the problem is: when you change the language on the language tile, the page gets refreshed and displayed in the chosen language. Except for the content of the Categories tile, which only gets updated when clicked on one of its categories (so eventually it does get translated, but not with the language change click, so I guess it's not included in the list of events of what should be updated when language is changed)


In the struts-config.xml make the following change. For the SetLocale_xx_xx actions change the forward to <forward name="SetLocale" path="/Welcome.do"/> instead of <forward name="SetLocale" path="/CatalogMainPage.do"/>.