on 2019 Apr 23 10:45 AM
Hi Experts ,
As we knew , Once order placed we will get email confirmation mail and this is OOB of Hybris .
Can anyone help me to understand How do we get email id of the user to whom we want to send the email after Order Placed.
It would be good help for me .
Regards,
You need to set userModel to you model
check the bellow code.
final OrderModel orderModel = new OrderModel(); final OrderProcessModel process = new OrderProcessModel(); final BaseStoreModel baseStoreModel = getBaseStoreService().getCurrentBaseStore();
Date date = new Date(System.currentTimeMillis());
orderModel.setOrderNumber(orderData.getCode());
orderModel.setSite(baseSiteService.getCurrentBaseSite());
orderModel.setUser(userService.getCurrentUser());
orderModel.setStore(baseStoreModel);
orderModel.setCurrency(commonI18NService.getBaseCurrency());
orderModel.setDate(date);
orderModel.setLanguage(commonI18NService.getCurrentLanguage());
orderModel.setGuid(orderData.getCode());
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
32 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.