• 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

How can I get new CSRF token in LARAVEL by using ajax

XAMPP keeps showing Dashboard/Welcome Page instead of the Configuration Page

How to convert the int value to inch in PHP [closed]

How in Laravel run JavaScript code stored in php variable?

PHP7 CLI attempts to load xdebug twice - "Cannot load Xdebug - it was already loaded"

mysql_result is defined but mysql_free_result warns it expected a resource

HTML and PHP in one file

MySQL - Connection failed: No route to host

jwt decode throws Invalid argument supplied for foreach() on php-jwt and codeignitor 4

PHP header location absolute URL

Remove "estimated for {country}" text after tax amount in Woocommerce checkout page

Get sum of arrays inside array

Submitting a form with ajax in Wordpress

Set quantity minimum, maximum and step at product level in Woocommerce

How can I stop a symfony process which is listening on http://127.0.0.1:8000

About Contact Privacy policy Terms and conditions