I'm following this guide :
http://www.mage-world.com/blog/how-to-use-model-and-collection-in-magento-2.html
But at the end i get the error
Fatal error: Class 'Magento\Framework\Model\Resource\Db\AbstractDb' not found in C:\wamp\www\eurecia-shop\app\code\Local\Providers\Model\Resource\providers.php on line 7
(I follow the tutorial, but i just change News by Providers, but it work the same)
this is my file where i get the error :
<?php
namespace Local\Providers\Model\Resource;
use Magento\Framework\Model\Resource\Db\AbstractDb;
class Providers extends AbstractDb
{
/**
* Define main table
*/
protected function _construct()
{
$this->_init('local_providers', 'id');
}
}
I search on google, and no result for this. I'm new to magento, so i'm not really familiar with it.