This commit is contained in:
Gabriel Bazán 2016-11-11 10:21:25 -03:00
parent 2284e2507f
commit d390292b91
5 changed files with 9 additions and 11 deletions

View File

@ -1,6 +1,8 @@
'use strict';
angular.module('copayApp.controllers').controller('rateCardController', function($scope, $state, $timeout, gettextCatalog, storageService) {
angular.module('copayApp.controllers').controller('rateCardController', function($scope, $state, $timeout, gettextCatalog, platformInfo, storageService) {
$scope.isCordova = platformInfo.isCordova;
$scope.goFeedbackFlow = function() {
if ($scope.isModal) {

View File

@ -19,11 +19,11 @@ angular.module('copayApp.controllers').controller('welcomeController', function(
$log.debug('Creating profile');
profileService.createProfile(function(err) {
if (err) $log.warn(err);
$scope.setProfileCreationTime();
setProfileCreationTime();
});
};
$scope.setProfileCreationTime = function() {
function setProfileCreationTime() {
var now = moment().unix() * 1000 + 24 * 60 * 60 * 1000;
storageService.setProfileCreationTime(now, function() {});
};

View File

@ -25,9 +25,6 @@ angular.module('copayApp.services').factory('configService', function(storageSer
wp: ''
},
feedback: {
url: 'https://script.google.com/macros/s/AKfycbybtvNSQKUfgzgXcj3jYLlvCKrcBoktjiJ1V8_cwd2yVkpUBGe3/exec'
},
// wallet default config
wallet: {
requiredCopayers: 2,

View File

@ -1,6 +1,8 @@
'use strict';
angular.module('copayApp.services').factory('feedbackService', function($http, $log, $httpParamSerializer, configService) {
var root = {};
var URL = "https://script.google.com/macros/s/AKfycbybtvNSQKUfgzgXcj3jYLlvCKrcBoktjiJ1V8_cwd2yVkpUBGe3/exec";
root.send = function(dataSrc, cb) {
$http(_post(dataSrc)).then(function() {
$log.info("SUCCESS: Feedback sent");
@ -12,12 +14,9 @@ angular.module('copayApp.services').factory('feedbackService', function($http, $
};
var _post = function(dataSrc) {
var config = configService.getSync();
var url = config.feedback.url;
return {
method: 'POST',
url: url,
url: URL,
headers: {
'content-type': 'application/x-www-form-urlencoded; charset=UTF-8'
},

View File

@ -29,7 +29,7 @@
<img src="img/icon-link.svg" class="bg just-a-hint"/>
</i>
</a>
<a class="ng-hide item item-icon-left item-icon-right" ng-show="true" ng-click="openRateModal()">
<a class="item item-icon-left item-icon-right" ng-click="openRateModal()">
<i class="icon big-icon-svg">
<img src="img/icon-send-feedback.svg" class="bg"/>
</i>