How to show valuation rate in batch selector / any dynamic value in link selection

Hi, what would be the recomended way to show the batch valuation rate next to the qty when selecting a batch in a link field ? The issue is that the valuation rate is not part of the batch doctype but part of the serial and batch bundle doctype and if there are multiple entries for the same batch it needs to be calculated like in the batch-wise balance history report. Iam thinking i would need a valuation rate field in the Batch doctype that always recalculates its value when it is shown in a link field or something like that, but i dont think something like this exists in frappe. Is there a place where the current batch wise valuation rate is stored maybe like the bin doctype ? Or maybe i can hijack the html/javascript that runs when you hit the batch no link field and the list opens ? Please make suggestions how to properly handle such usecases in frappe framework. Thank you :slight_smile: