This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var promise; | |
// starts the interval | |
$scope.start = function() { | |
// stops any running interval to avoid two intervals running at the same time | |
$scope.stop(); | |
// store the interval promise | |
promise = $interval(getOrderList, 5000); | |
console.log("start"); |
myApp.factory('Excel',function($window){
var uri='data:application/vnd.ms-excel;base64,',
template='<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns="http://www.w3.org/TR/REC-html40"><head><!--[if gte mso 9]><xml><x:ExcelWorkbook><x:ExcelWorksheets><x:ExcelWorksheet><x:Name>{worksheet}</x:Name><x:WorksheetOptions><x:DisplayGridlines/></x:WorksheetOptions></x:ExcelWorksheet></x:ExcelWorksheets></x:ExcelWorkbook></xml><![endif]--></head><body><table>{table}</table></body></html>',
base64=function(s){return $window.btoa(unescape(encodeURIComponent(s)));},
format=function(s,c){return s.replace(/{(\w+)}/g,function(m,p){return c[p];})};
return {
First you should have homebrew installed on your mac. How to install homebrew
Before installing gnuplot, you should install Aqua first. Go here to download the AquaTerm-1.1.1.dmg then install it.
If you have ever installed gnuplot before, please uninstall it first.
$ brew uninstall gnuplot
$ brew update && brew upgrade