I achieved to add a custom tab / grid to the product new & edit page with an input field inside. Following this tutorial
The problem is that it's not saving the data input. And at this point I have no idea if this is actually not covered in the tutorial or I made a mistake.
Is this enough to save the data input?
$customFieldValue = $this->_getRequest()->getPost('custom_field');
$product->save();
How could I debug this value in the backend?
It is not covered by tutorial. To see the difference you probably have to add new attribute to product and then do something like:
$customFieldValue = $this->_getRequest()->getPost('custom_field');
$product->setNewAttribute($customFieldValue);
$product->save();
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With