|
|
@ -446,9 +446,13 @@ void ClientModel::executeSequence(vector<TransactionSettings> const& _sequence) |
|
|
|
if (contractAddressIter == m_contractAddresses.end()) |
|
|
|
{ |
|
|
|
emit runFailed("Contract '" + transaction.contractId + tr(" not deployed.") + "' " + tr(" Cannot call ") + transaction.functionId); |
|
|
|
break; |
|
|
|
Address fakeAddress = Address::random(); |
|
|
|
std::pair<QString, int> contractToken = resolvePair(transaction.contractId); |
|
|
|
m_contractNames[fakeAddress] = contractToken.first; |
|
|
|
callAddress(fakeAddress, encoder.encodedData(), transaction); //Transact to a random fake address to that transaction is added to the list anyway
|
|
|
|
} |
|
|
|
callAddress(contractAddressIter->second, encoder.encodedData(), transaction); |
|
|
|
else |
|
|
|
callAddress(contractAddressIter->second, encoder.encodedData(), transaction); |
|
|
|
} |
|
|
|
m_gasCosts.append(m_client->lastExecution().gasUsed); |
|
|
|
onNewTransaction(); |
|
|
@ -833,9 +837,9 @@ void ClientModel::onNewTransaction() |
|
|
|
else |
|
|
|
{ |
|
|
|
//transaction/call
|
|
|
|
if (tr.transactionData.size() > 0 && tr.transactionData.front().size() >= 4) |
|
|
|
if (tr.inputParameters.size() >= 4) |
|
|
|
{ |
|
|
|
functionHash = FixedHash<4>(tr.transactionData.front().data(), FixedHash<4>::ConstructFromPointer); |
|
|
|
functionHash = FixedHash<4>(tr.inputParameters.data(), FixedHash<4>::ConstructFromPointer); |
|
|
|
function = QString::fromStdString(toJS(functionHash)); |
|
|
|
abi = true; |
|
|
|
} |
|
|
|