Jump to content

[SOLVED] PS1.7 Supplier_reference increase


Recommended Posts

Hello. Had to increase our supplier_reference characters recently for when importing CSV and displaying on front office product page. Found all the info I needed to make it work but in various places so I thought I would share what I changed in one place;

1) Classes > Product.php (Line 458. Change end number to what ever you need).

2) Classes > ProductSupplier.php (Line 71. Change to the same number as above).

3) PHPMyAdmin > ps_product (Click the + icon to the left of 'ps_product' and then the + icon next to 'Columns' that appears. Click 'supplier_reference' at the bottom of the next appearing list. Then change the 'Length/Values' on the right to the same number as you did for product.php).

4) PHPMyAdmin > ps_product_attribute (Click the + icon to the left of 'ps_product_attribute' and then the + icon next to 'Columns' that appears. Click 'supplier_reference' at the bottom of the next appearing list. Then change the 'Length/Values' on the right to the same number as you did for product.php).

5) PHPMyAdmin > ps_product_supplier (Click the + icon to the left of 'ps_product_supplier' and then the + icon next to 'Columns' that appears. Click 'product_supplier_reference' at the bottom of the next appearing list. Then change the 'Length/Values' on the right to the same number as you did for product.php). <--- This one will increase the character limit in supplier_reference when creating/editing a product in the back office (BO). Thanks to ChatGPT for this one! :D 

I hope this helps someone :)

Cheers.

Edited by DJPhill (see edit history)
Link to comment
Share on other sites

Hi,

I have a very similar issue to what you had, and was hoping you could help?

I need to increase the Max number of characters allowed in the 'MPN' field for my products from 40 to 80.

I have changed the MPN length to 80 for the VARCHARS in my ps_product & ps_product_attribute tables in my database.

I have also changed the MAX_MPN_LENGTH to 80 in my src/Core/Domain/Product/ProductSettings.php file. 

My problem is that the backoffice is still only allowing me to add MPN numbers of up to 40 characters.

I can't see any references to MPN number in any other files or database tables but my backoffice is still saying it will only allow 40 characters when I try to input more than that.

I was just wondering if you would know if I might have missed something?

Thanks

Steve

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