DbUserAgreementRepository
final class DbUserAgreementRepository implements UserAgreementRepositoryInterface (View source)
SQL persistence for accepted user agreement versions in the user_agreements table.
Methods
bool
hasUserAcceptedAgreement(int $userId, string $version)
No description
bool
recordAcceptance(int $userId, string $version, string $ipAddress, string $userAgent)
Stores the acceptance, or refreshes it when the user already accepted this version.
array
getUserAgreements(int $userId)
The user's acceptances, newest first.
array
getAllAgreements()
No description
Details
__construct(PDO $db, ConfigurationInterface $config)
No description
bool
hasUserAcceptedAgreement(int $userId, string $version)
No description
bool
recordAcceptance(int $userId, string $version, string $ipAddress, string $userAgent)
Stores the acceptance, or refreshes it when the user already accepted this version.
array
getUserAgreements(int $userId)
The user's acceptances, newest first.
array
getAllAgreements()
No description