Function post
has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring. Open
public function post()
{
$relatedModule = 'Approvals';
$referenceFieldModel = null;
$queryGenerator = (new \App\QueryGenerator($this->controller->request->getModule()));
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method post
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function post()
{
$relatedModule = 'Approvals';
$referenceFieldModel = null;
$queryGenerator = (new \App\QueryGenerator($this->controller->request->getModule()));
The method post() has a Cyclomatic Complexity of 11. The configured cyclomatic complexity threshold is 10. Open
public function post()
{
$relatedModule = 'Approvals';
$referenceFieldModel = null;
$queryGenerator = (new \App\QueryGenerator($this->controller->request->getModule()));
- Read upRead up
- Exclude checks
CyclomaticComplexity
Since: 0.1
Complexity is determined by the number of decision points in a method plus one for the method entry. The decision points are 'if', 'while', 'for', and 'case labels'. Generally, 1-4 is low complexity, 5-7 indicates moderate complexity, 8-10 is high complexity, and 11+ is very high complexity.
Example
// Cyclomatic Complexity = 11
class Foo {
1 public function example() {
2 if ($a == $b) {
3 if ($a1 == $b1) {
fiddle();
4 } elseif ($a2 == $b2) {
fiddle();
} else {
fiddle();
}
5 } elseif ($c == $d) {
6 while ($c == $d) {
fiddle();
}
7 } elseif ($e == $f) {
8 for ($n = 0; $n < $h; $n++) {
fiddle();
}
} else {
switch ($z) {
9 case 1:
fiddle();
break;
10 case 2:
fiddle();
break;
11 case 3:
fiddle();
break;
default:
fiddle();
break;
}
}
}
}
Source https://phpmd.org/rules/codesize.html#cyclomaticcomplexity
Missing class import via use statement (line '114', column '26'). Open
$queryGenerator = (new \App\QueryGenerator($this->controller->request->getModule()));
- Read upRead up
- Exclude checks
MissingImport
Since: 2.7.0
Importing all external classes in a file through use statements makes them clearly visible.
Example
function make() {
return new \stdClass();
}
Source http://phpmd.org/rules/cleancode.html#MissingImport
Missing class import via use statement (line '129', column '14'). Open
throw new \Api\Core\Exception('Not Found', 404);
- Read upRead up
- Exclude checks
MissingImport
Since: 2.7.0
Importing all external classes in a file through use statements makes them clearly visible.
Example
function make() {
return new \stdClass();
}
Source http://phpmd.org/rules/cleancode.html#MissingImport
Avoid assigning values to variables in if clauses and the like (line '133', column '7'). Open
public function post()
{
$relatedModule = 'Approvals';
$referenceFieldModel = null;
$queryGenerator = (new \App\QueryGenerator($this->controller->request->getModule()));
- Read upRead up
- Exclude checks
IfStatementAssignment
Since: 2.7.0
Assignments in if clauses and the like are considered a code smell. Assignments in PHP return the right operand as their result. In many cases, this is an expected behavior, but can lead to many difficult to spot bugs, especially when the right operand could result in zero, null or an empty string and the like.
Example
class Foo
{
public function bar($flag)
{
if ($foo = 'bar') { // possible typo
// ...
}
if ($baz = 0) { // always false
// ...
}
}
}
Source http://phpmd.org/rules/cleancode.html#ifstatementassignment
Avoid using static access to class '\App\Record' in method 'post'. Open
if (!\App\Record::isExists($recordId)) {
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid assigning values to variables in if clauses and the like (line '124', column '13'). Open
public function post()
{
$relatedModule = 'Approvals';
$referenceFieldModel = null;
$queryGenerator = (new \App\QueryGenerator($this->controller->request->getModule()));
- Read upRead up
- Exclude checks
IfStatementAssignment
Since: 2.7.0
Assignments in if clauses and the like are considered a code smell. Assignments in PHP return the right operand as their result. In many cases, this is an expected behavior, but can lead to many difficult to spot bugs, especially when the right operand could result in zero, null or an empty string and the like.
Example
class Foo
{
public function bar($flag)
{
if ($foo = 'bar') { // possible typo
// ...
}
if ($baz = 0) { // always false
// ...
}
}
}
Source http://phpmd.org/rules/cleancode.html#ifstatementassignment
Call to method getModuleModel
from undeclared class \App\QueryGenerator
(Did you mean class \Tests\App\QueryGenerator) Open
foreach ($queryGenerator->getModuleModel()->getFieldsByType('multiReference', true) as $fieldModel) {
- Exclude checks
Call to method getModuleModel
from undeclared class \App\QueryGenerator
(Did you mean class \Tests\App\QueryGenerator) Open
$fieldToken = current($queryGenerator->getModuleModel()->getFieldsByType('token', true));
- Exclude checks
Call to method __construct
from undeclared class \App\QueryGenerator
(Did you mean class \Tests\App\QueryGenerator) Open
$queryGenerator = (new \App\QueryGenerator($this->controller->request->getModule()));
- Exclude checks
Variable $recordData
is undeclared Open
'id' => $recordData['id'],
- Exclude checks
Call to method setFields
from undeclared class \App\QueryGenerator
(Did you mean class \Tests\App\QueryGenerator) Open
|| empty($recordData = $queryGenerator->setFields(['id', $referenceFieldModel->getName()])
- Exclude checks
Possibly zero references to use statement for classlike/namespace OA
(\OpenApi\Annotations)
Open
use OpenApi\Annotations as OA;
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Schema(ref="#/components/schemas/BaseModule_Post_GetConsentsForEntry_Request")
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\RequestBody(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Schema(ref="#/components/schemas/BaseModule_Post_GetConsentsForEntry_Request")
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\MediaType(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* {"basicAuth" : {}, "ApiKeyAuth" : {}, "token" : {}}
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* },
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="Required data for communication",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* },
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Response(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Response(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Response(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* title="Request body for GetConsentsForEntry",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* type="object",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* property="result",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* property="id",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
$queryGenerator = (new \App\QueryGenerator($this->controller->request->getModule()));
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
}
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
|| !$fieldToken
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* summary="Gets the list of consents for specific entry",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* required=true,
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\JsonContent(ref="#/components/schemas/BaseModule_Post_GetConsentsForEntry_Request"),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\MediaType(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* mediaType="multipart/form-data",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Response(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* type="string"
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* type="object",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="Record ID",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
$referenceFieldModel = $fieldModel;
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
'consents' => $consents
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Schema(ref="#/components/schemas/BaseModule_Post_GetConsentsForEntry_Request")
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* tags={"BaseModule"},
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* mediaType="application/x-www-form-urlencoded",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="`No sent token` OR `Invalid token`",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="No permissions for module",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* response=405,
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* example=24842
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* example=24842
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* type="object",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="Get the edit value in display view",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
foreach ($queryGenerator->getModuleModel()->getFieldsByType('multiReference', true) as $fieldModel) {
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
if ($fieldModel->isActiveField() && $fieldModel->getReferenceList() === [$relatedModule]) {
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
'id' => $recordData['id'],
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
];
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\JsonContent(ref="#/components/schemas/BaseModule_Post_GetConsentsForEntry_Response"),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="`No sent token` OR `Invalid token`",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="No permissions for module",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Property(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Property(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
public function post()
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
->one())
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
) {
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* security={
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="Method Not Allowed",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* property="token",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* property="token",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="Entry unique ID (Token type field in the module is required)",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* title="Response body for GetConsentsForEntry",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* type="object",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\AdditionalProperties(description="Data from the associated module", type="integer", example=24862),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
if (!$referenceFieldModel
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
throw new \Api\Core\Exception('Not Found', 404);
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
return [
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
}
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* security={
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* response=401,
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* response=404,
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Schema(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="Entry unique ID (Token type field in the module is required)",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Property(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* property="consents",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* )
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
break;
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
if (!\App\Record::isExists($recordId)) {
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
}
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* tags={"BaseModule"},
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* {"basicAuth" : {}, "ApiKeyAuth" : {}, "token" : {}}
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* required=true,
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\JsonContent(ref="#/components/schemas/BaseModule_Post_GetConsentsForEntry_Request"),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\MediaType(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* response=401,
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* response=403,
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* type="object",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* title="Response body for GetConsentsForEntry",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
$fieldToken = current($queryGenerator->getModuleModel()->getFieldsByType('token', true));
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* property="result",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\MediaType(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="Not Found",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* response=405,
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* schema="BaseModule_Post_GetConsentsForEntry_Request",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* type="object",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* type="integer",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
$referenceFieldModel = null;
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
|| empty($recordData = $queryGenerator->setFields(['id', $referenceFieldModel->getName()])
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* summary="Gets the list of consents for specific entry",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="Required data for communication",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Response(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* response=404,
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Property(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* property="id",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="Specific response",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\AdditionalProperties(description="Data from the associated module", type="integer", example=24862),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
*/
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
foreach ($consents as $key => $recordId) {
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Parameter(name="moduleName", in="path", @OA\Schema(type="string"), description="Module name", required=true, example="Contacts"),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="List of consents for specific entry",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\JsonContent(ref="#/components/schemas/BaseModule_Post_GetConsentsForEntry_Response"),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Schema(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Property(property="status", type="integer", enum={0, 1}, description="A numeric value of 0 or 1 that indicates whether the communication is valid. 1 - success , 0 - error"),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Property(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Property(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="Record ID",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="Get the edit value in display view",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
->createQuery()
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
}
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Response(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Response(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Response(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="Not Found",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* schema="BaseModule_Post_GetConsentsForEntry_Response",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Property(property="status", type="integer", enum={0, 1}, description="A numeric value of 0 or 1 that indicates whether the communication is valid. 1 - success , 0 - error"),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="Specific response",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* type="object",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* type="integer",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Property(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
->addCondition($fieldToken->getName(), $this->controller->request->getByType('token', \App\Purifier::ALNUM), 'e')
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
}
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
$referenceUiTypeModel = $referenceFieldModel->getUITypeModel();
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="Method Not Allowed",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* type="object",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* type="string"
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* schema="BaseModule_Post_GetConsentsForEntry_Response",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* path="/webservice/ManageConsents/{moduleName}/GetConsentsForEntry",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* mediaType="multipart/form-data",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* )
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* mediaType="application/x-www-form-urlencoded",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
{
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Schema(ref="#/components/schemas/BaseModule_Post_GetConsentsForEntry_Request")
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
$relatedModule = 'Approvals';
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* response=200,
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
}
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* description="List of consents for specific entry",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Response(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
unset($consents[$key]);
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* schema="BaseModule_Post_GetConsentsForEntry_Request",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* title="Request body for GetConsentsForEntry",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Property(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
}
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\RequestBody(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Parameter(name="moduleName", in="path", @OA\Schema(type="string"), description="Module name", required=true, example="Contacts"),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* @OA\Response(
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* response=200,
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* response=403,
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* property="consents",
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
* ),
- Exclude checks
Spaces must be used for alignment; tabs are not allowed Open
if ($consents = $referenceUiTypeModel->getArrayValues($recordData[$referenceFieldModel->getName()]) ?: []) {
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
*
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
*
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
* @throws \Api\Core\Exception
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
*
- Exclude checks
Line exceeds 120 characters; contains 129 characters Open
->addCondition($fieldToken->getName(), $this->controller->request->getByType('token', \App\Purifier::ALNUM), 'e')
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
/**
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
* @OA\Post(
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
* path="/webservice/ManageConsents/{moduleName}/GetConsentsForEntry",
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
public $allowedMethod = ['POST'];
- Exclude checks
Line exceeds 120 characters; contains 123 characters Open
* @OA\AdditionalProperties(description="Data from the associated module", type="integer", example=24862),
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
/** {@inheritdoc} */
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
* Gets consents.
- Exclude checks
Line exceeds 120 characters; contains 145 characters Open
* @OA\Parameter(name="moduleName", in="path", @OA\Schema(type="string"), description="Module name", required=true, example="Contacts"),
- Exclude checks
Line exceeds 120 characters; contains 189 characters Open
* @OA\Property(property="status", type="integer", enum={0, 1}, description="A numeric value of 0 or 1 that indicates whether the communication is valid. 1 - success , 0 - error"),
- Exclude checks
Spaces must be used to indent lines; tabs are not allowed Open
* @return array
- Exclude checks