Hi community, referring to the above title, I believe ‘Custom Script for Child Table’ is one of the most asked questions in the forum as it is truly confusing and difficult to understand.
Despite my numerous attempts in creating custom scripts from this link and other posts in this forum, I still fail to create a custom script that works.
Can anyone please guide me how to fetch custom fields: ‘machine_no’ and ‘loom_no’ from ‘Stock Entry Detail’ (Stock Entry’s child table) to my custom field ‘machine_no’ and ‘loom_no’ in my custom table field ‘Batch Breakdown Table’ in Batch doctype?
.
.
.
This is how it looks in Batch form:
I want it to be triggered when Ref Doc (ref_doc) is selected
.
.
.
This is the Stock Entry Details (source child table). To fetch these 2 fields into target child table:
.
.
.
This is the target child table ‘Batch Breakdown Table’. To ‘receive’ data from source child table, Stock Entry Details when ‘ref_doc’ is triggered:
So, I really hope someone can help me in this. I need this custom script badly. Thank you in advance.