1
This commit is contained in:
parent
27880bebce
commit
b145a8d2d3
@ -136,6 +136,10 @@ class DbEventProcess extends BaseService {
|
||||
return this.eventConf['contract_name'];
|
||||
}
|
||||
|
||||
getContractAddressByName(name) {
|
||||
return this.net['getContractAddressByName'](name);
|
||||
}
|
||||
|
||||
getInstanceName() {
|
||||
const instName = this.getNetId() + ' ' + this.getContractName() + '.' + this.getEventName() + ' dbprocess';
|
||||
return instName;
|
||||
|
@ -59,9 +59,13 @@ class Activate721Nft extends BaseEventProcess {
|
||||
this.throwError('error transId:2');
|
||||
return;
|
||||
}
|
||||
const contractAddress = this.getContractAddressByName();
|
||||
if (!contractAddress) {
|
||||
this.throwError('error error contractAddress transId:' + transId);
|
||||
return;
|
||||
}
|
||||
await this.updateGameDbInfo(transId, itemUniId, itemId, tokenId, tokenType);
|
||||
const nowTime = utils.getUtcTime();
|
||||
const contractAddress = this.getContractAddress();
|
||||
const fieldList = [
|
||||
['token_id', tokenId],
|
||||
['token_type', tokenType],
|
||||
@ -86,7 +90,6 @@ class Activate721Nft extends BaseEventProcess {
|
||||
],
|
||||
fieldList
|
||||
);
|
||||
console.log(this.getNetId(), this.getContractAddress());
|
||||
if (err) {
|
||||
this.throwError('mintNft transId:' + transId);
|
||||
}
|
||||
|
@ -62,6 +62,10 @@ class BaseEventProcess {
|
||||
return this.eventProc.getContractName();
|
||||
}
|
||||
|
||||
getContractAddressByName(name) {
|
||||
return this.eventProc.getContractName(name);
|
||||
}
|
||||
|
||||
getReturnValues() {
|
||||
return this.returnValues;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user