covis Posted June 10, 2015 Share Posted June 10, 2015 How can I get the customer object by user id? I hooked my module to "actionOrderStatusPostUpdate" and want to send a mail after payment is done. I have the customer id but not the customer mail address I want to send to. Context::getContext->customer will not work bcause you need a user logged in... Appreciate any help Link to comment Share on other sites More sharing options...
salfai Posted June 10, 2015 Share Posted June 10, 2015 (edited) Try : $customer = new Customer((int)$customer['id_customer']); $customer_email = $customer->email; Works for me. Edited June 10, 2015 by salfai (see edit history) Link to comment Share on other sites More sharing options...
covis Posted June 10, 2015 Author Share Posted June 10, 2015 That worked! Thanks! didn't expect it to be that "complex" Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now