Problem Description:
There is an object in the scene that needs to be selected, and the function has been realized. Due to the UI problem, it is necessary to add a background image to the Canvas, which causes the selection effect to fail because the rays are blocked.
solve:
Uncheck Raycast Target by default.
Solution via:
Thanks to the friends of the siki group.