• 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 to make Canonicals with PHP

How to remove Deprecated SymfonyComponentDebugDebugClassLoader?

MySQL order by field in Eloquent

NGINX: connect() to unix:/var/run/php7.2-fpm.sock failed (2: No such file or directory)

How to upload mpdf file after generating to s3 bucket in php

Call authenticate manually in router middleware

PHP block shortcut in Visual Studio Code

Laravel Pagination links() not working

Pages are working fine on localhost but not running on the hosting server

Laravel: Why is my variable not being set while it's in the construct function of the controller?

PHP Print to Network Printer

JQuery content editable div and text box on submit not sending POST

TesseractOCR not working for Laravel

Edit XML in HTML form and submit to self

Last order would be re-order in wooCommerce. How is it possible?

About Contact Privacy policy Terms and conditions