Which three actions do you specify in a module’s Data Patch to add a customer notes attribute?

A merchant tasked you to add an input field for notes to the Customer Account Information backend page.
Which three actions do you specify in a module’s Data Patch to add a customer notes attribute? (Choose three.)
A. $cache->clean([‘eav’, ‘db_ddl’]);
B. $customerSetup->addAttribute(‘customer’, ‘notes’, $options);
C. $customerSetup->getConnection()->addColumn(‘customer_entity’, ‘notes’, $columnSpecs);
D. $notesAttribute->setData(‘used_in_forms’, [‘adminhtml_customer’]);
E. $customerSetup->addAttributeToSet(‘customer’, $attributeSetIdCustomer, $groupId, ‘notes’);

Download Printable PDF. VALID exam to help you PASS.

4 thoughts on “Which three actions do you specify in a module’s Data Patch to add a customer notes attribute?

  1. This is a really odd question…
    You would only need to use get connection to start like: C $this->moduleDataSetup->getConnection()->startSetup();

    B is a given $customerSetup->addAttribute()
    D is used to specify that its used in the admin $notesAttribute->setData(‘used_in_forms’, [‘adminhtml_customer’]); Once its been added.

    Ive never used either E or A. Id go for A because the ddl cache is a thing https://devdocs.magento.com/guides/v2.4/config-guide/cli/config-cli-subcommands-cache.html

    So i reckon like it says ABD is correct

    3
    2

Leave a Reply

Your email address will not be published. Required fields are marked *


The reCAPTCHA verification period has expired. Please reload the page.