diff --git a/Plugins/BTCPayServer.Plugins.FixedFloat/BTCPayServer.Plugins.FixedFloat.csproj b/Plugins/BTCPayServer.Plugins.FixedFloat/BTCPayServer.Plugins.FixedFloat.csproj
index 6809077..6aaf2fb 100644
--- a/Plugins/BTCPayServer.Plugins.FixedFloat/BTCPayServer.Plugins.FixedFloat.csproj
+++ b/Plugins/BTCPayServer.Plugins.FixedFloat/BTCPayServer.Plugins.FixedFloat.csproj
@@ -9,7 +9,7 @@
FixedFloat
Allows you to embed a FixedFloat conversion screen to allow customers to pay with altcoins.
- 1.1.3
+ 1.1.4
diff --git a/Plugins/BTCPayServer.Plugins.FixedFloat/Views/Shared/FixedFloat/CheckoutPaymentExtension.cshtml b/Plugins/BTCPayServer.Plugins.FixedFloat/Views/Shared/FixedFloat/CheckoutPaymentExtension.cshtml
index b6c0aea..87ca3e8 100644
--- a/Plugins/BTCPayServer.Plugins.FixedFloat/Views/Shared/FixedFloat/CheckoutPaymentExtension.cshtml
+++ b/Plugins/BTCPayServer.Plugins.FixedFloat/Views/Shared/FixedFloat/CheckoutPaymentExtension.cshtml
@@ -37,7 +37,9 @@
const result = this.$parent.paymentMethodId === "FixedFloat";
if(this.preferredToCurrency && this.model.paymentMethodId !== this.preferredToCurrency){
-
+ if (this.model.onChainWithLnInvoiceFallback && this.model.paymentMethodId === "BTC"){
+ return result;
+ }
this.$parent.paymentMethodId = this.preferredToCurrency;
this.$parent.fetchData().then(()=> {
this.$parent.paymentMethodId = "FixedFloat";
@@ -46,11 +48,23 @@
}
return result;
},
+ lightning () {
+ if (!this.model.onChainWithLnInvoiceFallback || this.model.paymentMethodId !== "BTC"){
+ return null;
+ }
+ const index = this.model.invoiceBitcoinUrl.indexOf("lightning=");
+ if (index === -1){
+ return null;
+ }
+ return this.model.invoiceBitcoinUrl.slice(index + "lightning=".length);
+ },
url () {
+
+ const address= this.lightning || this.model.btcAddress;
return "https://widget.fixedfloat.com/?" +
`to=${this.settleMethodId}` +
"&lockReceive=true&ref=fkbyt39c" +
- `&address=${this.model.btcAddress}` +
+ `&address=${address}` +
this.amountQuery +
this.explicitQuery;
},
@@ -58,7 +72,7 @@
return this.model.paymentMethodId;
},
settleMethodId () {
- return this.currency.endsWith('LightningLike') || this.currency.endsWith('LNURLPay')
+ return this.currency.endsWith('LightningLike') || this.currency.endsWith('LNURLPay') || this.lightning
? 'BTCLN'
: this.currency.replace('_BTCLike', '').replace('_MoneroLike', '').replace('_ZcashLike', '').toUpperCase();
},
diff --git a/Plugins/BTCPayServer.Plugins.SideShift/BTCPayServer.Plugins.SideShift.csproj b/Plugins/BTCPayServer.Plugins.SideShift/BTCPayServer.Plugins.SideShift.csproj
index 72d77df..3d0657b 100644
--- a/Plugins/BTCPayServer.Plugins.SideShift/BTCPayServer.Plugins.SideShift.csproj
+++ b/Plugins/BTCPayServer.Plugins.SideShift/BTCPayServer.Plugins.SideShift.csproj
@@ -9,7 +9,7 @@
SideShift
Allows you to embed a SideShift conversion screen to allow customers to pay with altcoins.
- 1.1.10
+ 1.1.11
diff --git a/Plugins/BTCPayServer.Plugins.SideShift/Views/Shared/SideShift/CheckoutPaymentExtension.cshtml b/Plugins/BTCPayServer.Plugins.SideShift/Views/Shared/SideShift/CheckoutPaymentExtension.cshtml
index 8fe2bf3..e1d425b 100644
--- a/Plugins/BTCPayServer.Plugins.SideShift/Views/Shared/SideShift/CheckoutPaymentExtension.cshtml
+++ b/Plugins/BTCPayServer.Plugins.SideShift/Views/Shared/SideShift/CheckoutPaymentExtension.cshtml
@@ -46,7 +46,11 @@
}
self.explicitId = window.ssExplicitId;
},200)
+
if(this.preferredToCurrency && this.model.paymentMethodId !== this.preferredToCurrency){
+ if (this.model.onChainWithLnInvoiceFallback && this.model.paymentMethodId === "BTC"){
+ return;
+ }
this.$parent.paymentMethodId = this.preferredToCurrency;
await this.$parent.fetchData();
this.$parent.paymentMethodId = "SideShift";
@@ -54,6 +58,16 @@
},
computed: {
+ lightning () {
+ if (!this.model.onChainWithLnInvoiceFallback || this.model.paymentMethodId !== "BTC"){
+ return null;
+ }
+ const index = this.model.invoiceBitcoinUrl.indexOf("lightning=");
+ if (index === -1){
+ return null;
+ }
+ return this.model.invoiceBitcoinUrl.slice(index + "lightning=".length);
+ },
content () {
return this.$i18n.i18next.t("conversion_body", this.model).replace(/\n/ig, '
');
},
@@ -68,7 +82,7 @@
return 'liquid';
} else if (toCurrency === "usdt") {
return "usdtla";
- } else if (toCurrency.endsWith('lightninglike') || toCurrency.endsWith('lnurlpay')) {
+ } else if (toCurrency.endsWith('lightninglike') || toCurrency.endsWith('lnurlpay') || this.lightning) {
return "ln";
} else {
return toCurrency.replace('_btclike', '').replace('_monerolike', '').replace('_zcashlike', '').toLowerCase();
@@ -91,7 +105,7 @@
parentAffiliateId: "qg0OrfHJV",
defaultDepositMethodId: this.explicitId || undefined,
defaultSettleMethodId: this.settleMethodId,
- settleAddress: this.model.btcAddress,
+ settleAddress: this.lightning || this.model.btcAddress,
settleAmount: this.amountDue,
type: this.type
};