diff --git a/lnbits/extensions/tpos/crud.py b/lnbits/extensions/tpos/crud.py index 04b5eaa9d..c403eb5a0 100644 --- a/lnbits/extensions/tpos/crud.py +++ b/lnbits/extensions/tpos/crud.py @@ -53,7 +53,13 @@ async def delete_tpos(tpos_id: str) -> None: async def get_tpos_payments(tpos_id: str, limit: int = 5): rows = await db.fetchall( - f"SELECT * FROM apipayments WHERE extra LIKE '%tposId%' AND extra LIKE '%{tpos_id}%' ORDER BY time DESC LIMIT {limit}" + f""" + SELECT * FROM apipayments + WHERE pending = 'false' + AND extra LIKE '%tposId%' + AND extra LIKE '%{tpos_id}%' + ORDER BY time DESC LIMIT {limit} + """ ) return [Payment.from_row(row) for row in rows] diff --git a/lnbits/extensions/tpos/templates/tpos/tpos.html b/lnbits/extensions/tpos/templates/tpos/tpos.html index 32ed0b884..8fe61452e 100644 --- a/lnbits/extensions/tpos/templates/tpos/tpos.html +++ b/lnbits/extensions/tpos/templates/tpos/tpos.html @@ -275,17 +275,16 @@ {%raw%} - {{payment.amount / 1000}} sats + {{payment.amount / 1000}} sats {{payment.checking_id}}Hash: {{payment.checking_id.slice(0, 30)}}... {{payment.dateFrom}} - + {%endraw%} diff --git a/lnbits/extensions/tpos/views_api.py b/lnbits/extensions/tpos/views_api.py index 9167b5a11..206c19561 100644 --- a/lnbits/extensions/tpos/views_api.py +++ b/lnbits/extensions/tpos/views_api.py @@ -90,7 +90,6 @@ async def api_tpos_get_latest_invoices(tpos_id: str = None): "checking_id": payment.checking_id, "amount": payment.amount, "time": payment.time, - "bolt11": payment.bolt11, "pending": payment.pending, } for payment in payments