mirror of
https://github.com/d0zingcat/gocryptotrader.git
synced 2026-05-16 15:09:57 +00:00
Uses rootscope to announce when a currency + exchange is selected to allow all components to adapt to new data.
26 lines
708 B
JavaScript
26 lines
708 B
JavaScript
angular.module('myApp.stringUtils', [])
|
|
.filter('removeSpaces', [function () {
|
|
return function (string) {
|
|
if (!angular.isString(string)) {
|
|
return string;
|
|
}
|
|
return string.replace(/[\s]/g, '');
|
|
};
|
|
}]);
|
|
/*
|
|
angular.module('myApp.currenctExchangeFactory', []).factory('currentExchangeCurrency', function() {
|
|
var currentExchangeAndCurrency = {};
|
|
var exchangeService = {};
|
|
|
|
exchangeService.get = function() {
|
|
return currentExchangeAndCurrency;
|
|
};
|
|
exchangeService.update = function(exchange, currency) {
|
|
currentExchangeAndCurrency.Exchange = exchange;
|
|
currentExchangeAndCurrency.Currency = currency;
|
|
};
|
|
|
|
return exchangeService;
|
|
});
|
|
*/
|