This commit is contained in:
aozhiwei 2023-08-28 15:11:14 +08:00
parent 1251429cdf
commit 3565943aca
3 changed files with 18 additions and 0 deletions

View File

@ -54,4 +54,19 @@ class Staking(object):
['!items', [_common.StakingDetail()], '领取历史'],
]
},
{
'name': 'redeemPreview',
'desc': '赎回预览',
'group': 'Staking',
'url': 'webapp/index.php?c=Staking&a=redeemPreview',
'params': [
_common.ReqHead(),
['trans_id', '', 'trans_id'],
],
'response': [
_common.RspHead(),
['cec_rewards', 0, '该nft结算得到的ceg数量'],
['state', 0, '0:提前赎回 1:到期赎回'],
]
},
]

View File

@ -1436,10 +1436,12 @@ class StakingDetail(object):
def __init__(self):
self.fields = [
['trans_id', '', '本次质押交易唯一id'],
['token_id', '', 'token id'],
['token_type', '', 'token type'],
['contract_address', '', 'contract address'],
['net_id', '', 'net_id'],
['order_id', '', 'order_id'],
['start_time', '', '质押开始时间'],
['stake_time', '', '质押时间'],
['txhash', '', 'txhash'],

View File

@ -187,6 +187,7 @@ class Staking extends BaseModel {
'token_type' => $row['token_type'],
'contract_address' => $row['contract_address'],
'net_id' => $row['net_id'],
'order_id' => $row['order_id'],
'start_time' => $row['start_time'],
'stake_time' => $row['stake_time'],
'txhash' => $row['txhash'],