fix: payments filter (#2989)
This commit is contained in:
Vendored
+1
-1
File diff suppressed because one or more lines are too long
@@ -359,7 +359,7 @@ window.LNbits = {
|
|||||||
prepareFilterQuery(tableConfig, props) {
|
prepareFilterQuery(tableConfig, props) {
|
||||||
if (props) {
|
if (props) {
|
||||||
tableConfig.pagination = props.pagination
|
tableConfig.pagination = props.pagination
|
||||||
tableConfig.filter = props.filter
|
tableConfig.filter = {...tableConfig.filter, ...props.filter}
|
||||||
}
|
}
|
||||||
const pagination = tableConfig.pagination
|
const pagination = tableConfig.pagination
|
||||||
tableConfig.loading = true
|
tableConfig.loading = true
|
||||||
|
|||||||
@@ -312,7 +312,7 @@ window.PaymentsPageLogic = {
|
|||||||
|
|
||||||
const timeFrom = this.searchDate.from + 'T00:00:00'
|
const timeFrom = this.searchDate.from + 'T00:00:00'
|
||||||
const timeTo = this.searchDate.to + 'T23:59:59'
|
const timeTo = this.searchDate.to + 'T23:59:59'
|
||||||
this.lnbitsBalance = data[data.length - 1].balance
|
this.lnbitsBalance = data.length ? data[data.length - 1].balance : 0
|
||||||
data = data.filter(p => {
|
data = data.filter(p => {
|
||||||
if (this.searchDate.from && this.searchDate.to) {
|
if (this.searchDate.from && this.searchDate.to) {
|
||||||
return p.date >= timeFrom && p.date <= timeTo
|
return p.date >= timeFrom && p.date <= timeTo
|
||||||
|
|||||||
Reference in New Issue
Block a user