Any function to refresh a link field in child table (to further refresh fetch fields)

hi @superlack, would you mind sharing? I’m trying to do the same but I don’t even know how to start.
I can create custom fields in “Sales Invoice Timesheet” but that’s about it :slight_smile: When I try to fetch data using cur_frm.add_fetch from “Timesheet Detail” I get nothing…and I think that cur_frm.add_fetch will not work in this case…

Hey there, make sure that you’re putting the script in the parent doc (sales invoice), and that you’re saving, or triggering a refresh to make it function.

Also, I haven’t tested in a while, but this instead of using the custom script fetch method, this alternative might have been what I used to make it work:

hey Thanks , but your alternate method only works if the field type is data .
Any idea how to make it work if both the destination and source fields are LINKS ?
infact cant seem to fetch anything if its a Link field.
any more brilliant ideas?


@superlack frm.refresh_field(‘table name’);