refactor: drop the SatsPay/watchonly on-chain surface
v1.6.8 sells tickets on-chain through SatsPay charges — a per-purchase watchonly address, a hosted charge page, and a webhook back into the extension. We are not adopting that: on-chain goes through the fork's native LndRestWallet support once core can mint purpose-bound receiving addresses (aiolabs/lnbits#53). This is the parity note on #41, applied as its own commit so the merge it follows stays a faithful diff of what upstream shipped. Removed: - services: the five SatsPay/watchonly HTTP clients (and with them the only uses of httpx and typing.Any in that module) - views_api: _get_watchonly_status, GET /events/onchain/status, the SatsPay charge branch of api_ticket_create, POST /tickets/{id}/satspay-webhook, PUT /tickets/{hash}/onchain-confirm - models: EventExtra.onchain_{enabled,wallet_id,zeroconf,fasttrack}, TicketExtra.satspay_charge_id, TicketPaymentRequest.satspay_charge_url - frontend: the organiser's "Onchain payments" panel and its watchonly wallet picker, the per-ticket confirm-onchain button, the SatsPay charge-page redirect, and the wallet-status fetch behind them `onchain` is no longer an accepted payment_method — there is no rail to fulfil it until #41 lands, so accepting it could only fail later. Kept as vocabulary for #41, in upstream's field names so it needs no migration: TicketExtra.onchain / onchain_address and TicketPaymentRequest.onchain_amount_sat. 35 routes register with no duplicates; ruff, black, prettier clean; 97 tests pass; mypy error set still identical to HEAD's baseline.
This commit is contained in:
parent
ae5affa44f
commit
d90a0f8322
6 changed files with 10 additions and 377 deletions
|
|
@ -408,18 +408,6 @@
|
|||
>
|
||||
<q-tooltip>Resend ticket email</q-tooltip>
|
||||
</q-btn>
|
||||
<q-btn
|
||||
v-if="props.row.extra?.onchain && !props.row.paid"
|
||||
flat
|
||||
dense
|
||||
size="xs"
|
||||
@click="confirmOnchainTicket(props.row)"
|
||||
icon="currency_bitcoin"
|
||||
color="orange"
|
||||
class="q-ml-xs"
|
||||
>
|
||||
<q-tooltip>Confirm onchain payment</q-tooltip>
|
||||
</q-btn>
|
||||
</q-td>
|
||||
|
||||
<q-td v-for="col in props.cols" :key="col.name" :props="props">
|
||||
|
|
@ -909,55 +897,6 @@
|
|||
</div>
|
||||
</q-expansion-item>
|
||||
|
||||
<q-expansion-item
|
||||
group="advanced"
|
||||
icon="view_in_ar"
|
||||
label="Onchain payments"
|
||||
>
|
||||
<div class="q-mt-lg">
|
||||
<div class="text-caption q-mb-md">
|
||||
Accept Bitcoin onchain payments. Requires the
|
||||
<strong>SatsPay</strong> and <strong>Watchonly</strong>
|
||||
extensions to be installed and enabled.
|
||||
</div>
|
||||
<q-toggle
|
||||
v-model="formDialog.data.extra.onchain_enabled"
|
||||
label="Accept onchain payments"
|
||||
left-label
|
||||
@update:model-value="val => val && loadOnchainWallets()"
|
||||
></q-toggle>
|
||||
<q-select
|
||||
v-if="formDialog.data.extra.onchain_enabled"
|
||||
filled
|
||||
dense
|
||||
class="q-mt-md"
|
||||
v-model="formDialog.data.extra.onchain_wallet_id"
|
||||
label="Watchonly wallet"
|
||||
:options="
|
||||
onchainWallets.map(w => ({
|
||||
label: w.title || w.id,
|
||||
value: w.id
|
||||
}))
|
||||
"
|
||||
emit-value
|
||||
map-options
|
||||
hint="Bitcoin watchonly wallet for receiving onchain payments"
|
||||
></q-select>
|
||||
<div v-if="formDialog.data.extra.onchain_enabled" class="q-mt-md">
|
||||
<q-toggle
|
||||
v-model="formDialog.data.extra.onchain_zeroconf"
|
||||
label="Zero-conf (accept unconfirmed transactions)"
|
||||
left-label
|
||||
></q-toggle>
|
||||
<q-toggle
|
||||
v-model="formDialog.data.extra.onchain_fasttrack"
|
||||
label="Fasttrack (treat pending as paid)"
|
||||
left-label
|
||||
></q-toggle>
|
||||
</div>
|
||||
</div>
|
||||
</q-expansion-item>
|
||||
|
||||
<div class="row q-mt-lg">
|
||||
<q-btn
|
||||
v-if="formDialog.data.id"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue