Jump to content

Adding customisation fields on cart product detailed lines, is it possible?


jr.villaron

Recommended Posts

Hi everyone,

As usual I am unable to achieve what I thought it would have been an easy task in Prestashop. I would like to display customisation fields for every product in the cart detailed lines. I attach a screenshot to make myself better understood.

Here is the code that i have taken from product.tpl

{if $product.is_customizable && count($product.customizations.fields)}
{block name='product_customization'}
{include file="catalog/_partials/product-customization.tpl" customizations=$product.customizations}
{/block}
{/if}

But when I paste it in cart-detailed.tpl nothing happens...

 

Would it be possible to display the field somehow?

 

Thank you in advance!

2023-05-03_091850.png

Link to comment
Share on other sites

You can't simple use the code/template from product to add customizations in the shopping cart, this would require addtional developments. What is standard in classic theme is it least the option to display the customization

grafik.png.6278c72973b61146472ba9060e73c3fb.png

Link to comment
Share on other sites

This is my module ;) It enables the customer to directly add customization into the cart from the product page without the extra step of saving the customization first. There is no change/functionality inside the shopping cart itself

Link to comment
Share on other sites

Hi again,

the final decision that I have taken is to call the .product-customization element and open it on a modal. The problem that I see is that I still have the "Save" button and that when I save it redirects to the product page.

Do you think that by using your module we could save the field on the fancybox modal avoiding that unpleasant redirection ?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...