How can i give user permission to open a link field?

We assigned a opportunity to a sales user.now assigned opportunity can be accessed by sales user.but when user open opportunity doc type it shows message that ‘No permission to lead lead number’.lead is a link field in opportunity.How can i give permission to use linked doctype.can i write script for this ?

Hi @Hafees_Kazhunkil
Please give read permission for the Lead doctype to the sales user from the Role Permission Manager.

ok.is there any script to enable permission for a particular doctype

1)Go to Role Permission manager
2) Select Lead as Document Type and Sales User in Role
and check if the sales user has read permission for Lead Doctype
(as shown in the last row of screen shot)
if it is not there add it with Level 0.
You will not need any script for that
Your task will be done