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

#   upload fields not consistent when editing productr

##

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

Less More

- Posts: 515
- Thank you received: 22
-
-

11 years 4 months ago [\#209397](#209397) by [jouwnaambord.nl](/forum/user/1188-jouwnaambord-nl "View jouwnaambord.nl's Profile")  *[upload fields not consistent when editing productr](/forum/35-orders-management/878361-upload-fields-not-consistent-when-editing-productr#209397 "-- HikaShop version -- : 2.5.0 -- Joomla version -- : 3.4.3  Hi,  There seems to be some bug in the editing of a product that's in an order. When the product is edited, the upladed files are not linked to the orderproduct anymore and there is a array field instead of the link to the file. See screenshot attached.")* was created by *[jouwnaambord.nl](/forum/user/1188-jouwnaambord-nl "View jouwnaambord.nl's Profile")*

-- HikaShop version -- : 2.5.0
-- Joomla version -- : 3.4.3

Hi,

There seems to be some bug in the editing of a product that's in an order. When the product is edited, the upladed files are not linked to the orderproduct anymore and there is a array field instead of the link to the file. See screenshot attached.

[ ![orderproduct-edited.jpg](/forum/attachment/25681) ](/forum/attachment/25681 "...uct-edited.jpg")

- [ ![orderproduct-edited.jpg](/forum/attachment/25681) ](/forum/attachment/25681 "...uct-edited.jpg") [ ](/forum/attachment/25681?download=1 "...uct-edited.jpg")

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

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86587
- Thank you received: 14325
-
-

11 years 4 months ago [\#209413](#209413) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[upload fields not consistent when editing productr](/forum/35-orders-management/878361-upload-fields-not-consistent-when-editing-productr#209413 "-- HikaShop version -- : 2.5.0 -- Joomla version -- : 3.4.3  Hi,  There seems to be some bug in the editing of a product that's in an order. When the product is edited, the upladed files are not linked to the orderproduct anymore and there is a array field instead of the link to the file. See screenshot attached.")*

Hi,

Could you please provide a screenshot of the settings of your custom field ?

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

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

Less More

- Posts: 515
- Thank you received: 22
-
-

11 years 4 months ago [\#209525](#209525) by [jouwnaambord.nl](/forum/user/1188-jouwnaambord-nl "View jouwnaambord.nl's Profile")  Replied by *[jouwnaambord.nl](/forum/user/1188-jouwnaambord-nl "View jouwnaambord.nl's Profile")* on topic *[upload fields not consistent when editing productr](/forum/35-orders-management/878361-upload-fields-not-consistent-when-editing-productr#209525 "-- HikaShop version -- : 2.5.0 -- Joomla version -- : 3.4.3  Hi,  There seems to be some bug in the editing of a product that's in an order. When the product is edited, the upladed files are not linked to the orderproduct anymore and there is a array field instead of the link to the file. See screenshot attached.")*

Sure, here it is.
[ ![custom-field-upload-1.jpg](/forum/attachment/25686) ](/forum/attachment/25686 "...d-upload-1.jpg")

- [ ![custom-field-upload-1.jpg](/forum/attachment/25686) ](/forum/attachment/25686 "...d-upload-1.jpg") [ ](/forum/attachment/25686?download=1 "...d-upload-1.jpg")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzM1LW9yZGVycy1tYW5hZ2VtZW50Lzg3ODM2MS11cGxvYWQtZmllbGRzLW5vdC1jb25zaXN0ZW50LXdoZW4tZWRpdGluZy1wcm9kdWN0cj90bXBsPW1hcmtkb3du) 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: 26402
- Thank you received: 4081
-
- [](http://obsi.dev)
-

11 years 4 months ago [\#209580](#209580) by [Jerome](/forum/user/80-jerome "View Jerome's Profile")  Replied by *[Jerome](/forum/user/80-jerome "View Jerome's Profile")* on topic *[upload fields not consistent when editing productr](/forum/35-orders-management/878361-upload-fields-not-consistent-when-editing-productr#209580 "-- HikaShop version -- : 2.5.0 -- Joomla version -- : 3.4.3  Hi,  There seems to be some bug in the editing of a product that's in an order. When the product is edited, the upladed files are not linked to the orderproduct anymore and there is a array field instead of the link to the file. See screenshot attached.")*

Hi,

Thanks for the report.

Please edit the file "administrator/components/com_hikashop/classes/order.php" and replace Code:

if(isset($productData['order_id'])) { $product = new stdClass(); foreach($productData as $key =&gt; $value) { hikashop_secureField($key); $product-&gt;$key = $safeHtmlFilter-&gt;clean($value, 'string'); }

By Code:

if(isset($productData['order_id'])) { $product = new stdClass(); $fieldClass = hikashop_get('class.field'); $oldData = null; $item_fields = $fieldClass-&gt;getData('backend', 'item'); $fieldClass-&gt;_checkOneInput($item_fields, $productData, $product, 'item', $oldData); foreach($productData as $key =&gt; $value) { hikashop_secureField($key); if(isset($items_fields[$key])) continue; $product-&gt;$key = $safeHtmlFilter-&gt;clean($value, 'string'); }

It should fix the issue by using the field class to save the custom fields in the order product.

I will submit the patch to the rest of the team (with other little modifications), which should be include in the next release.

Regards,

---

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

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzM1LW9yZGVycy1tYW5hZ2VtZW50Lzg3ODM2MS11cGxvYWQtZmllbGRzLW5vdC1jb25zaXN0ZW50LXdoZW4tZWRpdGluZy1wcm9kdWN0cj90bXBsPW1hcmtkb3du) 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?

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

Time to create page: 0.051 seconds

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