mirror of
https://github.com/aljazceru/BTCPayServerPlugins.git
synced 2025-12-17 07:34:24 +01:00
update ff and ss
This commit is contained in:
@@ -9,7 +9,7 @@
|
|||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<Product>FixedFloat</Product>
|
<Product>FixedFloat</Product>
|
||||||
<Description>Allows you to embed a FixedFloat conversion screen to allow customers to pay with altcoins.</Description>
|
<Description>Allows you to embed a FixedFloat conversion screen to allow customers to pay with altcoins.</Description>
|
||||||
<Version>1.1.3</Version>
|
<Version>1.1.4</Version>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<!-- Plugin development properties -->
|
<!-- Plugin development properties -->
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
|
|||||||
@@ -37,7 +37,9 @@
|
|||||||
const result = this.$parent.paymentMethodId === "FixedFloat";
|
const result = this.$parent.paymentMethodId === "FixedFloat";
|
||||||
|
|
||||||
if(this.preferredToCurrency && this.model.paymentMethodId !== this.preferredToCurrency){
|
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.paymentMethodId = this.preferredToCurrency;
|
||||||
this.$parent.fetchData().then(()=> {
|
this.$parent.fetchData().then(()=> {
|
||||||
this.$parent.paymentMethodId = "FixedFloat";
|
this.$parent.paymentMethodId = "FixedFloat";
|
||||||
@@ -46,11 +48,23 @@
|
|||||||
}
|
}
|
||||||
return result;
|
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 () {
|
url () {
|
||||||
|
|
||||||
|
const address= this.lightning || this.model.btcAddress;
|
||||||
return "https://widget.fixedfloat.com/?" +
|
return "https://widget.fixedfloat.com/?" +
|
||||||
`to=${this.settleMethodId}` +
|
`to=${this.settleMethodId}` +
|
||||||
"&lockReceive=true&ref=fkbyt39c" +
|
"&lockReceive=true&ref=fkbyt39c" +
|
||||||
`&address=${this.model.btcAddress}` +
|
`&address=${address}` +
|
||||||
this.amountQuery +
|
this.amountQuery +
|
||||||
this.explicitQuery;
|
this.explicitQuery;
|
||||||
},
|
},
|
||||||
@@ -58,7 +72,7 @@
|
|||||||
return this.model.paymentMethodId;
|
return this.model.paymentMethodId;
|
||||||
},
|
},
|
||||||
settleMethodId () {
|
settleMethodId () {
|
||||||
return this.currency.endsWith('LightningLike') || this.currency.endsWith('LNURLPay')
|
return this.currency.endsWith('LightningLike') || this.currency.endsWith('LNURLPay') || this.lightning
|
||||||
? 'BTCLN'
|
? 'BTCLN'
|
||||||
: this.currency.replace('_BTCLike', '').replace('_MoneroLike', '').replace('_ZcashLike', '').toUpperCase();
|
: this.currency.replace('_BTCLike', '').replace('_MoneroLike', '').replace('_ZcashLike', '').toUpperCase();
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<Product>SideShift</Product>
|
<Product>SideShift</Product>
|
||||||
<Description>Allows you to embed a SideShift conversion screen to allow customers to pay with altcoins.</Description>
|
<Description>Allows you to embed a SideShift conversion screen to allow customers to pay with altcoins.</Description>
|
||||||
<Version>1.1.10</Version>
|
<Version>1.1.11</Version>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<!-- Plugin development properties -->
|
<!-- Plugin development properties -->
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
|
|||||||
@@ -46,7 +46,11 @@
|
|||||||
}
|
}
|
||||||
self.explicitId = window.ssExplicitId;
|
self.explicitId = window.ssExplicitId;
|
||||||
},200)
|
},200)
|
||||||
|
|
||||||
if(this.preferredToCurrency && this.model.paymentMethodId !== this.preferredToCurrency){
|
if(this.preferredToCurrency && this.model.paymentMethodId !== this.preferredToCurrency){
|
||||||
|
if (this.model.onChainWithLnInvoiceFallback && this.model.paymentMethodId === "BTC"){
|
||||||
|
return;
|
||||||
|
}
|
||||||
this.$parent.paymentMethodId = this.preferredToCurrency;
|
this.$parent.paymentMethodId = this.preferredToCurrency;
|
||||||
await this.$parent.fetchData();
|
await this.$parent.fetchData();
|
||||||
this.$parent.paymentMethodId = "SideShift";
|
this.$parent.paymentMethodId = "SideShift";
|
||||||
@@ -54,6 +58,16 @@
|
|||||||
|
|
||||||
},
|
},
|
||||||
computed: {
|
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 () {
|
content () {
|
||||||
return this.$i18n.i18next.t("conversion_body", this.model).replace(/\n/ig, '<br>');
|
return this.$i18n.i18next.t("conversion_body", this.model).replace(/\n/ig, '<br>');
|
||||||
},
|
},
|
||||||
@@ -68,7 +82,7 @@
|
|||||||
return 'liquid';
|
return 'liquid';
|
||||||
} else if (toCurrency === "usdt") {
|
} else if (toCurrency === "usdt") {
|
||||||
return "usdtla";
|
return "usdtla";
|
||||||
} else if (toCurrency.endsWith('lightninglike') || toCurrency.endsWith('lnurlpay')) {
|
} else if (toCurrency.endsWith('lightninglike') || toCurrency.endsWith('lnurlpay') || this.lightning) {
|
||||||
return "ln";
|
return "ln";
|
||||||
} else {
|
} else {
|
||||||
return toCurrency.replace('_btclike', '').replace('_monerolike', '').replace('_zcashlike', '').toLowerCase();
|
return toCurrency.replace('_btclike', '').replace('_monerolike', '').replace('_zcashlike', '').toLowerCase();
|
||||||
@@ -91,7 +105,7 @@
|
|||||||
parentAffiliateId: "qg0OrfHJV",
|
parentAffiliateId: "qg0OrfHJV",
|
||||||
defaultDepositMethodId: this.explicitId || undefined,
|
defaultDepositMethodId: this.explicitId || undefined,
|
||||||
defaultSettleMethodId: this.settleMethodId,
|
defaultSettleMethodId: this.settleMethodId,
|
||||||
settleAddress: this.model.btcAddress,
|
settleAddress: this.lightning || this.model.btcAddress,
|
||||||
settleAmount: this.amountDue,
|
settleAmount: this.amountDue,
|
||||||
type: this.type
|
type: this.type
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user