Fixed an issue with sending gas to a contract

pull/32/head
obscuren 11 years ago
parent ebbc5e7cb8
commit 97b98b1250
  1. 2
      ethereal/assets/qml/wallet.qml
  2. 4
      ethereal/ui/library.go

@ -198,7 +198,7 @@ ApplicationWindow {
id: txButton
text: "Send"
onClicked: {
this.enabled = false
//this.enabled = false
console.log(eth.createTx(txRecipient.text, txValue.text, txGas.text, txGasPrice.text, codeView.text))
}
}

@ -30,7 +30,7 @@ func (lib *EthLib) CreateTx(recipient, valueStr, gasStr, gasPriceStr, data strin
keyPair := ethutil.Config.Db.GetKeys()[0]
value := ethutil.Big(valueStr)
gas := ethutil.Big(valueStr)
gas := ethutil.Big(gasStr)
gasPrice := ethutil.Big(gasPriceStr)
var tx *ethchain.Transaction
// Compile and assemble the given data
@ -40,7 +40,7 @@ func (lib *EthLib) CreateTx(recipient, valueStr, gasStr, gasPriceStr, data strin
return err.Error()
}
code := ethutil.Assemble(asm)
code := ethutil.Assemble(asm...)
tx = ethchain.NewContractCreationTx(value, gasPrice, code)
} else {
tx = ethchain.NewTransactionMessage(hash, value, gasPrice, gas, []string{})

Loading…
Cancel
Save