$productcollection=$this->productFactory->create()->getCollection() ->addStoreFilter(2) ->addAttributeToSelect('*');;
Category: magento 2
Magento 2: How to call any template block from phtml file?
https://www.digitalocean.com/community/tutorials/how-to-set-up-apache-virtual-hosts-on-ubuntu-14-04-lts In Magento 1.x, you could call/print any module’s template block in any other template (phtml) file with the following code: 1 2 3 4 echo $this->getLayout() ->createBlock('newmodule/newblock') ->setTemplate('newmodule/newblock.phtml') ->toHtml(); In Magento 2.x, it’s slightly different. Below is the...
Magento 2: Get Store Information (Store ID, Code, Name, URL, Website ID)
http://blog.chapagain.com.np/magento-2-get-store-information-store-id-code-name-url-website-id/ This article shows how we can get store information in Magento 2. We will be fetching store id, store code, store name, store url, and store’s website id. We also write a function which checks if the store is...
Magento 2: Get Currency Code, Currency Symbol & Currency Rate
http://blog.chapagain.com.np/magento-2-get-currency-code-currency-symbol-currency-rate/ Tis article shows how we can get our store’s currency code, currency symbol, and currency rate in Magento 2. We will be fetching all base, default and current currency code. We will also be fetching available currency codes and...
Learn LESS in 10 Minutes (or Less)
http://tutorialzine.com/2015/07/learn-less-in-10-minutes-or-less/
Magento payment method tuturial
http://code.tutsplus.com/series/create-a-custom-payment-method-module-in-magento--cms-784
Magento 2 best tutrial
good example for Ui component grid :best approval http://www.advancedcheckout.com/blog/magento2-tutorial-how-to-create-admin-grid-in-magento2.html/ example grid Ui https://www.ashsmith.io/magento2/
magento 2 Grid and form tutrial
https://www.ashsmith.io/magento2/module-from-scratch-part-5-adminhtml/
Install table setup in Magento 2
$table = $setup->getConnection() ->newTable($setup->getTable('mjweb_customer_rewards')) ->addColumn('id', \Magento\Framework\DB\Ddl\Table::TYPE_INTEGER, null, array( 'identity' => true, 'unsigned' => true, 'nullable' => false, 'primary' => true, ), 'Id') ->addColumn('customer_id', \Magento\Framework\DB\Ddl\Table::TYPE_INTEGER, null, array( 'nullable' => false, 'unsigned' => true, 'nullable' => false, ), 'Customer ID') ->addColumn('rewards_point', \Magento\Framework\DB\Ddl\Table::TYPE_INTEGER,...
Copy custom data from quote to order and order item once order is placed in magento2
http://magento.stackexchange.com/questions/77016/copy-custom-data-from-quote-to-order-and-order-item-once-order-is-placed-in-mage