mirror of
https://github.com/status-im/snt-gas-relay.git
synced 2025-01-27 22:54:56 +00:00
Changed baseToken to its own row
This commit is contained in:
parent
8e32274461
commit
b90ac50ec9
@ -15,6 +15,7 @@ class ApproveAndCallGasRelayed extends React.Component {
|
|||||||
value: 0,
|
value: 0,
|
||||||
data: '0x00',
|
data: '0x00',
|
||||||
nonce: 0,
|
nonce: 0,
|
||||||
|
baseToken: '0x0000000000000000000000000000000000000000',
|
||||||
gasPrice: 0,
|
gasPrice: 0,
|
||||||
gasLimit: 0,
|
gasLimit: 0,
|
||||||
gasToken: "0x0000000000000000000000000000000000000000",
|
gasToken: "0x0000000000000000000000000000000000000000",
|
||||||
@ -76,8 +77,9 @@ class ApproveAndCallGasRelayed extends React.Component {
|
|||||||
});
|
});
|
||||||
|
|
||||||
try {
|
try {
|
||||||
let jsonAbi = this.props.IdentityGasRelay._jsonInterface.filter(x => x.name == "callGasRelayed")[0]
|
let jsonAbi = this.props.IdentityGasRelay._jsonInterface.filter(x => x.name == "approveAndCallGasRelayed")[0]
|
||||||
let funCall = this.props.web3.eth.abi.encodeFunctionCall(jsonAbi, [this.state.to,
|
let funCall = this.props.web3.eth.abi.encodeFunctionCall(jsonAbi, [this.state.baseToken,
|
||||||
|
this.state.to,
|
||||||
this.state.value,
|
this.state.value,
|
||||||
this.state.data,
|
this.state.data,
|
||||||
this.state.nonce,
|
this.state.nonce,
|
||||||
@ -121,7 +123,8 @@ class ApproveAndCallGasRelayed extends React.Component {
|
|||||||
});
|
});
|
||||||
|
|
||||||
try {
|
try {
|
||||||
let message = await this.props.IdentityGasRelay.methods.callGasRelayHash(
|
let message = await this.props.IdentityGasRelay.methods.approveAndCallGasRelayHash(
|
||||||
|
this.state.baseToken,
|
||||||
this.state.to,
|
this.state.to,
|
||||||
this.state.value,
|
this.state.value,
|
||||||
this.props.web3.utils.soliditySha3({t: 'bytes', v: this.state.data}),
|
this.props.web3.utils.soliditySha3({t: 'bytes', v: this.state.data}),
|
||||||
@ -151,7 +154,7 @@ class ApproveAndCallGasRelayed extends React.Component {
|
|||||||
}
|
}
|
||||||
<Form>
|
<Form>
|
||||||
<Row>
|
<Row>
|
||||||
<Col md={9}>
|
<Col md={8}>
|
||||||
<ControlLabel>Identity Address</ControlLabel>
|
<ControlLabel>Identity Address</ControlLabel>
|
||||||
<InputGroup>
|
<InputGroup>
|
||||||
<InputGroup.Addon>0x</InputGroup.Addon>
|
<InputGroup.Addon>0x</InputGroup.Addon>
|
||||||
@ -159,6 +162,17 @@ class ApproveAndCallGasRelayed extends React.Component {
|
|||||||
</InputGroup>
|
</InputGroup>
|
||||||
</Col>
|
</Col>
|
||||||
</Row>
|
</Row>
|
||||||
|
<Row>
|
||||||
|
<Col md={8}>
|
||||||
|
<ControlLabel>Base Token</ControlLabel>
|
||||||
|
<InputGroup>
|
||||||
|
<InputGroup.Addon>0x</InputGroup.Addon>
|
||||||
|
<FormControl type="text" defaultValue={this.state.baseToken} onChange={(ev) => this.handleChange(ev, 'baseToken')} />
|
||||||
|
</InputGroup>
|
||||||
|
<HelpBlock>RND: {this.props.RND.options.address}</HelpBlock>
|
||||||
|
<HelpBlock>ETH: 0x0000000000000000000000000000000000000000</HelpBlock>
|
||||||
|
</Col>
|
||||||
|
</Row>
|
||||||
<Row>
|
<Row>
|
||||||
<Col md={4}>
|
<Col md={4}>
|
||||||
<ControlLabel>To</ControlLabel>
|
<ControlLabel>To</ControlLabel>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user