Commit Graph

30 Commits

Author SHA1 Message Date
d11n
47f5d97eaf
Prevent an NRE in LNURL (#4908)
* Prevent an NRE in LNURL

In addition to f05a7f9f14. Fixes #4904.

* Revert "Prevent an NRE in LNURL"

This reverts commit 0b241d61ab.

* Fix NRE

---------

Co-authored-by: nicolas.dorier <nicolas.dorier@gmail.com>
2023-04-24 21:50:31 +09:00
nicolas.dorier
7546ef7a8e
Dotnet reformat 2023-04-10 11:07:03 +09:00
d11n
ded0c8a3bc
Update price display (#4736)
* Update price display

As proposed by @dstrukt in #4364.

* Update format

* Unify price display across the app

* Add DisplayFormatter

* Replace DisplayFormatCurrency method

* Use symbol currency format for invoice

* Unify currency formats on backend pages

* Revert recent changes

* Do not show exchange rate and fiat order amount for crypto denominations

* Fix test and add test cases
2023-03-13 10:12:58 +09:00
d11n
abe29f21f0
Checkout v2: Option to display amount in Sats in BIP21 case (#4730) 2023-03-09 21:36:11 +01:00
Andrew Camilleri
612a0397a7
Make LNURL enabled when only method (#3930)
* Make LNURL enabled when only method

This fixes the scenario where LNURL for standard invoices are disabled, but the POS Print view only shows LNURL, so the QR code would always error out. The fix is to bypass the setting when lnurl is the only enabled payment method on the invoice

* Make sure not to affect other flows

* fix
2022-07-06 22:09:05 +09:00
Kukks
e021d42551 Ensure that there is no LN/Bitcoin specific logic in the Invoice UI endpoint 2020-11-06 11:09:17 +01:00
Kukks
a729dd1380 Separate views of Bitcoin and LN 2020-11-06 09:35:26 +01:00
XPayServer
e276443d2d Add Value Criteria For Payment Method
I upgrade lightning max/bitcoin min to support better control in store. Now can have setting only enable specific payment method only if value high/low I think make code simple more too and backward compatible
2020-09-22 11:20:44 +02:00
rockstardev
b6c7af32de Cleaning up bom from cs files 2020-06-28 21:44:35 -05:00
nicolas.dorier
fd026a9733
Refactor server-side 2020-04-05 12:02:36 +09:00
Andrew Camilleri
7ab97311be Re-enable lightning sats feature through C# (#1014) 2019-09-11 14:49:06 +09:00
Andrew Camilleri
9a9e31c759 Split Bitcoin/LN to partial defined in payment handler and convert checkout to Vue (#996) 2019-08-27 11:31:15 +09:00
Andrew Camilleri
43ee22f965 Allow overriding UI of checkout in payment handler (#992) 2019-08-25 22:50:11 +09:00
HugoDoyon
6b777878e3 Add test to cover all case and fix small issue 2019-08-02 14:14:54 -04:00
nicolas.dorier
01787e2662
Refactor: Remove PrepareInvoiceDTO 2019-06-04 10:11:52 +09:00
nicolas.dorier
796954c6e3
Refactor: Remove BlockExplorerLink from the payment handler 2019-06-04 09:52:06 +09:00
nicolas.dorier
1f7097ef89
Refactor: Move DeserializeSupportedPaymentMethod to PaymentType 2019-06-04 09:33:42 +09:00
nicolas.dorier
1e77546251
Refactoring, make PaymentType a class instead of enum 2019-06-04 08:59:01 +09:00
nicolas.dorier
8711960e74
Removing DeserializePaymentMethodDetails from IPaymentMethodHandler 2019-06-04 01:55:07 +09:00
nicolas.dorier
864bcbb675
Move back GetCryptoPaymentData logic inside PaymentEntity 2019-06-04 01:24:15 +09:00
nicolas.dorier
0b257b98f5
Move back ToPrettyString() in PaymentMethodId to fix crash if a payment method as been disabled 2019-06-04 01:06:03 +09:00
Andrew Camilleri
916323bb3b [WIP] Further abstractions to Payment Handlers (#867)
* mark items to abstract


wip


wip


wip


wip


wip


wip


wip


cleanup


parse other types


compile and fix tests


fix bug 


fix warnings


fix rebase error


reduce payment method handler passings


more cleanup


switch tests to Fast mode 


fix obsolete warning


remove argument requirement 


rebase fixes


remove overcomplicated code


better parsing


remove dependency on environement


remove async

* fixes and simplification

* simplify

* clean up even more

* replace nuglify dependency

* remove extra space

* Fix tests

* fix booboo

* missing setter

* change url resolver

* reduce payment method handlers

* wrap payment method handlers in a custom type

* fix tests

* make invoice controller UI selectlist population cleaner

* make store controller use payment handler dictionary

* fix ln flag

* fix store controller test

* remove null checks on payment handlers

* remove unused imports

* BitcoinSpecificBtcPayNetwork - abstract BTCPayNetwork

* some type fixes

* fix tests

* simplify fetching handler in invoice controller

* rename network base and bitcoin classes

* abstract serializer to network level

* fix serializer when network not provided

* fix serializer when network not provided

* fix serializer when network not provided

* Abstract more payment type specific logic to handlers

* fix merge issue

* small fixes

* make use of repository instead of direct context usage

* reduce redundant code

* sanity check

* test fixes
2019-05-30 16:02:52 +09:00
Andrew Camilleri
81dae7d350 BTCPay Abstractions: Move PaymentMethod specific logic to their handlers (#850) 2019-05-29 23:33:31 +09:00
Andrew Camilleri
d3e3c31b0c Btcpay abstract BTCPayNetwork -- Alternative PR to #865 (#868)
* BitcoinSpecificBtcPayNetwork - abstract BTCPayNetwork

* some type fixes

* fix tests

* simplify fetching handler in invoice controller

* rename network base and bitcoin classes

* abstract serializer to network level

* fix serializer when network not provided

* fix serializer when network not provided

* fix serializer when network not provided

* try fixes for isolating pull request
2019-05-29 18:43:50 +09:00
Andrew Camilleri
25b08b21fa Provide Pretty descriptions for payment methods from their handlers (#852)
* small cleanup

* Provide Pretty descriptions for payment methods from their handlers

* remove PrettyMethod()
2019-05-24 15:38:47 +09:00
nicolas.dorier
9c30476fc8 Making BTCPayServer a bit faster when creating invoices 2018-08-21 13:54:52 +09:00
nicolas.dorier
d7cb6f1cca Add a way to customize lightning invoice description 2018-04-07 16:27:46 +09:00
nicolas.dorier
e23243565f Refactor CreateInvoiceCore to better give feedback on payment method errors to the merchant, be faster, and give NodeInfo 2018-03-28 22:37:01 +09:00
nicolas.dorier
3d33ecf397 make IsAvailable async 2018-02-23 16:09:15 +09:00
nicolas.dorier
0e1a1fd2cd Remove dependencies in StoreController to on chain payment specific stuff 2018-02-20 12:45:04 +09:00