Before the updates, the item attribute would automatically show on my sales orders.
For example:
Colour: BLACK
But now they are not anymore. I have tried to change the custom form by adding a custom field, but it does not fetch the information from my item code. Do you know how I could make it appear ?
Yes, I have checked the description box, but mine only has the item’s reference. I overwrote my items by importing a new csv, but I would like to know if there is another way to show my variant attributes.
Thank you for your reply and help. I really appreciate it.
I tried, but it did not work. Could you tell me if I did something wrong ? Because I do not know much about coding.
I added a custom field named “Attribute Value” in Sales order item right after the description field, and chose the field type as “data”, and created a custom script as below:
Thank you really much !
This has worked, but my problem is that my attributes are not in the description field, only my item’s reference. For example: 12345-BLACK is a variant of 12345, in the description field only “12345” appears.
So I tried to change your formula, but I encountered an error message.
attributes is the child table on the item master so above code will not work for it. You can only fetch the data of non table fieldtype.
You need to add the attributes table on the sales order doctype and have to write frappe.call to fetch the item’s attribuite and set on the sales order’s attribute table.