[Skip to main content](#vessel-content)

#   Order Custom Fields in Vendor Order Status email notification

##

- **[sabroso](/forum/user/38789-sabroso "View sabroso's Profile")**
- [![sabroso's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/38789-sabroso "View sabroso's Profile") Topic Author
- [ Offline](/forum/user/38789-sabroso)

Less More

- Posts: 128
- Thank you received: 2
-
-

9 years 7 months ago [\#267779](#267779) by [sabroso](/forum/user/38789-sabroso "View sabroso's Profile")  *[Order Custom Fields in Vendor Order Status email notification](/forum/19-hikamarket/889888-order-custom-fields-in-vendor-order-status-email-notification#267779 "-- HikaShop version -- : 3.0.1 -- HikaMarket version -- : 1.7.3 -- Joomla version -- : 3.6.5 -- PHP version -- : 5.6  Hi there,  I'm talking about the notification email: Market:Order Status Notification  When the email is sent to the Vendor to notify that an order is created the Order Custom Fields are included in the email - that's good.  However when the email is sent again to the Vendor once payment goes through to notify for order confirmation the Order Customs Fields are not there.  Can you see the same issue?  Thanks")* was created by *[sabroso](/forum/user/38789-sabroso "View sabroso's Profile")*

-- HikaShop version -- : 3.0.1
-- HikaMarket version -- : 1.7.3
-- Joomla version -- : 3.6.5
-- PHP version -- : 5.6

Hi there,

I'm talking about the notification email: Market:Order Status Notification

When the email is sent to the Vendor to notify that an **order is created** the Order Custom Fields are included in the email - that's good.

However when the email is sent again to the Vendor once payment goes through to notify for **order confirmation** the Order Customs Fields are not there.

Can you see the same issue?

Thanks

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzE5LWhpa2FtYXJrZXQvODg5ODg4LW9yZGVyLWN1c3RvbS1maWVsZHMtaW4tdmVuZG9yLW9yZGVyLXN0YXR1cy1lbWFpbC1ub3RpZmljYXRpb24/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Jerome](/forum/user/80-jerome "View Jerome's Profile")**
- [![Jerome's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar80.png)](/forum/user/80-jerome "View Jerome's Profile")
- [ Offline](/forum/user/80-jerome)
- HikaShop core developer

Less More

- Posts: 26401
- Thank you received: 4081
-
- [](http://obsi.dev)
-

9 years 7 months ago [\#267798](#267798) by [Jerome](/forum/user/80-jerome "View Jerome's Profile")  Replied by *[Jerome](/forum/user/80-jerome "View Jerome's Profile")* on topic *[Order Custom Fields in Vendor Order Status email notification](/forum/19-hikamarket/889888-order-custom-fields-in-vendor-order-status-email-notification#267798 "-- HikaShop version -- : 3.0.1 -- HikaMarket version -- : 1.7.3 -- Joomla version -- : 3.6.5 -- PHP version -- : 5.6  Hi there,  I'm talking about the notification email: Market:Order Status Notification  When the email is sent to the Vendor to notify that an order is created the Order Custom Fields are included in the email - that's good.  However when the email is sent again to the Vendor once payment goes through to notify for order confirmation the Order Customs Fields are not there.  Can you see the same issue?  Thanks")*

Hello,

Can you please give a more detailed context in order to reproduce the issue.
How exactly that second email is being sent ? (how the order being confirmed exactly)

Regards,

---

Jerome - Obsidev.com
HikaMarket &amp; HikaSerial developer / HikaShop core dev team.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzE5LWhpa2FtYXJrZXQvODg5ODg4LW9yZGVyLWN1c3RvbS1maWVsZHMtaW4tdmVuZG9yLW9yZGVyLXN0YXR1cy1lbWFpbC1ub3RpZmljYXRpb24/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[sabroso](/forum/user/38789-sabroso "View sabroso's Profile")**
- [![sabroso's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/38789-sabroso "View sabroso's Profile") Topic Author
- [ Offline](/forum/user/38789-sabroso)

Less More

- Posts: 128
- Thank you received: 2
-
-

9 years 7 months ago [\#267830](#267830) by [sabroso](/forum/user/38789-sabroso "View sabroso's Profile")  Replied by *[sabroso](/forum/user/38789-sabroso "View sabroso's Profile")* on topic *[Order Custom Fields in Vendor Order Status email notification](/forum/19-hikamarket/889888-order-custom-fields-in-vendor-order-status-email-notification#267830 "-- HikaShop version -- : 3.0.1 -- HikaMarket version -- : 1.7.3 -- Joomla version -- : 3.6.5 -- PHP version -- : 5.6  Hi there,  I'm talking about the notification email: Market:Order Status Notification  When the email is sent to the Vendor to notify that an order is created the Order Custom Fields are included in the email - that's good.  However when the email is sent again to the Vendor once payment goes through to notify for order confirmation the Order Customs Fields are not there.  Can you see the same issue?  Thanks")*

OK sorry, I'm seeing this issue when using Stripe or MangoPay for Payment and hence as confirmation.

Please let me know if you need more info

Thanks!

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzE5LWhpa2FtYXJrZXQvODg5ODg4LW9yZGVyLWN1c3RvbS1maWVsZHMtaW4tdmVuZG9yLW9yZGVyLXN0YXR1cy1lbWFpbC1ub3RpZmljYXRpb24/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[Jerome](/forum/user/80-jerome "View Jerome's Profile")**
- [![Jerome's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar80.png)](/forum/user/80-jerome "View Jerome's Profile")
- [ Offline](/forum/user/80-jerome)
- HikaShop core developer

Less More

- Posts: 26401
- Thank you received: 4081
-
- [](http://obsi.dev)
-

9 years 7 months ago [\#267845](#267845) by [Jerome](/forum/user/80-jerome "View Jerome's Profile")  Replied by *[Jerome](/forum/user/80-jerome "View Jerome's Profile")* on topic *[Order Custom Fields in Vendor Order Status email notification](/forum/19-hikamarket/889888-order-custom-fields-in-vendor-order-status-email-notification#267845 "-- HikaShop version -- : 3.0.1 -- HikaMarket version -- : 1.7.3 -- Joomla version -- : 3.6.5 -- PHP version -- : 5.6  Hi there,  I'm talking about the notification email: Market:Order Status Notification  When the email is sent to the Vendor to notify that an order is created the Order Custom Fields are included in the email - that's good.  However when the email is sent again to the Vendor once payment goes through to notify for order confirmation the Order Customs Fields are not there.  Can you see the same issue?  Thanks")*

Hello,

Okay.
So the best would be to follow what HikaShop has also modified in his order notification email.
You can replace the in HikaMarket order notification preload: Code:

$fields = $fieldsClass-&gt;getFields('frontcomp',$data,'order',''); foreach($fields as $fieldName =&gt; $oneExtraField) { if(isset($data-&gt;$fieldName) &amp;&amp; !isset($data-&gt;order-&gt;$fieldName)) $data-&gt;order-&gt;$fieldName = $data-&gt;$fieldName; if(empty($data-&gt;order-&gt;$fieldName)) continue; echo $sep . $fieldsClass-&gt;trans($oneExtraField-&gt;field_realname).' : '.$fieldsClass-&gt;show($oneExtraField, $data-&gt;order-&gt;$fieldName,'user_email'); $sep = '&lt;br /&gt;'; }

By Code:

$fields = $fieldsClass-&gt;getFields('display:mail_status_notif=1',$data,'order',''); foreach($fields as $fieldName =&gt; $oneExtraField) { if(isset($data-&gt;$fieldName) &amp;&amp; !isset($data-&gt;cart-&gt;$fieldName)) $data-&gt;cart-&gt;$fieldName = $data-&gt;$fieldName; if(empty($data-&gt;cart-&gt;$fieldName)) continue; echo $sep . $fieldsClass-&gt;trans($oneExtraField-&gt;field_realname).' : '.$fieldsClass-&gt;show($oneExtraField, $data-&gt;cart-&gt;$fieldName,'user_email'); $sep = '&lt;br /&gt;'; }

Thanks to these modifications, the email will use the same filters for the custom fields and will use the data from "data-&gt;cart" instead of "data-&gt;order".
Because "data-&gt;order" is based on what is available during the trigger, the custom fields might not be all loaded ; and the modification in HikaShop (via le mass-action system) have reduced the data in the triggers (to reduce the loading and optimize the content).

Regards,

---

Jerome - Obsidev.com
HikaMarket &amp; HikaSerial developer / HikaShop core dev team.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzE5LWhpa2FtYXJrZXQvODg5ODg4LW9yZGVyLWN1c3RvbS1maWVsZHMtaW4tdmVuZG9yLW9yZGVyLXN0YXR1cy1lbWFpbC1ub3RpZmljYXRpb24/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[sabroso](/forum/user/38789-sabroso "View sabroso's Profile")**
- [![sabroso's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/38789-sabroso "View sabroso's Profile") Topic Author
- [ Offline](/forum/user/38789-sabroso)

Less More

- Posts: 128
- Thank you received: 2
-
-

9 years 7 months ago [\#267866](#267866) by [sabroso](/forum/user/38789-sabroso "View sabroso's Profile")  Replied by *[sabroso](/forum/user/38789-sabroso "View sabroso's Profile")* on topic *[Order Custom Fields in Vendor Order Status email notification](/forum/19-hikamarket/889888-order-custom-fields-in-vendor-order-status-email-notification#267866 "-- HikaShop version -- : 3.0.1 -- HikaMarket version -- : 1.7.3 -- Joomla version -- : 3.6.5 -- PHP version -- : 5.6  Hi there,  I'm talking about the notification email: Market:Order Status Notification  When the email is sent to the Vendor to notify that an order is created the Order Custom Fields are included in the email - that's good.  However when the email is sent again to the Vendor once payment goes through to notify for order confirmation the Order Customs Fields are not there.  Can you see the same issue?  Thanks")*

That works, thank you very much!

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzE5LWhpa2FtYXJrZXQvODg5ODg4LW9yZGVyLWN1c3RvbS1maWVsZHMtaW4tdmVuZG9yLW9yZGVyLXN0YXR1cy1lbWFpbC1ub3RpZmljYXRpb24/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

Moderators: [Obsidev](/forum/user/7040-obsidev "View Obsidev's Profile")

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.053 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
