Client script for stock entry

Can anyone help me understand how to add a custom amount to the basic rate for items that are only listed in the target warehouse in stock entry in ERPNext 15? The custom amount should be fetched from the item master.