Jump to content

Programmatic creation of customization fields


patchrobe

Recommended Posts

Hi,

I'm new to Prestashop and have been getting to grips with the core classes. I've been trying to write a script that programatically creates customization fields. I've been calling the static method:

 

Product::duplicateCustomizationFields($old_id, $new_id);

 

to copy the customization fields from an existing product. When looking at the database and when calling the $myProduct->getCustomizationFields() , everything looks correct but the changes don't show up in the front end or back end of the site. I've tried setting the $myProduct->customizable and $myProduct->text_fields values manually and this doesn't seem to help. I've looked at the database EER diagram in MySQL Workbench and I've had a good look online and in the source code and I can't see what I'm missing. Can anyone help me please?

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...