CustomerGroupWriter

Implements \CustomerGroupWriterInterface

Class CustomerGroupWriter

category

System

package

CustomerGroup

subpackage

Repositories

Methods

CustomerGroupWriter constructor.

__construct(\CI_DB_query_builder $queryBuilder, \LanguageProvider $languageProvider) 

Arguments

$queryBuilder

\CI_DB_query_builder

$languageProvider

\LanguageProvider

Add group permission id to categories table.

_addGroupPermissionToCategories( $customerGroupId) : $this

Arguments

$customerGroupId

Response

$this

Add group permission id to products table.

_addGroupPermissionToProducts( $customerGroupId) : $this

Arguments

$customerGroupId

Response

$this

Check if given column exists in given table.

_columnNotExists( $column,  $table) : boolean

Arguments

$column

string

$table

string

Response

boolean

Creates an group_permission by id column in given table.

_createGroupPermissionColumn( $id,  $table) : $this

Arguments

$id

int

$table

string

Response

$this

Creates an personal offer table with given id as suffix.

_createPersonalOfferTable( $customerGroupId) : $this

Arguments

$customerGroupId

Response

$this

Drops personal offer table, if table with id exist.

_dropPersonalOfferTableIfExists( $customerGroupId) : $this

Arguments

$customerGroupId

Response

$this

Updates the default customer group in the configuration data table.

_setDefault(\CustomerGroupInterface $customerGroup,  $customerGroupId) : \CustomerGroupWriter

Arguments

$customerGroup

\CustomerGroupInterface

$customerGroupId

Response

\CustomerGroupWriter

Create base data from chosen personal offers table.

createBase(\IntType $customerGroupId, \IntType $baseId) : \CustomerGroupWriter

Arguments

$customerGroupId

\IntType

$baseId

\IntType

Response

\CustomerGroupWriter

Saves customer group entity data in database.

store(\CustomerGroupInterface $customerGroup) : $this|\CustomerGroupWriterInterface

Arguments

$customerGroup

\CustomerGroupInterface

Customer group to be saved.

Response

$this|\CustomerGroupWriterInterface

Same instance for chained method calls.

Updates customer group entity data in database.

update(\CustomerGroupInterface $customerGroup) : $this|\CustomerGroupWriterInterface

Arguments

$customerGroup

\CustomerGroupInterface

Customer group to be updated.

Response

$this|\CustomerGroupWriterInterface

Same instance for chained method calls.

Properties

queryBuilder

queryBuilder : \CI_DB_query_builder
var

Type(s)

\CI_DB_query_builder

languageProvider

languageProvider : \LanguageProvider
var

Type(s)

\LanguageProvider