mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-06-27 04:08:57 +02:00
Started to move doctrine annotations to attributes (rector automated)
This commit is contained in:
parent
bb1285c35c
commit
0bc4699cdc
73 changed files with 483 additions and 604 deletions
|
@ -84,11 +84,7 @@ use App\Entity\UserSystem\User;
|
|||
use Doctrine\ORM\Mapping as ORM;
|
||||
use InvalidArgumentException;
|
||||
|
||||
/**
|
||||
* @ORM\Entity()
|
||||
* This log entry is created when an element is deleted, that is used in a collection of another entity.
|
||||
* This is needed to signal time travel, that it has to undelete the deleted entity.
|
||||
*/
|
||||
#[ORM\Entity]
|
||||
class CollectionElementDeleted extends AbstractLogEntry implements LogWithEventUndoInterface
|
||||
{
|
||||
protected string $typeString = 'collection_element_deleted';
|
||||
|
|
|
@ -25,9 +25,7 @@ namespace App\Entity\LogSystem;
|
|||
use App\Exceptions\LogEntryObsoleteException;
|
||||
use Doctrine\ORM\Mapping as ORM;
|
||||
|
||||
/**
|
||||
* @ORM\Entity()
|
||||
*/
|
||||
#[ORM\Entity]
|
||||
class ConfigChangedLogEntry extends AbstractLogEntry
|
||||
{
|
||||
protected string $typeString = 'config_changed';
|
||||
|
|
|
@ -24,9 +24,7 @@ namespace App\Entity\LogSystem;
|
|||
|
||||
use Doctrine\ORM\Mapping as ORM;
|
||||
|
||||
/**
|
||||
* @ORM\Entity()
|
||||
*/
|
||||
#[ORM\Entity]
|
||||
class DatabaseUpdatedLogEntry extends AbstractLogEntry
|
||||
{
|
||||
protected string $typeString = 'database_updated';
|
||||
|
|
|
@ -30,9 +30,7 @@ use App\Entity\UserSystem\User;
|
|||
use Doctrine\ORM\Mapping as ORM;
|
||||
use InvalidArgumentException;
|
||||
|
||||
/**
|
||||
* @ORM\Entity()
|
||||
*/
|
||||
#[ORM\Entity]
|
||||
class ElementCreatedLogEntry extends AbstractLogEntry implements LogWithCommentInterface, LogWithEventUndoInterface
|
||||
{
|
||||
protected string $typeString = 'element_created';
|
||||
|
|
|
@ -32,9 +32,7 @@ use App\Entity\UserSystem\User;
|
|||
use Doctrine\ORM\Mapping as ORM;
|
||||
use InvalidArgumentException;
|
||||
|
||||
/**
|
||||
* @ORM\Entity()
|
||||
*/
|
||||
#[ORM\Entity]
|
||||
class ElementDeletedLogEntry extends AbstractLogEntry implements TimeTravelInterface, LogWithCommentInterface, LogWithEventUndoInterface
|
||||
{
|
||||
protected string $typeString = 'element_deleted';
|
||||
|
|
|
@ -30,9 +30,7 @@ use App\Entity\Contracts\TimeTravelInterface;
|
|||
use Doctrine\ORM\Mapping as ORM;
|
||||
use InvalidArgumentException;
|
||||
|
||||
/**
|
||||
* @ORM\Entity()
|
||||
*/
|
||||
#[ORM\Entity]
|
||||
class ElementEditedLogEntry extends AbstractLogEntry implements TimeTravelInterface, LogWithCommentInterface, LogWithEventUndoInterface, LogWithNewDataInterface
|
||||
{
|
||||
protected string $typeString = 'element_edited';
|
||||
|
|
|
@ -25,9 +25,7 @@ namespace App\Entity\LogSystem;
|
|||
use App\Exceptions\LogEntryObsoleteException;
|
||||
use Doctrine\ORM\Mapping as ORM;
|
||||
|
||||
/**
|
||||
* @ORM\Entity()
|
||||
*/
|
||||
#[ORM\Entity]
|
||||
class ExceptionLogEntry extends AbstractLogEntry
|
||||
{
|
||||
protected string $typeString = 'exception';
|
||||
|
|
|
@ -24,9 +24,7 @@ namespace App\Entity\LogSystem;
|
|||
|
||||
use Doctrine\ORM\Mapping as ORM;
|
||||
|
||||
/**
|
||||
* @ORM\Entity()
|
||||
*/
|
||||
#[ORM\Entity]
|
||||
class LegacyInstockChangedLogEntry extends AbstractLogEntry
|
||||
{
|
||||
protected string $typeString = 'instock_changed';
|
||||
|
|
|
@ -23,9 +23,7 @@ namespace App\Entity\LogSystem;
|
|||
use App\Entity\Parts\PartLot;
|
||||
use Doctrine\ORM\Mapping as ORM;
|
||||
|
||||
/**
|
||||
* @ORM\Entity()
|
||||
*/
|
||||
#[ORM\Entity]
|
||||
class PartStockChangedLogEntry extends AbstractLogEntry
|
||||
{
|
||||
public const TYPE_ADD = "add";
|
||||
|
|
|
@ -50,9 +50,8 @@ use Symfony\Component\HttpFoundation\IpUtils;
|
|||
|
||||
/**
|
||||
* This log entry is created when something security related to a user happens.
|
||||
*
|
||||
* @ORM\Entity()
|
||||
*/
|
||||
#[ORM\Entity]
|
||||
class SecurityEventLogEntry extends AbstractLogEntry
|
||||
{
|
||||
public const SECURITY_TYPE_MAPPING = [
|
||||
|
|
|
@ -27,9 +27,8 @@ use Symfony\Component\HttpFoundation\IpUtils;
|
|||
|
||||
/**
|
||||
* This log entry is created when a user logs in.
|
||||
*
|
||||
* @ORM\Entity()
|
||||
*/
|
||||
#[ORM\Entity]
|
||||
class UserLoginLogEntry extends AbstractLogEntry
|
||||
{
|
||||
protected string $typeString = 'user_login';
|
||||
|
|
|
@ -25,9 +25,7 @@ namespace App\Entity\LogSystem;
|
|||
use Doctrine\ORM\Mapping as ORM;
|
||||
use Symfony\Component\HttpFoundation\IpUtils;
|
||||
|
||||
/**
|
||||
* @ORM\Entity()
|
||||
*/
|
||||
#[ORM\Entity]
|
||||
class UserLogoutLogEntry extends AbstractLogEntry
|
||||
{
|
||||
protected string $typeString = 'user_logout';
|
||||
|
|
|
@ -24,9 +24,7 @@ namespace App\Entity\LogSystem;
|
|||
|
||||
use Doctrine\ORM\Mapping as ORM;
|
||||
|
||||
/**
|
||||
* @ORM\Entity()
|
||||
*/
|
||||
#[ORM\Entity]
|
||||
class UserNotAllowedLogEntry extends AbstractLogEntry
|
||||
{
|
||||
protected string $typeString = 'user_not_allowed';
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue