Tree/Warehouse how to delete it from search

hi
i have problem with tree view for warehouse since it dons’t take the user permissions
how to disable tree view in search and in doclist menu

you can delete the _tree.js in doctype

i did @Misbah but it still shows in search and in the left side of doctype list view i can switch to tree …

please bench restart or sudo service supervisor restart