2014-08-29 09:36:38 -07:00
< div class = "send" data-ng-controller = "SendController" data-ng-init = "loadTxs()" >
2014-07-18 14:56:39 -07:00
< div ng-show = '$root.wallet.isReady()' >
2014-08-06 09:59:33 -07:00
2014-09-05 12:58:28 -07:00
< h1 translate ng-show = "txs.length != 0" > Send Proposals< / h1 >
2014-08-06 09:59:33 -07:00
< div class = "last-transactions" ng-repeat = "tx in txs | paged" >
< div ng-include = "'views/includes/transaction.html'" > < / div >
< / div >
< div ng-show = "txs.length != 0" class = "large-12 line-dashed" style = "padding: 0;" > < / div >
2014-10-27 12:13:06 -07:00
< h1 class = "hide-for-large-up" > {{$root.title}}< / h1 >
2014-09-10 07:15:57 -07:00
< div class = "row collapse m0" >
2014-09-10 07:18:07 -07:00
< div class = "large-6 columns" >
2014-09-08 14:58:24 -07:00
< form name = "sendForm" ng-submit = "submitForm(sendForm)" novalidate >
2014-09-10 07:15:57 -07:00
< div class = "row collapse" >
2014-09-08 14:58:24 -07:00
< div class = "large-12 columns" >
< div class = "row collapse" >
2014-10-15 05:47:07 -07:00
< label for = "address" > < span translate > To < / span > < a class = "has-tip size-12" href = "#"
data-options="disable_for_touch:true"
tooltip-popup-delay='500'
tooltip="{{'Enter a valid Bitcoin address. Payment Protocol URLs are also supported'|translate}}"
tooltip-trigger="mouseenter"
tooltip-placement="right">(?)< / a >
2014-09-10 07:15:57 -07:00
< small translate ng-hide = "!sendForm.address.$pristine || address" > required< / small >
< small translate class = "is-valid" ng-show = "!sendForm.address.$invalid && address" > valid!< / small >
< small translate class = "has-error" ng-show = "sendForm.address.$invalid && address" > not valid< / small >
2014-09-08 14:58:24 -07:00
< / label >
< div class = "small-10 columns" >
2014-09-08 16:51:37 -07:00
< input type = "text" id = "address" name = "address" ng-disabled = "loading || !!$root.merchant"
2014-09-11 11:19:19 -07:00
placeholder="{{'Bitcoin address'|translate}}" ng-model="address" ng-change="onChanged()" valid-address required>
2014-09-08 14:58:24 -07:00
< small class = "icon-input" ng-show = "!sendForm.address.$invalid && address" > < i class = "fi-check" > < / i > < / small >
< small class = "icon-input" ng-show = "sendForm.address.$invalid && address" > < i class = "fi-x" > < / i > < / small >
2014-07-16 13:59:28 -07:00
< / div >
2014-09-10 07:15:57 -07:00
< div class = "small-2 columns" ng-hide = "showScanner || disableScanner" >
2014-09-08 14:58:24 -07:00
< a class = "postfix button black" ng-click = "openScanner()" > < i class = "fi-camera" > < / i > < / a >
< / div >
< div class = "small-2 columns" ng-show = "showScanner" >
2014-09-10 07:15:57 -07:00
< a translate class = "postfix button warning" ng-click = "cancelScanner()" > Cancel< / a >
2014-09-08 14:58:24 -07:00
< / div >
< / div >
< div id = "scanner" class = "row" ng-if = "showScanner" >
< div class = "text-centered" >
< canvas id = "qr-canvas" width = "200" height = "150" > < / canvas >
< div ng-show = "isMobile" >
< div id = "file-input-wrapper" class = "btn btn-primary" >
< span class = "pull-left text-centered" >
< i class = "glyphicon glyphicon-refresh icon-rotate" > < / i >
2014-09-10 07:15:57 -07:00
< span translate > Get QR code< / span >
2014-09-08 14:58:24 -07:00
< / span >
< input id = "qrcode-camera" type = "file" capture = "camera" accept = "image/*" >
2014-07-22 06:54:12 -07:00
< / div >
< / div >
2014-09-08 14:58:24 -07:00
< div ng-hide = "isMobile" >
< video id = "qrcode-scanner-video" width = "300" height = "225" ng-hide = "isMobile" > < / video >
< / div >
2014-07-22 06:54:12 -07:00
< / div >
2014-07-18 14:56:39 -07:00
< / div >
2014-07-16 13:59:28 -07:00
< / div >
2014-09-08 14:58:24 -07:00
< / div >
2014-07-16 13:59:28 -07:00
2014-09-10 07:15:57 -07:00
< div class = "row collapse" >
2014-09-10 11:56:36 -07:00
< div class = "large-6 medium-6 columns" >
2014-09-08 14:58:24 -07:00
< div class = "row collapse" >
2014-09-10 07:15:57 -07:00
< label for = "amount" > < span translate > Amount< / span >
< small translate ng-hide = "!sendForm.amount.$pristine" > required< / small >
< small translate class = "is-valid"
ng-show="!sendForm.amount.$invalid & &
!sendForm.amount.$pristine">valid!< / small >
< small translate class = "has-error"
2014-10-07 08:39:16 -07:00
ng-show="(sendForm.amount.$invalid || notValidAmount) & &
!sendForm.amount.$pristine">not valid
2014-09-08 14:58:24 -07:00
< / small >
< / label >
< div class = "small-9 columns" >
< input type = "number" id = "amount"
ng-disabled="loading || ($root.merchant & & +$root.merchant.total > 0) || $root.merchantError"
2014-09-10 07:15:57 -07:00
name="amount" placeholder="{{'Amount'|translate}}" ng-model="amount"
2014-10-07 08:39:16 -07:00
min="0.00000001" max="10000000000" valid-amount required
2014-09-10 11:09:11 -07:00
autocomplete="off">
2014-09-08 14:58:24 -07:00
< small class = "icon-input" ng-show = "!sendForm.amount.$invalid && amount" > < i class = "fi-check" > < / i > < / small >
2014-10-07 08:39:16 -07:00
< small class = "icon-input" ng-show = "sendForm.amount.$invalid & &
!sendForm.amount.$pristine & & !notValidAmount">< i class = "fi-x" > < / i > < / small >
2014-09-10 07:15:57 -07:00
< a class = "small input-note" title = "{{'Send all funds'|translate}}"
2014-09-08 14:58:24 -07:00
ng-show="$root.availableBalance > 0 & & (!$root.merchant || +$root.merchant.total === 0)"
ng-click="topAmount(sendForm)">
2014-09-03 12:24:25 -07:00
< span translate > Use all funds< / span > ({{getAvailableAmount()}} {{$root.wallet.settings.unitName}})
2014-09-08 14:58:24 -07:00
< / a >
< / div >
< div class = "small-3 columns" >
2014-09-03 12:24:25 -07:00
< span class = "postfix" > {{$root.wallet.settings.unitName}}< / span >
2014-07-22 06:54:12 -07:00
< / div >
< / div >
2014-09-08 14:58:24 -07:00
< / div >
2014-09-10 07:18:07 -07:00
< div class = "large-5 medium-5 columns" >
2014-09-08 14:58:24 -07:00
< div class = "row collapse" >
2014-09-10 07:15:57 -07:00
< label for = "alternative" > < span translate > Amount in< / span > {{ alternativeName }} < / label >
2014-09-08 14:58:24 -07:00
< div class = "small-9 columns" >
< input type = "number" id = "alternative_amount"
ng-disabled="loading || !isRateAvailable || ($root.merchant & & +$root.merchant.total > 0) || $root.merchantError"
2014-09-10 07:15:57 -07:00
name="alternative" placeholder="{{'Amount'|translate}}" ng-model="alternative"
2014-09-08 14:58:24 -07:00
required
autocomplete="off"
>
< / div >
< div class = "small-3 columns" >
< span class = "postfix" > {{alternativeIsoCode}}< / span >
2014-08-27 10:20:13 -07:00
< / div >
< / div >
< / div >
2014-09-08 14:58:24 -07:00
< / div >
2014-07-16 13:59:28 -07:00
2014-10-23 08:33:55 -07:00
< div class = "row collapse" >
2014-09-08 14:58:24 -07:00
< div class = "large-12 columns" >
< div class = "row collapse" >
2014-09-10 07:15:57 -07:00
< label for = "comment" > < span translate > Note< / span >
< small translate ng-hide = "!sendForm.comment.$pristine" > optional< / small >
< small translate class = "has-error" ng-show = "sendForm.comment.$invalid && !sendForm.comment.$pristine" > too long!< / small >
2014-09-08 14:58:24 -07:00
< / label >
< div class = "large-12 columns" >
< textarea id = "comment" ng-disabled = "loading"
2014-10-23 08:33:55 -07:00
name="comment" placeholder="{{(wallet.isShared() ? 'Leave a private message to your copayers' : 'Add a private comment to identify the transaction') |translate}}" ng-model="commentText" ng-maxlength="100">< / textarea >
2014-07-22 06:54:12 -07:00
< / div >
< / div >
2014-07-16 13:59:28 -07:00
< / div >
2014-09-08 14:58:24 -07:00
< / div >
2014-09-18 09:05:41 -07:00
2014-09-10 07:15:57 -07:00
< div class = "row collapse" >
2014-09-18 07:55:58 -07:00
< span ng-if = "!$root.alternativeConversionRate" >
< i class = "fi-bitcoin-circle icon-rotate spinner" > < / i >
< / span >
< span class = "left m5t text-gray size-14" ng-if = "$root.alternativeConversionRate > 0" > 1 BTC = {{alternativeConversionRate|noFractionNumber:2}} {{alternativeIsoCode}}
< / span >
< div class = "large-5 medium-3 small-6 columns right" >
2014-09-09 12:45:58 -07:00
< button type = "submit" class = "button primary expand text-center" ng-disabled = "sendForm.$invalid || loading" >
2014-09-08 14:58:24 -07:00
Send
< / button >
2014-07-22 06:54:12 -07:00
< / div >
2014-09-08 14:58:24 -07:00
< / div >
< / form >
< / div >
2014-09-10 07:15:57 -07:00
< / div > <!-- end of row -->
2014-07-22 06:54:12 -07:00
2014-08-29 14:38:19 -07:00
< div class = "large-6 columns show-for-large-up" ng-show = "!!$root.merchant" >
2014-07-22 07:27:10 -07:00
< div class = "send-note" >
2014-09-10 07:15:57 -07:00
< h6 translate > Send to< / h6 >
2014-09-08 16:51:37 -07:00
< p class = "text-gray" ng-class = "{'hidden': sendForm.address.$invalid || !address}"
title="{{$root.merchant.request_url}}">
{{$root.merchant.domain}}
2014-07-21 11:36:53 -07:00
< / p >
2014-09-10 07:15:57 -07:00
< h6 translate > Total amount for this transaction:< / h6 >
2014-08-11 12:32:02 -07:00
< p class = "text-gray" ng-class = "{'hidden': sendForm.amount.$invalid || !amount > 0}" >
2014-09-03 12:24:25 -07:00
< b > {{amount + defaultFee |noFractionNumber}}< / b > {{$root.wallet.settings.unitName}}
2014-08-29 09:36:38 -07:00
< small ng-if = "isRateAvailable" >
{{ rateService.toFiat((amount + defaultFee) * unitToSatoshi, alternativeIsoCode) | noFractionNumber: 2 }} {{ alternativeIsoCode }}
2014-08-29 14:38:19 -07:00
< br >
2014-08-29 09:36:38 -07:00
< / small >
2014-07-22 06:54:12 -07:00
< small >
2014-09-03 12:24:25 -07:00
< span translate > Including fee of< / span > {{defaultFee|noFractionNumber}} {{$root.wallet.settings.unitName}}
2014-07-22 06:54:12 -07:00
< / small >
2014-07-21 11:36:53 -07:00
< / p >
2014-08-11 12:32:02 -07:00
< div ng-show = "wallet.isShared()" >
2014-09-10 07:15:57 -07:00
< h6 translate > Note< / h6 >
2014-08-11 12:32:02 -07:00
< p ng-class = "{'hidden': !commentText}" > {{commentText}}< / p >
< / div >
< div ng-show = "!!$root.merchant" >
2014-09-10 07:15:57 -07:00
< h6 translate > Merchant Data:< / h6 >
2014-08-11 12:32:02 -07:00
< p class = "text-gray" >
Note: This is a payment protocol transaction.
< / p >
2014-09-10 07:15:57 -07:00
< h6 translate > Server Says:< / h6 >
2014-08-11 12:32:02 -07:00
< p class = "text-gray" >
{{$root.merchant.pr.pd.memo}}
< / p >
2014-09-10 07:15:57 -07:00
< h6 translate > Certificate:< / h6 >
2014-08-11 12:32:02 -07:00
< p class = "text-gray" >
2014-08-08 12:51:50 -07:00
< span ng-show = "!!$root.merchant.pr.ca" > {{$root.merchant.pr.ca}}< / span >
< span ng-show = "!$root.merchant.pr.ca" style = "color:red;weight:bold;" > Untrusted< / span >
2014-08-11 12:32:02 -07:00
< / p >
2014-09-10 07:15:57 -07:00
< h6 translate > Payment Expiration:< / h6 >
2014-08-11 12:32:02 -07:00
< p class = "text-gray" >
{{$root.merchant.expiration}}
< / p >
< / div >
2014-07-18 14:56:39 -07:00
< / div >
2014-07-22 06:54:12 -07:00
< / div >
2014-07-18 14:56:39 -07:00
2014-07-31 12:40:26 -07:00
< div class = "large-12 columns line-dashed" >
2014-09-05 12:58:28 -07:00
< h2 translate > Address Book< / h2 >
2014-09-10 07:15:57 -07:00
< p translate class = "text-gray m15b" ng-hide = "showAddressBook()" > Empty. Create an alias for your addresses< / p >
2014-07-31 12:40:26 -07:00
< table class = "large-12 medium-12 small-12" ng-show = "showAddressBook()" >
< thead >
< tr >
2014-09-05 12:58:28 -07:00
< th translate > Label< / th >
< th translate > Address< / th >
2014-09-17 05:45:21 -07:00
< th ng-class = "{'hide-for-small-only' : $root.wallet.isShared()}" ng-show = "$root.wallet.isShared()" translate > Creator< / th >
2014-09-16 08:04:21 -07:00
< th class = "hide-for-small-only" translate > Date< / th >
< th class = "hide-for-small-only" > < / th >
2014-07-16 13:59:28 -07:00
< / tr >
2014-07-31 12:40:26 -07:00
< / thead >
< tbody >
2014-08-08 12:51:50 -07:00
< tr
ng-repeat="(addr, info) in $root.wallet.addressBook"
2014-07-31 12:40:26 -07:00
ng-class="{'addressbook-disabled': info.hidden}">
< td > < a ng-click = "copyAddress(addr)" title = "Copy address" > {{info.label}}< / a > < / td >
2014-09-16 08:04:21 -07:00
< td class = "size-12" > {{addr}} < span class = "btn-copy" clip-copy = "addr" > < / span > < / td >
2014-09-17 05:45:21 -07:00
< td ng-show = "$root.wallet.isShared()" ng-class = "{'hide-for-small-only' : $root.wallet.isShared()}" > {{$root.wallet.publicKeyRing.nicknameForCopayer(info.copayerId)}}< / td >
2014-09-16 08:04:21 -07:00
< td class = "hide-for-small-only" > < time > {{info.createdTs | amCalendar}}< / time > < / td >
< td class = "hide-for-small-only" width = "5" > < a ng-click = "toggleAddressBookEntry(addr)" > {{info.hidden ?
2014-07-31 12:40:26 -07:00
'Enable' : 'Disable'}}< / a > < / td >
< / tr >
< / tbody >
< / table >
2014-09-15 07:49:53 -07:00
< button translate class = "button tiny primary text-center" ng-click = "openAddressBookModal()" > Add< / button >
2014-07-31 12:40:26 -07:00
< / div >
2014-07-16 13:59:28 -07:00
< / div >
< / div >