Found the solution.
After migrating script-based view to table function, a new object TABLE_FUNCTION_XXX.hdbtablefunction will be generated automatically and its initial status is inactive.
Need to activate this .hadtablefunction manually from repositories window, afterwards can activate the view successfully.