Post by gionata.zarantonello » Fri May 25, 2018 10:43 pm

Hi there!
This is my first post on this forum, so nice to meet you all!
Let's get straight to the point: I need to add a field to the oc_customer table in OC 2.3.0.2
This field should be called "update_time" and should be updated on the db every time any value in the oc_customer group changes.
I need this to provide an integration with an API extension therefore I need to have this functionality at the backend side of my project. I know how to create an additional field in the OpenCart database, but I'm not sure about how to update it whenever a user changes any of its related fields in the reserved area.

Thank you for your support,

Gionata


Posts

Joined
Tue Jan 02, 2018 7:37 pm

Post by straightlight » Tue May 29, 2018 11:33 pm

Assuming your new field would be called: date_modified as the same field structure as the date_added field from the customer database table, you would need to edit the catalog/model/account/customer.php file where the editCustomer method is instantiated.

Dedication and passion goes to those who are able to push and merge a project.

Regards,
Straightlight
Programmer / Opencart Tester


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON
Who is online

Users browsing this forum: No registered users and 12 guests