you now have the option to clear or keep inputs when building a transaction
This commit is contained in:
parent
e486adbcc8
commit
245f1e4508
2 changed files with 8 additions and 2 deletions
|
@ -300,7 +300,10 @@
|
|||
</span>
|
||||
</div>
|
||||
|
||||
<p class="text-muted">Enter a regular address or the redeem script to automatically load the inputs to build a transaction</p>
|
||||
|
||||
<div class="checkbox">
|
||||
<label><input type="checkbox" id="clearInputsOnLoad" class="checkbox-inline" checked> Clear existing inputs when new inputs are loaded</label>
|
||||
</div>
|
||||
|
||||
<div class="hidden alert alert-danger" id="redeemFromStatus"></div>
|
||||
|
||||
|
|
|
@ -405,7 +405,10 @@ $(document).ready(function() {
|
|||
var tx = coinjs.transaction();
|
||||
tx.listUnspent(addr, function(data){
|
||||
if(addr) {
|
||||
$("#inputs .txidRemove, #inputs .txidClear").click();
|
||||
if($("#clearInputsOnLoad").is(":checked")){
|
||||
$("#inputs .txidRemove, #inputs .txidClear").click();
|
||||
}
|
||||
|
||||
$("#redeemFromAddress").removeClass('hidden').html('<span class="glyphicon glyphicon-info-sign"></span> Retrieved unspent inputs from address <a href="https://www.blockchain.info/address/'+addr+'" target="_blank">'+addr+'</a>');
|
||||
|
||||
$.each($(data).find("unspent").children(), function(i,o){
|
||||
|
|
Loading…
Reference in a new issue