Bump and Migrate logic chartjs 2.9.4 to 4.5.0, bump stripe-php from 17.2.1 to 17.6.0, fontawesome-free from 5.15.4 to 7.0.0, fullcalendar from 6.1.17 to 6.1.19, TinyMCE from 7.9.1 to 8.0.2, bootsatrap js bundle from 4.6.1 to 4.6.2, DataTables from 2.3.1 to 2.3.3

This commit is contained in:
johnnyq
2025-08-28 13:57:42 -04:00
parent 9f50c9355a
commit 39d6c42c71
359 changed files with 3058 additions and 25716 deletions

View File

@@ -28,6 +28,8 @@ namespace Stripe;
* @property string $number A unique number that identifies this particular credit note and appears on the PDF of the credit note and its associated invoice.
* @property null|int $out_of_band_amount Amount that was credited outside of Stripe.
* @property string $pdf The link to download the PDF of the credit note.
* @property int $post_payment_amount The amount of the credit note that was refunded to the customer, credited to the customer's balance, credited outside of Stripe, or any combination thereof.
* @property int $pre_payment_amount The amount of the credit note by which the invoice's <code>amount_remaining</code> and <code>amount_due</code> were reduced.
* @property ((object{amount: int, credit_balance_transaction?: Billing\CreditBalanceTransaction|string, discount?: Discount|string, type: string}&StripeObject))[] $pretax_credit_amounts The pretax credit amounts (ex: discount, credit grants, etc) for all line items.
* @property null|string $reason Reason for issuing this credit note, one of <code>duplicate</code>, <code>fraudulent</code>, <code>order_change</code>, or <code>product_unsatisfactory</code>
* @property ((object{amount_refunded: int, refund: Refund|string}&StripeObject))[] $refunds Refunds related to this credit note.
@@ -56,30 +58,32 @@ class CreditNote extends ApiResource
const STATUS_ISSUED = 'issued';
const STATUS_VOID = 'void';
const TYPE_MIXED = 'mixed';
const TYPE_POST_PAYMENT = 'post_payment';
const TYPE_PRE_PAYMENT = 'pre_payment';
/**
* Issue a credit note to adjust the amount of a finalized invoice. For a
* <code>status=open</code> invoice, a credit note reduces its
* <code>amount_due</code>. For a <code>status=paid</code> invoice, a credit note
* does not affect its <code>amount_due</code>. Instead, it can result in any
* combination of the following:
* Issue a credit note to adjust the amount of a finalized invoice. A credit note
* will first reduce the invoices <code>amount_remaining</code> (and
* <code>amount_due</code>), but not below zero. This amount is indicated by the
* credit notes <code>pre_payment_amount</code>. The excess amount is indicated by
* <code>post_payment_amount</code>, and it can result in any combination of the
* following:
*
* <ul> <li>Refund: create a new refund (using <code>refund_amount</code>) or link
* an existing refund (using <code>refund</code>).</li> <li>Customer balance
* credit: credit the customers balance (using <code>credit_amount</code>) which
* will be automatically applied to their next invoice when its finalized.</li>
* <ul> <li>Refunds: create a new refund (using <code>refund_amount</code>) or link
* existing refunds (using <code>refunds</code>).</li> <li>Customer balance credit:
* credit the customers balance (using <code>credit_amount</code>) which will be
* automatically applied to their next invoice when its finalized.</li>
* <li>Outside of Stripe credit: record the amount that is or will be credited
* outside of Stripe (using <code>out_of_band_amount</code>).</li> </ul>
*
* For post-payment credit notes the sum of the refund, credit and outside of
* Stripe amounts must equal the credit note total.
* The sum of refunds, customer balance credits, and outside of Stripe credits must
* equal the <code>post_payment_amount</code>.
*
* You may issue multiple credit notes for an invoice. Each credit note will
* increment the invoices <code>pre_payment_credit_notes_amount</code> or
* <code>post_payment_credit_notes_amount</code> depending on its
* <code>status</code> at the time of credit note creation.
* You may issue multiple credit notes for an invoice. Each credit note may
* increment the invoices <code>pre_payment_credit_notes_amount</code>,
* <code>post_payment_credit_notes_amount</code>, or both, depending on the
* invoices <code>amount_remaining</code> at the time of credit note creation.
*
* @param null|array{amount?: int, credit_amount?: int, effective_at?: int, email_type?: string, expand?: string[], invoice: string, lines?: (array{amount?: int, description?: string, invoice_line_item?: string, quantity?: int, tax_amounts?: null|array{amount: int, tax_rate: string, taxable_amount: int}[], tax_rates?: null|string[], type: string, unit_amount?: int, unit_amount_decimal?: string})[], memo?: string, metadata?: array<string, string>, out_of_band_amount?: int, reason?: string, refund_amount?: int, refunds?: array{amount_refunded?: int, refund?: string}[], shipping_cost?: array{shipping_rate?: string}} $params
* @param null|array|string $options