Issue #4277 : Change the menu performance of template.

Issue #4277 : Change the menu performance of template.