mirror of
https://github.com/Karaka-Management/phpOMS.git
synced 2026-02-13 15:18:41 +00:00
Automated formatting changes
This commit is contained in:
parent
8641d7610c
commit
5ba685e12b
|
|
@ -24,7 +24,7 @@ namespace phpOMS\Account;
|
||||||
*/
|
*/
|
||||||
final class NullGroup extends Group
|
final class NullGroup extends Group
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* Constructor
|
* Constructor
|
||||||
*
|
*
|
||||||
* @param int $id Model id
|
* @param int $id Model id
|
||||||
|
|
|
||||||
|
|
@ -555,7 +555,7 @@ class DataMapperAbstract implements DataMapperInterface
|
||||||
$tValue = $property->getValue($obj);
|
$tValue = $property->getValue($obj);
|
||||||
$property->setAccessible(false);
|
$property->setAccessible(false);
|
||||||
} else {
|
} else {
|
||||||
$tValue = $obj->$propertyName;
|
$tValue = $obj->{$propertyName};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isset(static::$ownsOne[$propertyName])) {
|
if (isset(static::$ownsOne[$propertyName])) {
|
||||||
|
|
@ -681,7 +681,7 @@ class DataMapperAbstract implements DataMapperInterface
|
||||||
$objectId = $refProp->getValue($obj);
|
$objectId = $refProp->getValue($obj);
|
||||||
$refProp->setAccessible(false);
|
$refProp->setAccessible(false);
|
||||||
} else {
|
} else {
|
||||||
$objectId = $obj->$propertyName;
|
$objectId = $obj->{$propertyName};
|
||||||
}
|
}
|
||||||
|
|
||||||
return $objectId;
|
return $objectId;
|
||||||
|
|
@ -709,7 +709,7 @@ class DataMapperAbstract implements DataMapperInterface
|
||||||
$refProp->setValue($obj, $objId);
|
$refProp->setValue($obj, $objId);
|
||||||
$refProp->setAccessible(false);
|
$refProp->setAccessible(false);
|
||||||
} else {
|
} else {
|
||||||
$obj->$propertyName = $objId;
|
$obj->{$propertyName} = $objId;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -764,7 +764,7 @@ class DataMapperAbstract implements DataMapperInterface
|
||||||
$property->setAccessible(true);
|
$property->setAccessible(true);
|
||||||
$values = $property->getValue($obj);
|
$values = $property->getValue($obj);
|
||||||
} else {
|
} else {
|
||||||
$values = $obj->$propertyName;
|
$values = $obj->{$propertyName};
|
||||||
}
|
}
|
||||||
|
|
||||||
/** @var self $mapper */
|
/** @var self $mapper */
|
||||||
|
|
@ -781,7 +781,7 @@ class DataMapperAbstract implements DataMapperInterface
|
||||||
$relProperty->setValue($values, $objId);
|
$relProperty->setValue($values, $objId);
|
||||||
$relProperty->setAccessible(false);
|
$relProperty->setAccessible(false);
|
||||||
} else {
|
} else {
|
||||||
$values->$internalName = $objId;
|
$values->{$internalName} = $objId;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!$isPublic) {
|
if (!$isPublic) {
|
||||||
|
|
@ -839,13 +839,13 @@ class DataMapperAbstract implements DataMapperInterface
|
||||||
if (!$isPublic) {
|
if (!$isPublic) {
|
||||||
$relProperty->setValue($value, self::createNullModel($objId));
|
$relProperty->setValue($value, self::createNullModel($objId));
|
||||||
} else {
|
} else {
|
||||||
$value->$internalName = self::createNullModel($objId);
|
$value->{$internalName} = self::createNullModel($objId);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (!$isPublic) {
|
if (!$isPublic) {
|
||||||
$relProperty->setValue($value, $objId);
|
$relProperty->setValue($value, $objId);
|
||||||
} else {
|
} else {
|
||||||
$value->$internalName = $objId;
|
$value->{$internalName} = $objId;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1140,7 +1140,7 @@ class DataMapperAbstract implements DataMapperInterface
|
||||||
$values = $property->getValue($obj);
|
$values = $property->getValue($obj);
|
||||||
$property->setAccessible(false);
|
$property->setAccessible(false);
|
||||||
} else {
|
} else {
|
||||||
$values = $obj->$propertyName;
|
$values = $obj->{$propertyName};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!\is_array($values)) {
|
if (!\is_array($values)) {
|
||||||
|
|
@ -1184,7 +1184,7 @@ class DataMapperAbstract implements DataMapperInterface
|
||||||
$relProperty->setValue($value, $objId);
|
$relProperty->setValue($value, $objId);
|
||||||
$relProperty->setAccessible(false);
|
$relProperty->setAccessible(false);
|
||||||
} else {
|
} else {
|
||||||
$value->$mapper::$columns[static::$hasMany[$propertyName]['self']]['internal'] = $objId;
|
$value->{$mapper}::$columns[static::$hasMany[$propertyName]['self']]['internal'] = $objId;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1457,7 +1457,7 @@ class DataMapperAbstract implements DataMapperInterface
|
||||||
$tValue = $property->getValue($obj);
|
$tValue = $property->getValue($obj);
|
||||||
$property->setAccessible(false);
|
$property->setAccessible(false);
|
||||||
} else {
|
} else {
|
||||||
$tValue = $obj->$propertyName;
|
$tValue = $obj->{$propertyName};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isset(static::$ownsOne[$propertyName])) {
|
if (isset(static::$ownsOne[$propertyName])) {
|
||||||
|
|
@ -1678,7 +1678,7 @@ class DataMapperAbstract implements DataMapperInterface
|
||||||
$values = $property->getValue($obj);
|
$values = $property->getValue($obj);
|
||||||
$property->setAccessible(false);
|
$property->setAccessible(false);
|
||||||
} else {
|
} else {
|
||||||
$values = $obj->$propertyName;
|
$values = $obj->{$propertyName};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!\is_array($values)) {
|
if (!\is_array($values)) {
|
||||||
|
|
@ -1812,7 +1812,7 @@ class DataMapperAbstract implements DataMapperInterface
|
||||||
* The exception is of course the belongsTo relation.
|
* The exception is of course the belongsTo relation.
|
||||||
*/
|
*/
|
||||||
foreach (static::$columns as $key => $column) {
|
foreach (static::$columns as $key => $column) {
|
||||||
$value = $isPublic ? $obj->$propertyName : $property->getValue($obj);
|
$value = $isPublic ? $obj->{$propertyName} : $property->getValue($obj);
|
||||||
if (self::$relations === RelationType::ALL
|
if (self::$relations === RelationType::ALL
|
||||||
&& isset(static::$ownsOne[$propertyName])
|
&& isset(static::$ownsOne[$propertyName])
|
||||||
&& $column['internal'] === $propertyName
|
&& $column['internal'] === $propertyName
|
||||||
|
|
@ -1989,7 +1989,7 @@ class DataMapperAbstract implements DataMapperInterface
|
||||||
);
|
);
|
||||||
$refProp->setAccessible(false);
|
$refProp->setAccessible(false);
|
||||||
} else {
|
} else {
|
||||||
$obj->$member = !\is_array($objects) && !isset(static::$hasMany[$member]['conditional'])
|
$obj->{$member} = !\is_array($objects) && !isset(static::$hasMany[$member]['conditional'])
|
||||||
? [$mapper::getObjectId($objects) => $objects]
|
? [$mapper::getObjectId($objects) => $objects]
|
||||||
: $objects;
|
: $objects;
|
||||||
}
|
}
|
||||||
|
|
@ -2365,7 +2365,7 @@ class DataMapperAbstract implements DataMapperInterface
|
||||||
|
|
||||||
$refProp->setValue($obj, \json_decode($value, true));
|
$refProp->setValue($obj, \json_decode($value, true));
|
||||||
} elseif ($def['mapper']::$columns[$column]['type'] === 'Serializable') {
|
} elseif ($def['mapper']::$columns[$column]['type'] === 'Serializable') {
|
||||||
$member = $isPublic ? $obj->$member : $refProp->getValue($obj);
|
$member = $isPublic ? $obj->{$member} : $refProp->getValue($obj);
|
||||||
$member->unserialize($value);
|
$member->unserialize($value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -338,8 +338,8 @@ final class HttpRequest extends RequestAbstract
|
||||||
}
|
}
|
||||||
|
|
||||||
// @codeCoverageIgnoreStart
|
// @codeCoverageIgnoreStart
|
||||||
$components = \explode(';', $_SERVER['HTTP_ACCEPT_LANGUAGE']);
|
$components = \explode(';', $_SERVER['HTTP_ACCEPT_LANGUAGE']);
|
||||||
$locals = \stripos($components[0], ',') !== false
|
$locals = \stripos($components[0], ',') !== false
|
||||||
? $locals = \explode(',', $components[0])
|
? $locals = \explode(',', $components[0])
|
||||||
: $components;
|
: $components;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user