feat: added option to hide stripe billing links from dashboard
This commit is contained in:
@@ -16,6 +16,7 @@ class Dashboard extends Component
|
|||||||
public $usageLog;
|
public $usageLog;
|
||||||
public $subscription;
|
public $subscription;
|
||||||
public $plans;
|
public $plans;
|
||||||
|
public $showStripeBilling = false;
|
||||||
|
|
||||||
public function paymentStatus(Request $request)
|
public function paymentStatus(Request $request)
|
||||||
{
|
{
|
||||||
@@ -184,6 +185,7 @@ class Dashboard extends Component
|
|||||||
foreach (config('app.plans') as $plan) {
|
foreach (config('app.plans') as $plan) {
|
||||||
if ($plan['pricing_id'] === $userPriceID) {
|
if ($plan['pricing_id'] === $userPriceID) {
|
||||||
$planName = $plan['name'];
|
$planName = $plan['name'];
|
||||||
|
$this->showStripeBilling = $plan['accept_stripe'];
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -31,7 +31,10 @@
|
|||||||
@if($subscription['ends_at'] ?? "") end at<span class="app-primary"> {{ \Carbon\Carbon::make($subscription['ends_at'])->toFormattedDayDateString() ?? "" }}.</span>
|
@if($subscription['ends_at'] ?? "") end at<span class="app-primary"> {{ \Carbon\Carbon::make($subscription['ends_at'])->toFormattedDayDateString() ?? "" }}.</span>
|
||||||
@else auto-renew as per the plan you chose.
|
@else auto-renew as per the plan you chose.
|
||||||
@endif
|
@endif
|
||||||
To manage you subscription <a href="{{ route('billing') }}" target="_blank" class="text-blue-500">Click here</a></p>
|
@if($showStripeBilling)
|
||||||
|
To manage you subscription <a href="{{ route('billing') }}" target="_blank" class="text-blue-500">Click here</a>
|
||||||
|
@endif
|
||||||
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</article>
|
</article>
|
||||||
@else
|
@else
|
||||||
|
|||||||
Reference in New Issue
Block a user