Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F117894234
D4579.1775368810.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Authored By
Unknown
Size
1 KB
Referenced Files
None
Subscribers
None
D4579.1775368810.diff
View Options
diff --git a/src/app/Http/Controllers/API/V4/PaymentsController.php b/src/app/Http/Controllers/API/V4/PaymentsController.php
--- a/src/app/Http/Controllers/API/V4/PaymentsController.php
+++ b/src/app/Http/Controllers/API/V4/PaymentsController.php
@@ -405,12 +405,24 @@
return false;
}
+ $appName = Tenant::getConfig($wallet->owner->tenant_id, 'app.name');
+ $description = "{$appName} Recurring Payment";
+ if ($plan = $wallet->plan()) {
+ if ($plan->months == 12) {
+ $description = "{$appName} Annual Payment";
+ } elseif ($plan->months == 3) {
+ $description = "{$appName} Quarterly Payment";
+ } elseif ($plan->months == 1) {
+ $description = "{$appName} Monthly Payment";
+ }
+ }
+
$request = [
'type' => Payment::TYPE_RECURRING,
'currency' => $wallet->currency,
'amount' => $amount,
'methodId' => PaymentProvider::METHOD_CREDITCARD,
- 'description' => Tenant::getConfig($wallet->owner->tenant_id, 'app.name') . ' Recurring Payment',
+ 'description' => $description,
];
self::addTax($wallet, $request);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Apr 5, 6:00 AM (18 h, 8 m ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
18832575
Default Alt Text
D4579.1775368810.diff (1 KB)
Attached To
Mode
D4579: Make recurring payment description different for different plan periods
Attached
Detach File
Event Timeline