ui: Fix pagination clearing filters
This commit is contained in:
parent
577849f01c
commit
5b0c1e9b51
@ -37,7 +37,7 @@ def page_automation_strategies(self, url_split, post_string):
|
|||||||
messages = []
|
messages = []
|
||||||
form_data = self.checkForm(post_string, 'automationstrategies', messages)
|
form_data = self.checkForm(post_string, 'automationstrategies', messages)
|
||||||
|
|
||||||
if form_data and have_data_entry(form_data, 'applyfilters'):
|
if form_data and not have_data_entry(form_data, 'clearfilters'):
|
||||||
if have_data_entry(form_data, 'sort_by'):
|
if have_data_entry(form_data, 'sort_by'):
|
||||||
sort_by = get_data_entry(form_data, 'sort_by')
|
sort_by = get_data_entry(form_data, 'sort_by')
|
||||||
ensure(sort_by in ['created_at', 'rate'], 'Invalid sort by')
|
ensure(sort_by in ['created_at', 'rate'], 'Invalid sort by')
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
|
|
||||||
# Copyright (c) 2022 tecnovert
|
# Copyright (c) 2022-2023 tecnovert
|
||||||
# Distributed under the MIT software license, see the accompanying
|
# Distributed under the MIT software license, see the accompanying
|
||||||
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
|
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
|
||||||
|
|
||||||
@ -139,7 +139,7 @@ def page_bids(self, url_split, post_string, sent=False, available=False, receive
|
|||||||
|
|
||||||
messages = []
|
messages = []
|
||||||
form_data = self.checkForm(post_string, 'bids', messages)
|
form_data = self.checkForm(post_string, 'bids', messages)
|
||||||
if form_data and have_data_entry(form_data, 'applyfilters'):
|
if form_data and not have_data_entry(form_data, 'clearfilters'):
|
||||||
if have_data_entry(form_data, 'sort_by'):
|
if have_data_entry(form_data, 'sort_by'):
|
||||||
sort_by = get_data_entry(form_data, 'sort_by')
|
sort_by = get_data_entry(form_data, 'sort_by')
|
||||||
ensure(sort_by in ['created_at', ], 'Invalid sort by')
|
ensure(sort_by in ['created_at', ], 'Invalid sort by')
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
|
|
||||||
# Copyright (c) 2022 tecnovert
|
# Copyright (c) 2022-2023 tecnovert
|
||||||
# Distributed under the MIT software license, see the accompanying
|
# Distributed under the MIT software license, see the accompanying
|
||||||
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
|
# file LICENSE or http://www.opensource.org/licenses/mit-license.php.
|
||||||
|
|
||||||
@ -641,7 +641,7 @@ def page_offers(self, url_split, post_string, sent=False):
|
|||||||
}
|
}
|
||||||
messages = []
|
messages = []
|
||||||
form_data = self.checkForm(post_string, 'offers', messages)
|
form_data = self.checkForm(post_string, 'offers', messages)
|
||||||
if form_data and have_data_entry(form_data, 'applyfilters'):
|
if form_data and not have_data_entry(form_data, 'clearfilters'):
|
||||||
filters['coin_from'] = setCoinFilter(form_data, 'coin_from')
|
filters['coin_from'] = setCoinFilter(form_data, 'coin_from')
|
||||||
filters['coin_to'] = setCoinFilter(form_data, 'coin_to')
|
filters['coin_to'] = setCoinFilter(form_data, 'coin_to')
|
||||||
|
|
||||||
|
@ -20,6 +20,7 @@
|
|||||||
- ui: Bids on expired offers won't show as available.
|
- ui: Bids on expired offers won't show as available.
|
||||||
- api: getcoinseed shows seed id.
|
- api: getcoinseed shows seed id.
|
||||||
- ui: Can edit automation strategy data.
|
- ui: Can edit automation strategy data.
|
||||||
|
- ui: Fix pagination clearing filters
|
||||||
|
|
||||||
|
|
||||||
0.0.54
|
0.0.54
|
||||||
|
@ -294,7 +294,7 @@ def main():
|
|||||||
'amt_var': offer_template['amount_variable'],
|
'amt_var': offer_template['amount_variable'],
|
||||||
'valid_for_seconds': offer_template.get('offer_valid_seconds', config.get('offer_valid_seconds', 3600)),
|
'valid_for_seconds': offer_template.get('offer_valid_seconds', config.get('offer_valid_seconds', 3600)),
|
||||||
'rate': use_rate,
|
'rate': use_rate,
|
||||||
'swap_type': 'adaptor_sig',
|
'swap_type': offer_template.get('swap_type', 'adaptor_sig'),
|
||||||
'lockhrs': '24',
|
'lockhrs': '24',
|
||||||
'automation_strat_id': 1}
|
'automation_strat_id': 1}
|
||||||
if args.debug:
|
if args.debug:
|
||||||
|
Loading…
Reference in New Issue
Block a user