1

in customer grid there is a phone column like this:

enter image description here

i can filter this column or choose to hide/show this column from setting, i need to remove this phone column from grid and filter, is there a way to do this programmatically from custom module?

1
  • Check my answer will solve your issue. Commented Jun 22, 2018 at 4:39

1 Answer 1

1

Vendor/Module/view/adminhtml/ui_component/customer_listing.xml

You can remove by <item name="componentDisabled" xsi:type="boolean">true</item>

Example:

<column name="billing_telephone">
            <argument name="data" xsi:type="array">
                <item name="config" xsi:type="array">
                    <item name="filter" xsi:type="string">text</item>
                    <item name="editor" xsi:type="string">text</item>
                    <item name="label" xsi:type="string" translate="true">Phone</item>
                    <item name="sortOrder" xsi:type="number">60</item>
                    <item name="componentDisabled" xsi:type="boolean">true</item>
                </item>
            </argument>
        </column>

Run command:

php bin/magento cache:flush

2
  • it makes my grid wont load anymore, stuck in loading Commented Jun 22, 2018 at 6:30
  • @TinyDancer its working for me. Commented Jun 22, 2018 at 8:58

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.