diff options
Diffstat (limited to 'public/js')
| -rw-r--r-- | public/js/calculator.coffee | 10 | ||||
| -rw-r--r-- | public/js/setup.coffee | 1 |
2 files changed, 4 insertions, 7 deletions
diff --git a/public/js/calculator.coffee b/public/js/calculator.coffee index 700e9903..c90954ab 100644 --- a/public/js/calculator.coffee +++ b/public/js/calculator.coffee @@ -58,16 +58,12 @@ setup = -> g.commission or= 0 g.symbol or= 'quadrigacx' - if g.title - $('#title').html(g.title).show() - if g.logo $('#logo').attr('src', g.logo).show() - else unless g.title - $('#logo').attr('src', '/assets/img/bitcoin.png').show() + else if g.title + $('#title').html("<a href='/#{g.user}/edit'>#{g.title}</a>").show() - $('#logo').click -> $(location).attr("href","/#{g.user}/edit") - $('#address').html("#{address} <a href='http://blockchain.info/address/#{address}' target='_blank'><img src='/assets/img/blockchain.png' /></a>") + $('#address').html("<a href='/#{g.user}/report'>#{address}</a> <a href='http://blockchain.info/address/#{address}' target='_blank'><img src='/assets/img/blockchain.png' /></a>") $('#symbol').html(g.symbol + " bid") $('#currency').html(g.currency) $('#unit').html(g.unit) diff --git a/public/js/setup.coffee b/public/js/setup.coffee index ce6b3963..7daf960f 100644 --- a/public/js/setup.coffee +++ b/public/js/setup.coffee @@ -80,6 +80,7 @@ $(-> $.getJSON("/#{user}.json", (data) -> $('#title').val(data.title) $('#address').val(data.address) + $('#logo').val(data.logo) $("#symbol option[value='#{data.symbol}']").attr('selected', 'selected') $('#commission').val(data.commission) $('#unit').val(data.unit) |
