Merge pull request #497 from cmgustavo/bug/glidera-02

Glidera: minor bug fixes
This commit is contained in:
Matias Alejo Garcia 2016-10-17 11:09:40 -03:00 committed by GitHub
commit 8f6e2e2843
4 changed files with 25 additions and 32 deletions

View File

@ -5,12 +5,12 @@ angular.module('copayApp.controllers').controller('glideraController',
$scope.network = glideraService.getEnvironment(); $scope.network = glideraService.getEnvironment();
$scope.openExternalLink = function(url, optIn, title, message, okText, cancelText) { $scope.openExternalLink = function(url) {
externalLinkService.open(url, optIn, title, message, okText, cancelText); externalLinkService.open(url);
}; };
var initGlidera = function(accessToken) { var initGlidera = function(accessToken) {
$scope.token = null; $scope.token = accessToken;
$scope.permissions = null; $scope.permissions = null;
$scope.email = null; $scope.email = null;
$scope.personalInfo = null; $scope.personalInfo = null;

View File

@ -52,7 +52,7 @@ angular.module('copayApp.controllers').controller('preferencesGlideraController'
$scope.$on("$ionicView.enter", function(event, data){ $scope.$on("$ionicView.enter", function(event, data){
$scope.network = glideraService.getEnvironment(); $scope.network = glideraService.getEnvironment();
$scope.token = accessToken; $scope.token = null;
$scope.permissions = null; $scope.permissions = null;
$scope.email = null; $scope.email = null;
$scope.personalInfo = null; $scope.personalInfo = null;

View File

@ -37,6 +37,7 @@ click-to-accept {
} }
&.button-primary, &.button-primary,
&.button-secondary, &.button-secondary,
&.button-light,
&.button-assertive { &.button-assertive {
&.button-standard { &.button-standard {
@extend %button-standard; @extend %button-standard;

View File

@ -3,15 +3,20 @@
<ion-nav-back-button> <ion-nav-back-button>
</ion-nav-back-button> </ion-nav-back-button>
<ion-nav-title>Glidera</ion-nav-title> <ion-nav-title>Glidera</ion-nav-title>
<ion-nav-buttons side="secondary">
<button class="button back-button" ng-show="token" ui-sref="tabs.buyandsell.glidera.preferences">
<i class="icon ion-ios-gear-outline"></i>
</button>
</ion-nav-buttons>
</ion-nav-bar> </ion-nav-bar>
<ion-content> <ion-content>
<div class="box-notification error" ng-show="!network"> <div class="box-notification error m0" ng-show="!network">
Glidera is disabled for this application Glidera is disabled for this application
</div> </div>
<div class="box-notification warning" ng-show="network == 'testnet'"> <div class="box-notification warning m0" ng-show="network == 'testnet'">
Testnet wallets only work with Glidera Sandbox Accounts Testnet wallets only work with Glidera Sandbox Accounts
</div> </div>
@ -19,7 +24,7 @@
<div ng-init="showOauthForm = false"> <div ng-init="showOauthForm = false">
<div class="text-center m20v"> <div class="text-center m20v">
<img src="img/glidera-logo.png" ng-click="update(token, permissions)" width="200"> <img src="img/glidera-logo.png" ng-click="update({'fullUpdate': true})" width="200">
</div> </div>
<div class="text-center small-10 small-centered columns" ng-show="!showOauthForm"> <div class="text-center small-10 small-centered columns" ng-show="!showOauthForm">
<p class="glidera-lead">You can buy and sell Bitcoin with a US bank account directly in this app.</p> <p class="glidera-lead">You can buy and sell Bitcoin with a US bank account directly in this app.</p>
@ -59,7 +64,7 @@
<div class="col"> <div class="col">
<input type="button" <input type="button"
value="Cancel" value="Cancel"
class="button button-block button-light" class="button button-standard button-light"
ng-click="showOauthForm = false"> ng-click="showOauthForm = false">
</div> </div>
<div class="col"> <div class="col">
@ -75,33 +80,20 @@
</div> </div>
</div> </div>
<div ng-if="token && permissions"> <div ng-if="token">
<div class="text-center m20v"> <div class="text-center m20v">
<img src="img/glidera-logo.png" ng-click="update(token, permissions)" width="200"> <img src="img/glidera-logo.png" ng-click="update({'fullUpdate': true})" width="200">
</div> </div>
<div class="list"> <div class="text-center m30v size-12"
<a class="item item-icon-left item-icon-right" href ui-sref="tabs.buyandsell.glidera.preferences"> ng-show="status && !status.userCanTransact">
<i class="icon ion-ios-gear"></i> <h4 class="text-bold">Complete Setup</h4>
<span ng-show="personalInfo">{{personalInfo.firstName}} {{personalInfo.lastName}}</span> <div>Your Glidera account is not ready to transact. Please, verify it at <b>Glidera.io</b></div>
<span class="item-note" ng-show="email"> <a class="button"
{{email}} ng-init="glideraUrl = network == 'testnet' ? 'https://sandbox.glidera.io/login' : 'https://glidera.io/login'"
</span> ng-click="openExternalLink(glideraUrl)">
<i class="icon bp-arrow-right"></i> Go to Glidera
</a> </a>
</div> </div>
<div class="padding">
<div class="text-center m30v size-12"
ng-show="status && !status.userCanTransact">
<h4 class="text-bold"> Complete Setup</h4>
<div>Your Glidera account is not ready to transact. Please, verify it at <b>Glidera.io</b></div>
<a class="button"
ng-init="glideraUrl = network == 'testnet' ? 'https://sandbox.glidera.io/login' : 'https://glidera.io/login'"
ng-click="openExternalLink(glideraUrl)">
Go to Glidera
</a>
</div>
</div>
</div>
<div class="list" <div class="list"
ng-show="status && status.userCanTransact"> ng-show="status && status.userCanTransact">
@ -121,7 +113,7 @@
</a> </a>
</div> </div>
<div class="list card" ng-show="permissions.transaction_history"> <div class="list card" ng-show="permissions && permissions.transaction_history">
<div class="item item-heading"> <div class="item item-heading">
Activity Activity
</div> </div>