getRequest()->getParam('id'); } public function getRewardData(): array { $customerId = $this->getCustomerId(); if ($customerId <= 0) { return []; } $customer = $this->customers->getById($customerId); $account = $this->balanceManager->getAccount($customerId, (int)$customer->getWebsiteId()); $account['tier'] = $this->tierResolver->resolveEffective((string)$account['tier_code'], (float)$account['lifetime_spend_base']); return $account; } public function getTransactions(): array { return $this->getCustomerId() > 0 ? $this->balanceManager->getTransactions($this->getCustomerId(), 20) : []; } public function getAdjustUrl(): string { return $this->getUrl('esun_reward/customer/adjust'); } public function getSocialPoints(): int { return $this->config->socialPoints(); } }