erc20TransferFrom static method
Request data when execute erc20 transferFrom.
contractAddress
is token contract address.
from
is from public address.
to
is to public address.
amount
is token amount.
Implementation
static Future<String> erc20TransferFrom(
String contractAddress, String from, String to, BigInt amount) async {
var list2 = [from, to, amount.toString()];
var list1 = [contractAddress, "erc20_transferFrom", list2];
const method = "particle_abi_encodeFunctionCall";
final params = list1;
return await EvmService.rpc(method, params);
}