This topic contains 1 reply, has 2 voices, and was last updated by Yevhen Shyshkin 7 years, 8 months ago.
- Topic
Hi sir,
I installed orocommerce without loading the demo data. However when I view the frontend, I see some predefined menus in header and footer.
I want to remove the menus in header and footer area.
I extended the “OroB2BMenuBundle” in my own custom bundle:
12345678910111213<?phpnamespace Appterra\MenuBundle;use Symfony\Component\HttpKernel\Bundle\Bundle;class AppterraMenuBundle extends Bundle{public function getParent(){return 'OroB2BMenuBundle';}}Then I copy the folder the migrations folder from “oro\commerce\src\OroB2B\Bundle\MenuBundle\Migrations\Data\ORM\LoadMenuItemData.php” to my custom bundle(“src\Appterra\MenuBundle”) to remove the predefined menus. I comment the lines below”
1234567891011<?phpprotected function createMainMenu(ObjectManager $manager){$item = $this->factory->createItem('main-menu');// $item->addChild('Contact Us', ['uri' => '/contact-us']);// $item->addChild('About', ['uri' => '/about']);$menuItem = $this->menuItemManager->createFromItem($item);$manager->persist($menuItem);}123456789101112131415<?phpprotected function createFooterLinks(ObjectManager $manager){$item = $this->factory->createItem('footer-links');// $itemInformation = $item->addChild('Information');// $itemInformation->addChild('About Us', ['uri' => '/about']);// $itemInformation->addChild('Customer Service', ['uri' => '/customer-service']);// $itemInformation->addChild('Privacy Policy', ['uri' => '/privacy-policy']);// $itemInformation->addChild('Site Map', ['uri' => '/sitemap']);// $itemInformation->addChild('Search Terms', ['uri' => '/search/terms']);// $itemInformation->addChild('Advanced Search', ['uri' => '/search/advanced']);// $itemInformation->addChild('Orders and Returns', ['uri' => '/orders-and-returns']);// $itemInformation->addChild('Contact Us', ['uri' => '/contact-us']);Then i run the console command: php app/console oro:migrations:load.
But it did not remove those menus. Did I miss something?
How can I removed them and make my own menus in header and footer?
Thank you.
The forum ‘OroCommerce’ is closed to new topics and replies.