ECMS-5816: [Unified Search] Failed to display document search result

Problem analysis
* NullPointerException occurs while getting PageState

Fix description
* Return false in the hasPortlet() function when the current page hasn't PageState.
Merge commit '5092ab953274221b9a01a566b546587e2ac0339f' into HEAD