fix bug for dynamic menu
add more test case for service