2016-12-08 06:04:07 -08:00
< ion-view id = "coinbase" >
< ion-nav-bar class = "bar-royal" >
< ion-nav-back-button >
< / ion-nav-back-button >
< ion-nav-title > Coinbase< / ion-nav-title >
< / ion-nav-bar >
2017-01-31 16:31:16 -08:00
< ion-nav-buttons side = "secondary" >
2017-02-01 13:58:24 -08:00
< button class = "button button-clear button-small ng-hide" ng-show = "!accessToken" ng-click = "coinbase.toggleOauthForm()" >
2017-03-01 12:56:35 -08:00
< span ng-hide = "showOauthForm" > Enter Code< / span >
< span ng-show = "showOauthForm" > Restart< / span >
2017-01-31 16:31:16 -08:00
< / button >
< / ion-nav-buttons >
< ion-content scroll = "false" class = "ng-hide" ng-show = "!accessToken" >
< div class = "integration-onboarding" >
< div class = "integration-onboarding-logo" >
< img src = "img/coinbase-logo.png" >
2016-04-13 10:08:03 -07:00
< / div >
2017-03-01 12:56:35 -08:00
< div class = "integration-onboarding-description" ng-hide = "showOauthForm" > Coinbase's exchange service is available in 33 countries, and can take 3-5 days to buy or sell bitcoin.< / div >
< div class = "integration-onboarding-description" ng-show = "showOauthForm" > If you have trouble, contact Coinbase support for direct assistance.< / div >
2017-01-31 16:31:16 -08:00
< div class = "integration-onboarding-cta" ng-show = "!showOauthForm" >
2017-03-01 12:56:35 -08:00
< button class = "button button-standard button-primary" ng-click = "coinbase.openAuthenticateWindow()" > Connect Coinbase Account< / button >
< button class = "button button-standard button-secondary" ng-click = "coinbase.openSignupWindow()" > Sign Up for Coinbase< / button >
2016-04-13 10:08:03 -07:00
< / div >
2017-01-31 16:31:16 -08:00
< div ng-show = "showOauthForm" class = "integration-onboarding-oauthform" >
2016-04-13 10:08:03 -07:00
< form name = "oauthCodeForm" ng-submit = "coinbase.submitOauthCode(code)" novalidate >
2017-01-31 16:31:16 -08:00
< div class = "list" >
< label class = "item item-input item-floating-label" >
2016-12-08 06:04:07 -08:00
< span class = "input-label" > OAuth Code< / span >
< input type = "text"
ng-model="code"
2017-01-31 16:31:16 -08:00
placeholder="{{'Enter OAuth Code'}}" required>
2016-12-08 06:04:07 -08:00
< / label >
< / div >
2016-04-13 10:08:03 -07:00
< input
2016-12-08 06:04:07 -08:00
class="button button-standard button-primary"
type="submit" value="Connect Coinbase Account" ng-disabled="oauthCodeForm.$invalid">
2017-03-01 12:56:35 -08:00
< button type = "button" class = "button button-standard button-secondary" ng-click = "coinbase.openSupportWindow()" > Coinbase Support → < / button >
2016-04-13 10:08:03 -07:00
< / form >
< / div >
< / div >
2017-01-31 16:31:16 -08:00
< / ion-content >
< ion-content class = "ng-hide" ng-show = "accessToken" >
2016-04-13 10:08:03 -07:00
2017-01-31 16:31:16 -08:00
< div >
2016-04-13 10:08:03 -07:00
2017-01-12 20:05:52 -08:00
< div class = "m20t text-center" ng-click = "updateTransactions()" >
2016-12-08 06:13:33 -08:00
< img src = "img/coinbase-logo.png" width = "200" >
< / div >
2017-01-12 20:05:52 -08:00
< div class = "list card" >
2016-12-08 06:04:07 -08:00
< a class = "item item-icon-right"
2017-01-12 04:58:12 -08:00
href ui-sref="tabs.buyandsell.coinbase.amount({nextStep: 'tabs.buyandsell.coinbase.buy', currency: currency})">
2017-01-13 06:05:33 -08:00
< img src = "img/buy-bitcoin.svg" alt = "buy bitcoin" width = "30" class = "item-img-buy" style = "vertical-align:
text-bottom;">
2016-12-08 06:04:07 -08:00
Buy Bitcoin
2017-02-20 10:48:17 -08:00
< span class = "item-note" >
< ion-spinner class = "spinner-dark recent" icon = "crescent" ng-show = "!buyPrice" > < / ion-spinner >
< span ng-show = "buyPrice" > {{buyPrice.amount|currency:'$':2}} {{buyPrice.currency}}/BTC< / span >
< / span >
2016-12-08 06:04:07 -08:00
< i class = "icon bp-arrow-right" > < / i >
< / a >
< a class = "item item-icon-right"
2017-04-21 05:32:54 -07:00
href ui-sref="tabs.buyandsell.coinbase.amount({nextStep: 'tabs.buyandsell.coinbase.sell', currency: currency})" no-low-fee>
2017-01-13 06:05:33 -08:00
< img src = "img/sell-bitcoin.svg" alt = "sell bitcoin" width = "30" class = "item-img-sell" style = "vertical-align:
text-bottom;">
2016-12-08 06:04:07 -08:00
Sell Bitcoin
2017-02-20 10:48:17 -08:00
< span class = "item-note" >
< ion-spinner class = "spinner-dark recent" icon = "crescent" ng-show = "!sellPrice" > < / ion-spinner >
< span ng-show = "sellPrice" > {{sellPrice.amount|currency:'$':2}} {{sellPrice.currency}}/BTC< / span >
< / span >
2016-12-08 06:04:07 -08:00
< i class = "icon bp-arrow-right" > < / i >
< / a >
2016-04-13 10:08:03 -07:00
< / div >
2016-12-08 06:04:07 -08:00
< div class = "list card" >
< div class = "item item-heading" ng-click = "updateTransactions()" >
Activity
2017-01-31 16:31:16 -08:00
< / div >
2016-12-08 06:04:07 -08:00
< a class = "item"
2016-12-30 14:08:51 -08:00
ng-if="pendingTransactions.data & & !error"
ng-repeat="(id, tx) in pendingTransactions.data | orderObjectBy:'updated_at':true track by $index"
2016-12-08 06:04:07 -08:00
ng-click="coinbase.openTxModal(tx)">
2016-04-13 10:08:03 -07:00
2016-12-08 06:04:07 -08:00
< span class = "item-note" >
2017-01-12 15:29:34 -08:00
< div class = "assertive" ng-show = "tx.error || tx.status == 'error'" >
2016-04-13 10:08:03 -07:00
Error
< / div >
2016-12-08 06:04:07 -08:00
< div ng-show = "!tx.error" >
2016-04-13 10:08:03 -07:00
< div ng-show = "tx.status == 'completed'" >
< time ng-if = "tx.created_at" > {{tx.created_at | amTimeAgo}}< / time >
< / div >
< div ng-show = "tx.status == 'pending'" >
2016-12-08 06:04:07 -08:00
< span ng-if = "tx.status == 'pending'" > Pending< / span >
2016-04-13 10:08:03 -07:00
< / div >
< / div >
2016-12-08 06:04:07 -08:00
< / span >
< img class = "left m10r" src = "img/bought-pending.svg" alt = "bought" width = "24" ng-show = "(tx.type == 'buy' || (tx.to && tx.type == 'send')) && tx.status != 'completed'" >
< img class = "left m10r" src = "img/bought.svg" alt = "bought" width = "30" ng-show = "(tx.type == 'buy' || (tx.to && tx.type == 'send')) && tx.status == 'completed'" >
< img class = "left m10r" src = "img/sold-pending.svg" alt = "sold" width = "24" ng-show = "tx.from && tx.type == 'send'" >
< img class = "left m10r" src = "img/sold.svg" alt = "sold" width = "30" ng-show = "!tx.from && tx.type == 'sell' && tx.status == 'completed'" >
< h2 >
< span ng-show = "tx.type == 'sell' && tx.status == 'completed'" > Sold< / span >
2017-01-05 13:10:57 -08:00
< span ng-show = "tx.type == 'send' && tx.to && tx.status == 'completed'" > Bought< / span >
2016-12-08 06:04:07 -08:00
< / h2 >
< p >
< span ng-if = "tx.type == 'sell' || (tx.type == 'send' && tx.from)" > -< / span > {{tx.amount.amount.replace('-','')}}
{{tx.amount.currency}}
< / p >
< / a >
2016-04-13 10:08:03 -07:00
< / div >
< / div >
2016-12-08 06:04:07 -08:00
< / ion-content >
< / ion-view >