• 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

Magento 2 - Controller returning blank page

Laravel post contact form giving me error 419

How update php.ini on a Mac OS X Mojave?

Passing a boolean value from checkbox in Laravel form

Open a popup box after receiving result from ajax

Can we define variables in `.tpl` files?

onKeyUp event calculation not working on the following rows from php generated forms except the first one

How to Make Laravel Eloquent "IN" Query?

SMTP "Error: DATA not accepted from server!" Opencart 2.3 on InMotionHosting

PhpSpreadSheet: How to save Workbook sheets in individual CSV files

PHP: Calling MySQL Stored Procedure with Both INPUT AND OUTPUT Parameters (NOT "INOUT")

Get latest Tweets - What API

Laravel relationship belongsToMany with composite primary keys

Malformed MIME header error in Symfony 5.3

SQL AVG() to 2 decimals

About Contact Privacy policy Terms and conditions