refactor settings tab
This commit is contained in:
parent
9e70821c4c
commit
41cc509d47
21 changed files with 462 additions and 252 deletions
|
|
@ -1,25 +1,28 @@
|
|||
'use strict';
|
||||
|
||||
angular.module('copayApp.controllers').controller('preferencesLogs',
|
||||
function(historicLog) {
|
||||
this.logs = historicLog.get();
|
||||
function($scope, historicLog) {
|
||||
|
||||
this.sendLogs = function() {
|
||||
var body = 'Copay Session Logs\n Be careful, this could contain sensitive private data\n\n';
|
||||
body += '\n\n';
|
||||
body += this.logs.map(function(v) {
|
||||
return v.msg;
|
||||
}).join('\n');
|
||||
$scope.init = function() {
|
||||
$scope.logs = historicLog.get();
|
||||
}
|
||||
|
||||
window.plugins.socialsharing.shareViaEmail(
|
||||
body,
|
||||
'Copay Logs',
|
||||
null, // TO: must be null or an array
|
||||
null, // CC: must be null or an array
|
||||
null, // BCC: must be null or an array
|
||||
null, // FILES: can be null, a string, or an array
|
||||
function() {},
|
||||
function() {}
|
||||
);
|
||||
};
|
||||
});
|
||||
$scope.sendLogs = function() {
|
||||
var body = 'Copay Session Logs\n Be careful, this could contain sensitive private data\n\n';
|
||||
body += '\n\n';
|
||||
body += $scope.logs.map(function(v) {
|
||||
return v.msg;
|
||||
}).join('\n');
|
||||
|
||||
window.plugins.socialsharing.shareViaEmail(
|
||||
body,
|
||||
'Copay Logs',
|
||||
null, // TO: must be null or an array
|
||||
null, // CC: must be null or an array
|
||||
null, // BCC: must be null or an array
|
||||
null, // FILES: can be null, a string, or an array
|
||||
function() {},
|
||||
function() {}
|
||||
);
|
||||
};
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue