init
This commit is contained in:
@@ -0,0 +1,38 @@
|
||||
<?php
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Stemcell\Customer\Model\ResourceModel\Salesperson;
|
||||
|
||||
use Magento\Framework\Model\ResourceModel\Db\Collection\AbstractCollection;
|
||||
|
||||
class Collection extends AbstractCollection
|
||||
{
|
||||
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
protected $_idFieldName = 'salesperson_id';
|
||||
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
protected function _construct()
|
||||
{
|
||||
$this->_init(
|
||||
\Stemcell\Customer\Model\Salesperson::class,
|
||||
\Stemcell\Customer\Model\ResourceModel\Salesperson::class
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $valueField
|
||||
* @param $labelField
|
||||
* @param $additional
|
||||
* @return array
|
||||
*/
|
||||
protected function _toOptionArray($valueField = 'salesperson_id', $labelField = 'name', $additional = [])
|
||||
{
|
||||
return parent::_toOptionArray($valueField, $labelField, $additional);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user