CRM V2

WPCrmQuestion
in package

Class de gestion de la segmentation question avec Wordpress (ce truc immonde)

Tags
category

API

subpackage

Wordpress

author

Jérémy Munsch jeremy.munsch@ldc.fr

license

MIT https://opensource.org/licenses/MIT

link
/

Table of Contents

allWithCustomerAnswers()  : array<string|int, mixed>
Get all the questions with user answers
getAll()  : array<string|int, mixed>
Get all questions only
unansweredBy()  : array<string|int, Question>
Get unanswered question for a specific customer
getRawProperty()  : mixed
Get a property

Methods

allWithCustomerAnswers()

Get all the questions with user answers

public static allWithCustomerAnswers(WPCrmUser $user) : array<string|int, mixed>
Parameters
$user : WPCrmUser
Tags
throws
CrmException

if an error occurs on server side or on getting response

throws
ApiErrorException

If any error or \LDC\LDCCRM\Enums\ApiError occurs

Return values
array<string|int, mixed> —

[ 0 => [ 'question' => \LDC\LDCCRM\Models\Question, 'customerAnswers' => \LDC\LDCCRM\Models\Answer[] ] ]

with \LDC\LDCCRM\Models\Question[] and the customer \LDC\LDCCRM\Models\Answer[]

getAll()

Get all questions only

public static getAll() : array<string|int, mixed>
Tags
throws
CrmException

if an error occurs on server side or on getting response

throws
ApiErrorException

If any error or \LDC\LDCCRM\Enums\ApiError occurs

Return values
array<string|int, mixed> —

with \LDC\LDCCRM\Models\Question[]

getRawProperty()

Get a property

protected static getRawProperty(object $object, string $field) : mixed
Parameters
$object : object
$field : string
Return values
mixed —

Search results