Get search bar result based on user doctype or module permission

Hi,
I want to customise search bar result based on user’s role and doctype permission. Any help will appreciate.
Thanks in advance

@S_M_Shahroz_Allauddi it already does that! Is there a place where you did not find this?