• 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

Malformed MIME header error in Symfony 5.3

Composer Script echo

Open a popup box after receiving result from ajax

Phalcon: setStatusCode returns empty response

Detect emoticons in string

Laravel 5: Is there a non-case sensitive way to sort a collection by an attribute?

Why does codeigniter & Linux server throws unserialize() session data error when user tries to login

How to fix this error : Ask your hosting provider to use PHP 7.2.5 or higher for both HTTP and CLI?

PHP Form Not Inserting

OAuth2 Token PHP

Laravel Command Schedule Not Working Properly

laravel MVC execution flow

Substitute integers and dots with regex [duplicate]

Laravel 8 factory state afterCreating

Laravel 5.2: Unable to locate factory with name [default]

About Contact Privacy policy Terms and conditions