Inheritance diagram for Customer:A customer.
Public Properties | |
| const | DIR = 'customers' |
| const | IS_DECLINED = 'declined' |
| Customer declined the invite, has no account. More... | |
| const | IS_DISABLED = 'disabled' |
| Customer can't log in. More... | |
| const | IS_ENABLED = 'enabled' |
| Customer can log in and shop. More... | |
| const | IS_INVITED = 'invited' |
| Customer needs to activate their account via invite link before logging in. More... | |
| const | MAP |
| const | TYPE = 'customer' |
Public Properties inherited from AbstractEntity | |
| const | DIR = '' |
| All subclasses must redeclare this to match their REST directory (without container). More... | |
| const | TYPE = '' |
| All subclasses must redeclare this to match their types. More... | |
Public Properties inherited from Data | |
| const | MAP = [] |
| const | PATCH = [] |
Protected Properties | |
| string | $activationUrl |
Protected Properties inherited from Data | |
| Api | $api |
| Pool | $pool |
Public Methods | |
| magic bool | getAcceptsMarketing () |
| magic string | getAcceptsMarketingUpdatedAt () |
| string | getActivationUrl () |
| magic Address[] | getAddresses () |
| magic string | getCreatedAt () |
| ISO8601. More... | |
| magic string | getCurrency () |
| read-only More... | |
| null Address | getDefaultAddress () |
| magic string | getEmail () |
| magic string | getFirstName () |
| magic string | getLastName () |
| magic string | getLastOrderId () |
| read-only More... | |
| magic string | getLastOrderName () |
| read-only More... | |
| magic string | getMarketingOptInLevel () |
| read-only More... | |
| magic null string | getMultipassIdentifier () |
| magic string | getNote () |
| Order[] | getOrders () |
| magic int | getOrdersCount () |
| read-only More... | |
| magic string | getPhone () |
| string[] | getPoolKeys () |
| magic string | getTags () |
| magic string[] | getTaxExemptions () |
| magic string | getTotalSpent () |
| magic string | getUpdatedAt () |
| magic bool | hasAddresses () |
| magic bool | hasPhone () |
| magic bool | hasTaxExemptions () |
| bool | isDeclined () |
| bool | isDisabled () |
| bool | isEnabled () |
| bool | isInvited () |
| magic bool | isTaxExempt () |
| magic bool | isVerifiedEmail () |
| Address | newAddress () |
| Invite | newInvite () |
| Creates an invite for an existing customer. More... | |
| magic Address[] | selectAddresses (callable $filter) |
fn( Address $address ): bool More... | |
| magic $this | setAcceptsMarketing (bool $opted) |
| magic $this | setAcceptsMarketingUpdatedAt (string $iso8601) |
| magic $this | setAddresses (Address[] $addresses) |
| magic $this | setEmail (string $email) |
| required, unique More... | |
| magic $this | setFirstName (string $name) |
| required More... | |
| magic $this | setLastName (string $name) |
| required More... | |
| magic $this | setMultipassIdentifier (?string $ident) |
| magic $this | setNote (string $note) |
| $this | setPassword (string $password) |
| magic $this | setPhone (string $e164) |
| unique More... | |
| magic $this | setSendEmailInvite (bool $invite) |
| magic $this | setSendEmailWelcome (bool $welcome) |
| magic $this | setState (string $status) |
| magic $this | setTags (string $csv) |
| magic $this | setTaxExempt (bool $exempt) |
Public Methods inherited from AbstractEntity | |
| string | __toString () |
| null string | getId () |
| bool | hasId () |
| $this | reload () |
| Fully reloads the entity from Shopify. More... | |
Public Methods inherited from Data | |
| mixed | __call (string $method, array $args) |
| __construct ($caller, array $data=[]) | |
| string | serialize () |
| Dehydrated JSON encode. More... | |
| array | toArray () |
| void | unserialize ($serialized) |
Public Methods inherited from CreateTrait | |
| $this | create () |
Public Methods inherited from DeleteTrait | |
| void | delete () |
Public Methods inherited from UpdateTrait | |
| $this | update () |
Public Methods inherited from MetafieldTrait | |
| Metafield[] | getMetafields () |
| Metafield | newMetafield () |
| Factory. More... | |
Protected Methods | |
| _setData (array $data) | |
| Clears all diffs and sets all data, hydrating mapped fields. More... | |
Protected Methods inherited from AbstractEntity | |
| null AbstractEntity | _container () |
| The container/owner object, if any. More... | |
| mixed | _get (string $field) |
| Lazy-loads missing fields. More... | |
| void | _onDelete () |
| void | _onSave () |
| void | _reload (string $field) |
Protected Methods inherited from Data | |
| mixed | _hydrate (string $class, $item) |
| A factory that also hydrates / caches entities. More... | |
| array | _select ($subject, callable $filter,... $args) |
Magic method: selectField(callable $filter) More... | |
| $this | _setField (string $field, $value) |
| Sets a value, hydrating if mapped, and clears the diff. More... | |
Protected Methods inherited from CreateTrait | |
| string | _dir () |
The POST directory. More... | |
Protected Methods inherited from MetafieldTrait | |
| string | _metafieldType () |
Additional Inherited Members | |
Public Static Methods inherited from AbstractEntity | |
| static null self | load ($caller, string $id, array $query=[]) |
| static self[] | loadAll ($caller, string $path, array $query=[]) |
| const IS_DECLINED = 'declined' |
Customer declined the invite, has no account.
| const IS_DISABLED = 'disabled' |
Customer can't log in.
This is the default.
| const IS_ENABLED = 'enabled' |
Customer can log in and shop.
| const IS_INVITED = 'invited' |
Customer needs to activate their account via invite link before logging in.
| const MAP |
|
protected |
| magic bool getAcceptsMarketing | ( | ) |
| magic string getAcceptsMarketingUpdatedAt | ( | ) |
| string getActivationUrl | ( | ) |
| magic string getCreatedAt | ( | ) |
ISO8601.
| magic string getCurrency | ( | ) |
read-only
| null Address getDefaultAddress | ( | ) |
| magic string getEmail | ( | ) |
| magic string getFirstName | ( | ) |
| magic string getLastName | ( | ) |
| magic string getLastOrderId | ( | ) |
read-only
| magic string getLastOrderName | ( | ) |
read-only
| magic string getMarketingOptInLevel | ( | ) |
read-only
| magic null string getMultipassIdentifier | ( | ) |
| magic string getNote | ( | ) |
| magic int getOrdersCount | ( | ) |
read-only
| magic string getPhone | ( | ) |
| string [] getPoolKeys | ( | ) |
Reimplemented from AbstractEntity.
| magic string getTags | ( | ) |
| magic string [] getTaxExemptions | ( | ) |
| magic string getTotalSpent | ( | ) |
| magic string getUpdatedAt | ( | ) |
| magic bool hasAddresses | ( | ) |
| magic bool hasPhone | ( | ) |
| magic bool hasTaxExemptions | ( | ) |
|
final |
|
final |
|
final |
|
final |
| magic bool isTaxExempt | ( | ) |
| magic bool isVerifiedEmail | ( | ) |
| magic $this setAcceptsMarketing | ( | bool | $opted | ) |
| magic $this setAcceptsMarketingUpdatedAt | ( | string | $iso8601 | ) |
| magic $this setEmail | ( | string | ) |
required, unique
| magic $this setFirstName | ( | string | $name | ) |
required
| magic $this setLastName | ( | string | $name | ) |
required
| magic $this setMultipassIdentifier | ( | ?string | $ident | ) |
| magic $this setNote | ( | string | $note | ) |
| $this setPassword | ( | string | $password | ) |
| string | $password |
| magic $this setPhone | ( | string | $e164 | ) |
unique
| magic $this setTags | ( | string | $csv | ) |
| magic $this setTaxExempt | ( | bool | $exempt | ) |