Skip to content

Instantly share code, notes, and snippets.

View martymarkenson's full-sized avatar

Marty Markenson martymarkenson

View GitHub Profile
@martymarkenson
martymarkenson / 0_reuse_code.js
Created September 6, 2017 15:10
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
$scope.$watch("view.wdg['currentGauge']['text']", function() {
if($scope.view.wdg['currentGauge']['text'] > 5) {
$scope.view.wdg['currentGauge']['src'] = 'app/resources/Uploaded/current_red.png';
}
else if($scope.view.wdg['currentGauge']['text'] > 1) {
$scope.view.wdg['currentGauge']['src'] = 'app/resources/Uploaded/current_green.png';
}
else{
$scope.view.wdg['currentGauge']['src'] = 'app/resources/Uploaded/current_yellow.png';
}