Commit Graph

152 Commits

Author SHA1 Message Date
Nicolas Dorier
932d313dee Can apply tax rates to PoS items (#6724) 2025-05-19 10:35:46 +09:00
nicolas.dorier
9dc1aeda72 [Feature] Can configure fallback rates 2025-05-08 19:05:55 +09:00
nicolas.dorier
5f908322c2 Make Rider a bit less verbose Code cleanup 2025-04-23 16:51:56 +09:00
Nicolas Dorier
2f26979ed7 Refactor vault (#6678)
* Use Blazor for the Vault code

* Put elements in different file

* Controller abstraction

* Break into VaultElement
2025-04-21 17:09:46 +09:00
Nicolas Dorier
658ddd1f27 Fix: Refunds through API were ignoring BOLT11 expiration at store level (#6644) 2025-03-31 09:32:12 +09:00
nicolas.dorier
2911771f19 Feature: RBF and UX improvement to fee bumping 2025-03-11 17:44:18 +09:00
ThiagoOyo
9bff84f90f Fix: Archived invoices shouldn't be browsable by non authenticated users (#6588)
* fix: return 403 when unauthenticated user accesses an archived invoice receipt

* refactor: simplify archived invoice access check with pattern matching

* Return 404 for unauthorized users accessing archived invoice

Co-authored-by: d11n <mail@dennisreimann.de>

* feat: add archived invoice validation for unauthenticated access in Checkout and GetStatus

* test: add test case for unauthorized access to archived invoice returning not found

* test: add unauthorized checkout test for archived invoice

* Commenting code and adding test case for GetStatus

---------

Co-authored-by: d11n <mail@dennisreimann.de>
Co-authored-by: rockstardev <5191402+rockstardev@users.noreply.github.com>
2025-03-06 17:45:53 +09:00
d11n
20e8db7307 App: Allow receipt to be shown in iframe (#6574)
Also detects if the checkout page is shown within an iframe and hides the back to store link in that case.
2025-01-21 23:50:27 +09:00
d11n
08835895e9 Invoices: Allow admin to see invoices of users (#6517)
* Invoices: Allow admin to see invoices of users

Fixes #6489. As discussed with @TChukwuleta, this succeeds and closes #6497.

* Invoices: Allow admin to see invoices of users

Fixes #6489. As discussed with @TChukwuleta, this succeeds and closes #6497.

* Update controller to allow admin access for basic invoice actions
2024-12-23 17:50:44 +09:00
nicolas.dorier
4f63f08aeb Plugin: Add IGlobalCheckoutModelExtension 2024-12-09 21:29:04 +09:00
d11n
d3315c2fa6 Integrate mobile-working-branch part 1 (#6428) 2024-11-26 14:17:40 +09:00
nicolas.dorier
74011e50e3 Do not translate checkout with the backend language 2024-10-20 11:49:36 +09:00
Nicolas Dorier
7b6a115adc [Greenfield] Select default payoutMethodId if none are selected in the Refund route (#6315) 2024-10-17 22:54:59 +09:00
d11n
77fba4aee3 Add more translations (#6302)
* Newlines

* Dashboard

* Add more translations

* Moar

* Remove &nbsp; from translated texts

* Dictionary controller translations

* Batch 1 of controller updates

* Batch 2 of controller updates

* Component translations

* Batch 3 of controller updates

* Fixes
2024-10-17 22:51:40 +09:00
nicolas.dorier
b91f3048ef Fix: An unactivated payment method failing to activate would crash the checkout 2024-10-08 15:07:32 +09:00
nicolas.dorier
68f24e47cd Rename more legacy fields 2024-10-07 21:22:03 +09:00
nicolas.dorier
968223a953 Rename PaymentModel to CheckoutModel 2024-10-07 19:58:08 +09:00
nicolas.dorier
2f287874e3 Rename legacy fields 2024-10-07 19:51:50 +09:00
nicolas.dorier
c35e7406cd Cleanup AvailableCrypto from the model 2024-10-07 19:15:40 +09:00
nicolas.dorier
34b2cca492 Simplify extension of payments extensions 2024-10-07 18:37:38 +09:00
nicolas.dorier
e1bfc04451 Move checkout registration to the UI Extension 2024-10-07 17:38:02 +09:00
nicolas.dorier
ef0ba7b0c4 Remove useless properties 2024-10-07 16:18:09 +09:00
nicolas.dorier
b744fd6167 Allow payment methods to modify all the payment model 2024-10-07 14:53:21 +09:00
nicolas.dorier
abc8161a08 Add the concept of RateDivisibility 2024-10-04 23:14:38 +09:00
Nicolas Dorier
64ba8248d2 Can inject currency data in CurrencyNameTable (#6276) 2024-10-04 22:24:44 +09:00
Nicolas Dorier
2f2b4094f6 [UI] Do not show unabled payment methods in invoice creation (#6272) 2024-10-03 21:34:09 +09:00
Nicolas Dorier
363b60385b Renaming various properties in the Payouts API (#6246)
* Rename Payouts Currency/OriginalCurrency

* Rename Payout Processor PayoutMethodIds

* Rename paymentMethods to payoutMethodIds

* Rename payoutMethodIds to payoutMethods
2024-09-26 11:25:45 +09:00
Nicolas Dorier
3cf1aa00fa Payments should use composite key (#6240)
* Payments should use composite key

* Invert PK for InvoiceAddress
2024-09-23 17:06:56 +09:00
Nicolas Dorier
ba2301ebfe Refactor the InvoiceAddresses table (#6232) 2024-09-19 22:15:02 +09:00
Nicolas Dorier
0f93581ff5 Refactor confirmation count tracking (#6215) 2024-09-17 17:28:58 +09:00
Nicolas Dorier
b4946f4db1 Fix divisibility in invoice details of lightning amounts (#6202)
* Fix divisibility in invoice details of lightning amounts

This PR will show 11 decimal in the invoice details for BTC amount
of lightning payment methods.

It also hacks around the fact that some
lightning clients don't create the requested amount of sats, which
resulted in over or under payments. (Blink not supporting msats, and
strike)

Now, In that case, a payment method fee (which can be negative) called tweak fee
will be added to the prompt.

We are also hiding this tweak fee from the user in the checkout page in
order to not disturb the UI with inconsequential fee of 0.000000001 sats.

* Only show 8 digits in checkout, even if amount is 11 digits
2024-09-12 12:43:08 +09:00
d11n
841f41da2f Invoice: Improve zero amount invoice handling (#6199)
This is for the checkout page to properly redirect paid invoices with no payment methods (e.g. free invoices with zero amount) to either the receipt page or redirect URL. Only fall back to 404 if there is neither.

Fixes #6123.
2024-09-09 11:05:03 +09:00
Nicolas Dorier
a3cfb9e5e4 Removal of the Altcoins build (#6177)
* Remove some useless #if ALTCOINS

* Removal of the Altcoins build
2024-08-30 08:34:23 +09:00
Nicolas Dorier
07f3301e32 Remove unused code (#6152) 2024-08-22 18:52:41 +09:00
d11n
ddb07a7ba9 Receipt page fixes (#6079)
* Receipt: Don't assign empty values to data; hide present empty values
* Receipt: Use same URL on "Return to Store" link as on invoice
2024-07-09 16:59:36 +02:00
Nicolas Dorier
247532e3c4 Do not crash when refunding an invoice that has been marked settled (Fix #6003) (#6086) 2024-07-04 16:43:30 +09:00
nicolas.dorier
4a2f61de9f Fix crash if refunding an invoice without payment 2024-07-04 10:43:39 +09:00
d11n
c063c70b07 Search: Display text filters in search input (#5986)
* Search: Display text filters in search input

This changes the search text input to also display the filters, which don't have a special UI (e.g. dropdown). Those filters (e.g. orderid) were not displayed before and hence could not be reset.

Fixes #5984.

* Add and fix test
2024-05-23 20:22:16 +09:00
Nicolas Dorier
69e0ae76c7 Fix: Error while connecting to websockets without reverse proxy (#5981) 2024-05-15 09:17:45 +09:00
Nicolas Dorier
c134602cbd Remove Legacy Status from the code (#5982) 2024-05-15 07:49:53 +09:00
Nicolas Dorier
d96b066658 Recommended exchange to be resolved during Invoice Creation (#5976)
* Recommended Exchange Rate Selection during Invoice Creation

* Make Recommended exchanges pluginifiable
2024-05-13 22:29:42 +09:00
Nicolas Dorier
adbe5977cd Decouple DefaultRates from BTCPayNetwork (#5974) 2024-05-09 17:20:24 +09:00
d11n
4c303d358b Branding updates for 2.0 (#5947)
* Remove deprecated CSS options

Closes #5945.

* Greenfield: Add brandColor to store APIs

Closes #5946.

* Migrate file IDs to URLs

Closes #5953.

* Greenfield: Add CSS and logo URL to store settings API

Closes #5945.

* Add migration test

* Store and Server branding can reference file's via fileid:ID

* Add PaymentSoundUrl to Store API

---------

Co-authored-by: nicolas.dorier <nicolas.dorier@gmail.com>
2024-05-09 09:18:02 +09:00
Nicolas Dorier
9db9c5e936 Decouple PaymentMethodId from PayoutMethodId (#5944) 2024-05-01 10:22:07 +09:00
Andrew Camilleri
6049fa23a7 Support pluginable rate providers (#5777)
* Support pluginable rate providers

This PR allows plugins to provide custom rate providers, that can be contextual to a store. For example, if you use the upcoming fiat offramp plugin, or the Blink plugin, you'll probably want to configure the fetch the rates from them since they are determining the actual fiat rrate to you. However, they require API keys. This PR enables these scenarios, even much more advanced ones, but for example:
* Install fiat offramp plugin
* Configure it
* You can now use the fiat offramp rate provider (no additional config steps beyond selecting the rate source from the select, or maybe the plugin would automatically set it for you once configured)

* Apply suggestions from code review

* Simplify

* Do not use BackgroundFetcherRateProvider for contextual rate prov

---------

Co-authored-by: nicolas.dorier <nicolas.dorier@gmail.com>
2024-04-30 18:31:15 +09:00
Nicolas Dorier
0c35939001 Cleanup data from the InvoiceEvents table (#5904) 2024-04-25 14:09:01 +09:00
d11n
56d57bbd84 Improve data display on receipt (#5896)
Once more an improvement for the receipt, which also fixes #5882:

- Unify data displayed on the web and print version
- Split cart and additional data and ensure additional data is displayed
- Do not display extra subtotal row if there are no tips or discounts
- Make PosData partial more universal and backwards-compatible by using case insensitive key lookups
2024-04-24 10:22:00 +02:00
Dennis Reimann
d2e9ec9494 Cleanup v2 leftovers 2024-04-05 18:05:51 +02:00
nicolas.dorier
4208110d57 Remove CheckoutV1 2024-04-05 16:58:13 +09:00
Nicolas Dorier
6cc1751924 The Big Cleanup: Refactor BTCPay internals (#5809) 2024-04-04 16:31:04 +09:00