Skip to content

Commit 47eddfd

Browse files
authored
Merge pull request #1155 from itflow-org/rec-payment-stripe
Autopay
2 parents 706a77c + 071352e commit 47eddfd

File tree

4 files changed

+11
-5
lines changed

4 files changed

+11
-5
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22

33
This file documents all notable changes made to ITFlow.
44

5+
## [UNRELEASED]
6+
7+
### Fixed
8+
- Stripe now shows as a payment option in the add recurring payment modal
9+
510
## [25.01]
611

712
### Added / Changed

modals/recurring_payment_add_modal.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,9 @@
4848
</div>
4949
<select class="form-control select2" name="payment_method" required>
5050
<option value="">- Method of Payment -</option>
51+
<?php if ($config_stripe_enable) { ?>
52+
<option value="Stripe">Stripe</option>
53+
<?php } ?>
5154
<?php
5255

5356
$sql_payment_method_select = mysqli_query($mysqli, "SELECT * FROM categories WHERE category_type = 'Payment Method' AND category_archived_at IS NULL ORDER BY category_name ASC");

post/user/invoice.php

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1430,9 +1430,6 @@
14301430

14311431
$_SESSION['alert_type'] = "error";
14321432
$_SESSION['alert_message'] = "Auto Payment Removed for Recurring Invoice <strong>$recurring_prefix$recurring_number</strong>";
1433-
if ($config_stripe_enable) {
1434-
$_SESSION['alert_message'] = "Auto Payment Removed - Stripe Auto payments must be manually removed in Stripe";
1435-
}
14361433

14371434
header("Location: " . $_SERVER["HTTP_REFERER"]);
14381435

recurring_invoice.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,9 @@
6262
}
6363
$recurring_payment_id = intval($row['recurring_payment_id']);
6464
$recurring_payment_recurring_invoice_id = intval($row['recurring_payment_recurring_invoice_id']);
65+
$recurring_payment_method = nullable_htmlentities($row['recurring_payment_method']);
6566

66-
// Override Tab Title // No Sanitizing needed as this var will opnly be used in the tab title
67+
// Override Tab Title // No Sanitizing needed as this var will only be used in the tab title
6768
$tab_title = $row['client_name'];
6869
$page_title = "{$row['recurring_prefix']}{$row['recurring_number']}";
6970

@@ -131,7 +132,7 @@
131132

132133
<?php if ($recurring_payment_recurring_invoice_id) { ?>
133134
<a class="btn btn-outline-secondary" href="post.php?delete_recurring_payment=<?php echo $recurring_payment_id; ?>">
134-
<i class="fas fa-fw fa-times-circle mr-2"></i>Disable AutoPay
135+
<i class="fas fa-fw fa-times-circle mr-2"></i>Disable AutoPay (<?php echo $recurring_payment_method ?>)
135136
</a>
136137
<?php } else { ?>
137138
<a class="btn btn-secondary" href='#' data-toggle="modal" data-target="#addRecurringPaymentModal<?php echo $recurring_id; ?>">

0 commit comments

Comments
 (0)