I have added onestepCheckout module in my project. Now, I want to show discount amount in checkout summary after product name.

I refer this link : Add custom product attribute to checkout summary Magento 2

It shows something on that page while loading. But when my page loaded properly then it's gone.

Can anyone please help me to solve this.

Here you can see this 'no' below item image is showing while loading and then disappears. : https://www.loom.com/share/ab05cd107b384d468b2d1147816c2ae6

  • Have you check consol or error log file? Commented Apr 26, 2019 at 6:50
  • yes, i have checked consol : prntscr.com/nh29j7 Commented Apr 26, 2019 at 7:03
  • /vendor/magento/module-sales-rule/view/frontend/layout/checkout_cart_index.xml <item name="discount" xsi:type="array"> <item name="component" xsi:type="string">Magento_SalesRule/js/view/cart/totals/discount</item> <item name="config" xsi:type="array"> <item name="title" xsi:type="string" translate="true">Discount</item> </item> </item> Insert it in checkout_cart_index.xml file of Magento_checkout in your theme by Overriding it there. Now you can see discount try it @KhooshbuPatel Commented Apr 26, 2019 at 7:14
  • Thanks for your suggestion but it's not working because I have added OnestepCheckout module.@sannikalariya Commented Apr 26, 2019 at 11:48


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.