How can I block access to a specific category in Magento 2 for users who are not logged in or belong to a specific customer group using an observer?

Add an Observer for Category Restriction events.xml <?xml version=”1.0″?> <config xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance”         xsi:noNamespaceSchemaLocation=”urn:magento:framework:Event/etc/events.xsd”>     <event name=”controller_action_predispatch_catalog_category_view”>         <observer name=”restrict_category_access_observer”                   instance=”JJRestrictPageObserverRestrictCategoryAccess”/>     </event> </config> Implement the Observer to Block the Category RestrictCategoryAccess.php <?php namespace JJRestrictPageObserver; use MagentoFrameworkEventObserver; use MagentoFrameworkEventObserverInterface;… Continue reading How can I block access to a specific category in Magento 2 for users who are not logged in or belong to a specific customer group using an observer?

Published
Categorized as Magento

How to remove a category from being displayed in Magento 2 for users who are not logged in or belong to a specific customer group using an observer?*

Step 1: Define the Event Observer <?xml version=”1.0″?> <config xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance”         xsi:noNamespaceSchemaLocation=”urn:magento:framework:Event/etc/events.xsd”>     <event name=”catalog_category_collection_load_after”>         <observer name=”restrict_category_observer”                   instance=”JJRestrictPageObserverRestrictCategory”/>     </event> </config> Step 2: Implement the Observer <?php namespace JJRestrictPageObserver; use MagentoFrameworkEventObserver; use MagentoFrameworkEventObserverInterface; use MagentoCustomerModelSession as CustomerSession;… Continue reading How to remove a category from being displayed in Magento 2 for users who are not logged in or belong to a specific customer group using an observer?*

Published
Categorized as Magento

How can I remove a specific navigation link (e.g., ‘Hot Sale’) for guest users and for logged-in users who are not in a specific customer group, by overriding the Swissup NavigationPro template in Magento 2?

Step 1: Create the Override Directory Swissup’s menu.phtml is located at: vendor/swissup/module-navigationpro/view/frontend/templates/menu.phtml To override it in your custom theme (JJ), create the required directory: mkdir -p szco/app/design/frontend/JJ/Swissup_Navigationpro/templates/ Step 2: Copy the menu.phtml File Copy the original menu.phtml from the module to your theme: cp szco/vendor/swissup/module-navigationpro/view/frontend/templates/menu.phtml szco/app/design/frontend/JJ/Swissup_Navigationpro/templates/menu.phtml Step 3: Modify menu.phtml to Remove “Hot Sale” for… Continue reading How can I remove a specific navigation link (e.g., ‘Hot Sale’) for guest users and for logged-in users who are not in a specific customer group, by overriding the Swissup NavigationPro template in Magento 2?

Published
Categorized as Magento

Revenue and Expense Recognition Overview

Revenue recognition features enable you to recognize revenue independently from billing customers and receiving payments to defer revenue for recognition in multiple future time periods. The amortization feature enables you to record expenses independently from receiving bills and making payments, so you can defer expenses and spread their impact across multiple future time periods. NetSuite… Continue reading Revenue and Expense Recognition Overview

Motion Design in UI: Enhancing User Experience with Animation

Introduction Motion design has revolutionized user interfaces (UI), transforming static visuals into dynamic and interactive experiences. From subtle animations to engaging transitions, motion design enhances usability and keeps users engaged. This article explores how motion design elevates UI and creates more intuitive digital interactions. The Role of Motion Design in UI Motion design in UI… Continue reading Motion Design in UI: Enhancing User Experience with Animation

Published
Categorized as Design

Domain record setup

Go to Commerce –> Hosting –> Domains –> New. Select the domain type as ‘Webstore Only’. Provide the domain name. Select website setup record and hosting root. Save the domain record. After saving the record there will generate two CNAME records which should be added to the domain provider’s website (eg:- godaddy, network solution…) in… Continue reading Domain record setup

Preventing Tax Rounding Discrepancies by using Discount Items

Preventing Tax Rounding Discrepancies by using Discount Items Discrepancies caused by rounding differences can occur when tax is applied to the transaction total in NetSuite Point of Sale (NSPOS), but calculated against line items in NetSuite ERP. The invoiced amount shown in NetSuite ERP can be different by a small fraction (approximately $0.01) from the… Continue reading Preventing Tax Rounding Discrepancies by using Discount Items

Text Stretching Issues in PDF Template Table Cells

When generating PDF documents with table cells, developers may encounter an issue where text characters appear stretched across the available cell space. This formatting irregularity can affect the document’s professional appearance and readability. Solution The solution involves implementing proper HTML structure within the table cell by encapsulating the data within paragraph (<p>) tags. Here’s the… Continue reading Text Stretching Issues in PDF Template Table Cells

Limitations of adding a custom field using form.addField() in a record

Using the form.addField() method to add a custom field to a record in NetSuite (via SuiteScript) can be quite powerful, but there are certain disadvantages or limitations associated with this approach. Here are some of the key drawbacks: 1. Limited to the Form Context Scope Restriction: The field added via form.addField() is tied to a… Continue reading Limitations of adding a custom field using form.addField() in a record