This commit is contained in:
aozhiwei 2023-07-03 19:34:23 +08:00
parent a4854c9bbc
commit 0a2f9c77d9

View File

@ -128,16 +128,21 @@ class PullBcEvent extends BaseService {
const logHead = this.getInstanceName() + ' event_process.saveLastBlockNumber';
while (true) {
const {err} = await this.conn.upsert(
't_parameter',
't_last_block',
[
['name', this.getBlockNumberDbName()]
['net_id', this.getNetId()],
['contract_address', this.getContractAddress()],
['event_name', this.getEventName()],
],
[
['value', blockNumber],
['block_number', blockNumber],
],
[
['name', this.getBlockNumberDbName()],
['value', blockNumber],
['net_id', this.getNetId()],
['contract_address', this.getContractAddress()],
['event_name', this.getEventName()],
['block_number', blockNumber],
['contract_name', this.getContractName()],
]
);
if (!err) {