Zastąp moduł podstawowy jak poniżej: Kod /Custom/listy życzeń: kod
/Custom/Wishlist/registration.php
<?php \Magento\Framework\Component\ComponentRegistrar::register( \Magento\Framework\Component\ComponentRegistrar::MODULE, 'Custom_Wishlist', __DIR__ );
Kod/Użytkownika/życzeń/composer.json
{
"name": "custom/wishlist-magento2",
"description": "N/A",
"require": {
"php": "~5.5.0|~5.6.0|~7.0.0"
},
"type": "magento2-module",
"license": [
"OSL-3.0",
"AFL-3.0"
],
"version": "1.0.0",
"authors": [
{
"name": "Pramod Kharade",
"email": "[email protected]",
"homepage": "https://www.blazeclan.com/",
"role": "Developer"
}
],
"autoload": {
"files": [
"registration.php"
],
"psr-4": {
"Custom\\wishlist\\": ""
}
}
}
Kod/Użytkownika/życzeń/etc/moduł.xml
<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Module/etc/module.xsd">
<module name="Custom_Wishlist" setup_version="1.0.0" >
<sequence>
<module name="Magento_Wishlist" />
</sequence>
</module>
</config>
Kod/Użytkownika/życzeń/etc/view/frontend/layout/default.xml
<?xml version="1.0"?>
<referenceContainer name="sidebar.additional" remove="true">
<block class="Magento\Wishlist\Block\Customer\Sidebar" name="wishlist_sidebar" as="wishlist" template="Magento_Wishlist::sidebar.phtml"/>
</referenceContainer>
</body>
Świetnie! zadziałało! – jstuardo
Witam gyus Sugeruję, abyście wszyscy nie zamienili motywu pustego i lumy, ponieważ pochodzą z domyślnej instalacji zamiast tego lepszego rozwiązania, proszę utwórz własny motyw i zróbcie z nim cokolwiek, aby zachować swój sklep z nadchodzącym magento wersja –
Jeśli chcesz usunąć "Moja lista życzeń" z paska bocznego, ale nadal zachowuj funkcjonalność na stronie produktu, dodaj to w pliku default.xml: ' ([źródło] (http://magento-r.blogspot.sg/2016/01/remove-wishlist-and-compare-products.html)) –
10basetom