Add low balance checking on Wallet page
This commit is contained in:
parent
4b521f29e6
commit
09cad7196b
1 changed files with 11 additions and 0 deletions
|
@ -24,6 +24,17 @@ var NewAddressSection = React.createClass({
|
|||
|
||||
var SendToAddressSection = React.createClass({
|
||||
sendToAddress: function() {
|
||||
if (this.state.amount > this.state.balance)
|
||||
{
|
||||
alert("The amount you're trying to send is greater than the number of credits in your wallet.");
|
||||
return;
|
||||
}
|
||||
else if ((this.state.balance - this.state.amount) < 1)
|
||||
{
|
||||
alert("Insufficient balance: after this transaction you would have less than 1 LBC in your wallet.")
|
||||
return;
|
||||
}
|
||||
|
||||
this.setState({
|
||||
results: "",
|
||||
});
|
||||
|
|
Loading…
Add table
Reference in a new issue