• 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

json_encode turns array into an object

PHP code for generating decent-looking coupon codes (mix of letters and numbers)

Error Class "LaravelFortifyFeatures" not found

How to debug in WooCommerce 3+

woocommerce change position of price

Woocommerce product attributes with hierarchy like categories

I want to store data in new index as per my key in php [duplicate]

Laravel multi auth - Authentication user provider [] is not defined

laravel controller function parameters

Adding custom body class to the custom archive pages

Laravel whole batch is cancelled if one Job fails

Add and update products to session cart in Laravel

Insert database rows from columns of data from associative array of indexed arrays

Warning: Unknown: Failed to write session data using user defined save handler. (session.save_path: ) in Unknown on line 0

Insert a DIV after the 6th product only once in WooCommerce category archives

About Contact Privacy policy Terms and conditions