What can you determine from this directory’s name?

You are reviewing a Magento module and see a directory named Service. What can you determine from this directory’s name?A . It is where the API response cache is storedB . It is where API-related configuration residesC . It is where the module’s service contracts are storedD . You need...

April 4, 2021 No Comments READ MORE +

How do you do that?

You are developing a module and need to add another column to a table introduced by another module MyCompany_MyModule via db schema. How do you do that?A . Create a etc/db_schema.xml file in your module, add the column and run bin/magento setup:upgradeB . Create a etc/db.xml file in your module,...

April 3, 2021 No Comments READ MORE +

In which file will the event observer be declared?

You have created a custom module which must perform an action immediately after an order is placed, but only on the store front of the merchant site. You have selected the checkout_submit_all_after as the target event which the module will observe. In which file will the event observer be declared?A...

April 3, 2021 No Comments READ MORE +

If you want to create layout XML instructions for this controller, what would be the layout XML's filename?

You see this code in etc/adminhtml/routes.xml: <route id="mymodule" frontName="user-subscriptions"> <module name="MyCompany_MyModule" /> </route> You have placed a controller in Controller/Index/Subscribe.php. If you want to create layout XML instructions for this controller, what would be the layout XML's filename?A . mymodule_index_subscribe.xmlB . mymodule_subscribe_[ACTION NAME].xmlC . user_subscriptions_index_subscribe.xmlD . user_subscriptions_subscribe_[ACTION NAME].xmlView AnswerAnswer: A

April 2, 2021 No Comments READ MORE +

What is the resolution?

You are creating a new indexer which must run after the targetrule_product_rule index process. When you run bin/magento indexer:reindex, your rule always runs first creating inaccurate data. What is the resolution?A . Use a dependencies node in your indexer configuration.B . Specify the sortOrder in your indexer configuration.C . Use...

April 2, 2021 No Comments READ MORE +

What is the layout handle of the storefront path /custom/feature/?

A module declares the route: What is the layout handle of the storefront path /custom/feature/?A . mymodule_featureB . custom_featureC . mymodule_feature_indexD . custom_feature_indexView AnswerAnswer: C

April 2, 2021 No Comments READ MORE +

With the automatic dependency injection that Magento provides, how is the StoreManagerInterface resolved?

The constructor function for MagentoCatalogModelCategory contains this excerpt: With the automatic dependency injection that Magento provides, how is the StoreManagerInterface resolved?A . If no $storeManager is provided, Magento’s code generator creates a shell concrete class based on MagentoStoreModelStoreManagerInterfaceB . Magento finds all classes that implement MagentoStoreModelStoreManagerInterface (ordered alphabetically) and injects...

April 2, 2021 No Comments READ MORE +

How do you resolve the issue, keeping maintainability in mind?

A custom module is performing an optimized custom query for quote items. The class applies the query customizations on the select object of a quote item collection instance. You are tasked to resolve an issue where the query sometimes does not deliver the expected results. You have debugged the problem...

April 1, 2021 No Comments READ MORE +

What are two functions of a resource model? (Choose two.)

What are two functions of a resource model? (Choose two.)A . It executes create, retrieve, update and delete actions for an entityB . It loads lists of entity modelsC . It is made available in the Magento API for the purpose of data manipulationD . It maps an entity to...

April 1, 2021 No Comments READ MORE +

How do you resolve the exception?

You need to find all orders in the processing state. You have written the code: How do you resolve the exception?A . Use dependency injection to load an instance of the SearchCriteria classB . Change the getList parameter to: $searchCriteraBuilder->addFilter(‘state’,’processing’)->create()C . Clear generated code to get a new version of...

April 1, 2021 No Comments READ MORE +