• Categories
    • PHP
    • phpMyAdmin
    • PHPMailer
    • FFMpeg
    • PHPEXcel
    • PHPDoc
    • PHPUnit
    • CakePHP
    • CakePHP 2.0
    • Cake PHP 2.1
    • CakePHP Model
    • Facebook PHP SDK
    • composer-php
    • PHP 7
    • PHP GD
    All Categories
  • About

Store / Website Column in Magento 2 Admin Grid - Custom Module

phpmysqlmagento2


PHP Snippet 1:

 /**
 * Check is single store mode
 */
 if (!$this->_storeManager->isSingleStoreMode()) {
    $this->addColumn(
        'store_id',
         [
             'header' => __('Store View'),
             'index' => 'store_id',
             'type' => 'store',
             'store_all' => true,
             'store_view' => true,
             'sortable' => false,
             'filter_condition_callback' => [$this, '_filterStoreCondition']
            ]
        );
    }

Related Snippets

Create a new line whenever an array value reaches more than 10 characters

Add custom text under order details on WooCommerce My account view order pages

selected value from the listbox in php

Populate Dynamic Dropdowns List in Codeigniter

phpmyadmin : Depends: php-twig (>= 2.9) but 2.6.2-2 is to be installed. WHAT?

How to get the ID of the link in another page in php

Use Python plotly chart in PHP

How to install ZeroMQ for PHP on an Alpine Linux container?

Upgrade PHP on AWS Linux

How to fix " Uncaught TypeError: Argument 1 passed to JpGraphException::defaultHandler() " problem in php 7.1.3 and jpgraph 4.2.6?

How to get result of the formula on import xlsx with maatwebsite using Laravel? I get formula and not value of the formula

Warning: sqlite_query() expects parameter 1 to be resource, string given

PHP AWS Cognito 'Error executing "SignUp" : ResourceNotFoundException : User pool client XXXX does not exist

Create a zip file and download it

I can't delete my image when it is liked because of the foreign key in mysql

About Contact Privacy policy Terms and conditions