mirror of
https://github.com/wallabag/wallabag.git
synced 2024-05-31 23:48:06 +00:00
33 lines
728 B
PHP
33 lines
728 B
PHP
<?php
|
|
|
|
namespace Wallabag\Entity\Api;
|
|
|
|
use Doctrine\ORM\Mapping as ORM;
|
|
use FOS\OAuthServerBundle\Entity\AccessToken as BaseAccessToken;
|
|
|
|
/**
|
|
* @ORM\Table("oauth2_access_tokens")
|
|
* @ORM\Entity
|
|
*/
|
|
class AccessToken extends BaseAccessToken
|
|
{
|
|
/**
|
|
* @ORM\Id
|
|
* @ORM\Column(type="integer")
|
|
* @ORM\GeneratedValue(strategy="AUTO")
|
|
*/
|
|
protected $id;
|
|
|
|
/**
|
|
* @ORM\ManyToOne(targetEntity="Wallabag\Entity\Api\Client", inversedBy="accessTokens")
|
|
* @ORM\JoinColumn(nullable=false)
|
|
*/
|
|
protected $client;
|
|
|
|
/**
|
|
* @ORM\ManyToOne(targetEntity="Wallabag\Entity\User")
|
|
* @ORM\JoinColumn(name="user_id", referencedColumnName="id", onDelete="CASCADE")
|
|
*/
|
|
protected $user;
|
|
}
|