Browse Source

tw.view: cleanup prompts

The MMGen Project 2 years ago
parent
commit
bd411b1be4

+ 2 - 2
mmgen/proto/btc/tw/addresses.py

@@ -23,11 +23,11 @@ class BitcoinTwAddresses(TwAddresses,BitcoinTwRPC):
 
 	has_age = True
 	prompt = """
-Sort options: [a]mt, [A]ge, [M]mid, [r]everse
+Sort options: [a]mt, [A]ge, [M]mgen addr, [r]everse
 Column options: toggle [D]ays/date/confs/block
 Filters: show [E]mpty addrs, [u]sed addrs, all [L]abels
 View/Print: pager [v]iew, [w]ide view, [p]rint
-Actions: [q]uit, r[e]draw, add [l]abel:
+Actions: [q]uit view, r[e]draw, add [l]abel:
 """
 	key_mappings = {
 		'a':'s_amt',

+ 4 - 5
mmgen/proto/btc/tw/txhistory.py

@@ -231,15 +231,14 @@ class BitcoinTwTxHistory(TwTxHistory,BitcoinTwRPC):
 	item_desc = 'transaction'
 	no_data_errmsg = 'No transactions in tracking wallet!'
 	prompt = """
-Sort options: [t]xid, [a]mt, total a[m]t, [A]ge, [b]locknum, [r]everse
-Column options: toggle [D]ays/date/confs/block, tx[i]d, [T]otal amt
-Filters: show [u]nconfirmed
+Sorting: [t]xid, [a]mt, total a[m]t, [A]ge, block[n]um, [r]everse
+Column opts: toggle [D]ays/date/confs/block, tx[i]d, [T]otal amt
 View/Print: pager [v]iew, full [V]iew, screen [p]rint, full [P]rint
-Actions: [q]uit, r[e]draw:
+Filters/Actions: show [u]nconfirmed, [q]uit view, r[e]draw:
 """
 	key_mappings = {
 		'A':'s_age',
-		'b':'s_blockheight',
+		'n':'s_blockheight',
 		'a':'s_amt',
 		'm':'s_total_amt',
 		't':'s_txid',

+ 5 - 4
mmgen/proto/btc/tw/unspent.py

@@ -31,9 +31,10 @@ class BitcoinTwUnspentOutputs(TwUnspentOutputs):
 	dump_fn_pfx = 'listunspent'
 	prompt_fs = 'Total to spend, excluding fees: {} {}\n\n'
 	prompt = """
-Sort options: [t]xid, [a]mount, a[d]dress, [A]ge, [r]everse, [M]mgen addr
-Display options: toggle [D]ays/date, show [g]roup, show [m]mgen addr, r[e]draw
-Actions: [q]uit view, [p]rint to file, pager [v]iew, [w]ide view, add [l]abel:
+Sort options: [t]xid, [a]mount, a[d]dr, [A]ge, [r]everse, [M]mid
+Display options: toggle [D]ays/date, show gr[o]up, show [m]mid
+View options: pager [v]iew, [w]ide view
+Actions: [q]uit view, [p]rint, r[e]draw, add [l]abel:
 """
 	key_mappings = {
 		't':'s_txid',
@@ -43,7 +44,7 @@ Actions: [q]uit view, [p]rint to file, pager [v]iew, [w]ide view, add [l]abel:
 		'r':'d_reverse',
 		'M':'s_twmmid',
 		'D':'d_days',
-		'g':'d_group',
+		'o':'d_group',
 		'm':'d_mmid',
 		'e':'d_redraw',
 		'q':'a_quit',

+ 2 - 2
mmgen/proto/eth/tw/addresses.py

@@ -22,10 +22,10 @@ class EthereumTwAddresses(TwAddresses,EthereumTwView,EthereumTwRPC):
 
 	has_age = False
 	prompt = """
-Sort options: [a]mt, [M]mid, [r]everse
+Sort options: [a]mt, [M]mgen addr, [r]everse
 Filters: show [E]mpty addrs, all [L]abels
 View/Print: pager [v]iew, [w]ide view, [p]rint
-Actions: [q]uit, r[e]draw, [D]elete address, add [l]abel:
+Actions: [q]uit view, r[e]draw, [D]elete addr, add [l]abel:
 """
 	key_mappings = {
 		'a':'s_amt',

+ 3 - 3
mmgen/proto/eth/tw/unspent.py

@@ -46,10 +46,10 @@ class EthereumTwUnspentOutputs(EthereumTwView,TwUnspentOutputs):
 	item_desc = 'account'
 	dump_fn_pfx = 'balances'
 	prompt = """
-Sort options:    [a]mount, a[d]dress, [r]everse, [M]mgen addr
+Sort options: [a]mount, a[d]dress, [r]everse, [M]mgen addr
 Display options: show [m]mgen addr, r[e]draw screen
-Actions:         [q]uit view, [p]rint to file, pager [v]iew, [w]ide view,
-                 [D]elete address, add [l]abel, [R]efresh balance:
+View options: [q]uit view, [p]rint to file, [v]iew, [w]ide view
+Actions: [D]elete addr, add [l]abel, [R]efresh balance:
 """
 	key_mappings = {
 		'a':'s_amt',

+ 1 - 1
test/test_py_d/ts_main.py

@@ -526,7 +526,7 @@ class TestSuiteMain(TestSuiteBase,TestSuiteShared):
 			outputs_list.append(len(tx_data)*(addrs_per_wallet+1) + 1)
 
 		self.txcreate_ui_common(t,
-			menu        = (['M'],['M','D','D','D','D','m','g'])[self.test_name=='txcreate'],
+			menu        = (['M'],['M','D','D','D','D','m','o'])[self.test_name=='txcreate'],
 			inputs      = ' '.join(map(str,outputs_list)),
 			add_comment = ('',tx_comment_lat_cyr_gr)[do_label],
 			view        = view,

+ 2 - 2
test/test_py_d/ts_regtest.py

@@ -765,14 +765,14 @@ class TestSuiteRegtest(TestSuiteBase,TestSuiteShared):
 		self.get_file_with_ext('out',delete_all=True)
 		t = self.spawn('mmgen-tool',
 			['--bob',f'--outdir={self.tmpdir}','txhist','age_fmt=date_time','interactive=true'] )
-		for resp in ('u','i','t','a','m','T','A','r','r','D','D','D','D','p','P','b','V'):
+		for resp in ('u','i','t','a','m','T','A','r','r','D','D','D','D','p','P','n','V'):
 			t.expect('draw:\b',resp,regex=True)
 		if t.pexpect_spawn:
 			t.expect(r'Block:.*\b394\b',regex=True)
 			time.sleep(1)
 			t.send('q')
 			time.sleep(0.2)
-			t.send('b')
+			t.send('n')
 			t.expect('draw:\b','q',regex=True)
 		else:
 			txnum,idx = (8,1) if self.proto.coin == 'BCH' else (9,3)