Before this commit, in project sharing feature, when the portal user is
in task form view, he can see the sale order stat button if a sale order
is defined in the task but this button is disabled.
This commit allows the portal user to click on this stat button if he
has access to the sale order of task. If he cannot access then the stat
button will be invisible.
And if the portal user clicks on this button, he will be redirect to
`/my/orders/<id of the sale order>`.
task-2633229
Closes#82379