PurchaseCreditsService
class PurchaseCreditsService implements PurchaseCreditsServiceInterface
PurchaseCreditsService class
Properties
private ConfigServiceInterface | $configService | Stores ConfigServiceInterface | |
private EntityManagerInterface | $em | Stores EntityManagerInterface | |
private PurchaseCreditsEmailInterface | $purchaseCreditsEmail | Stores PurchaseCreditsEmailInterface | |
private PurchaseCreditsFormFactoryInterface | $purchaseCreditsFormFactory | Stores PurchaseCreditsFormFactoryInterface | |
private ServiceToolsInterface | $serviceTools | Stores ServiceToolsInterface | |
private Request | $request | Stores current Request | |
private TransactionServiceInterface | $transactionService | Stores TransactionServiceInterface | |
private TranslatorInterface | $translator | Stores TranslatorInterface |
Methods
__construct(ConfigServiceInterface $configService, EntityManagerInterface $em, PurchaseCreditsEmailInterface $purchaseCreditsEmail, PurchaseCreditsFormFactoryInterface $purchaseCreditsFormFactory, ServiceToolsInterface $serviceTools, RequestStack $requestStack, TransactionServiceInterface $transactionService, TranslatorInterface $translator)
No description
create()
Creates the PurchaseCredits
Form
createForm(string $name, PurchaseCredits $purchaseCredits, int $credits, array $priceChoices)
Shortcut to call PurchaseCreditsFormFactory to create Form
array
getPrices()
Gets prices for credits
array
getPricesChoice()
Gets prices choice labels for credits
Details
at line 80
__construct(ConfigServiceInterface $configService, EntityManagerInterface $em, PurchaseCreditsEmailInterface $purchaseCreditsEmail, PurchaseCreditsFormFactoryInterface $purchaseCreditsFormFactory, ServiceToolsInterface $serviceTools, RequestStack $requestStack, TransactionServiceInterface $transactionService, TranslatorInterface $translator)
at line 104
PurchaseCredits
create()
Creates the PurchaseCredits
at line 117
Form
createForm(string $name, PurchaseCredits $purchaseCredits, int $credits, array $priceChoices)
Shortcut to call PurchaseCreditsFormFactory to create Form
at line 125
array
getPrices()
Gets prices for credits
at line 144
array
getPricesChoice()
Gets prices choice labels for credits
at line 166
define(PurchaseCredits $purchaseCredits)
Registers the PurchaseCredits
at line 177
bool
validate(Payment $payment)
Validate the credits purchased