summaryrefslogtreecommitdiffstats
path: root/framework/src/onos/web/gui/src/main/webapp/_sdh/ng-examples/js
diff options
context:
space:
mode:
Diffstat (limited to 'framework/src/onos/web/gui/src/main/webapp/_sdh/ng-examples/js')
-rw-r--r--framework/src/onos/web/gui/src/main/webapp/_sdh/ng-examples/js/ch03-controller.js17
-rw-r--r--framework/src/onos/web/gui/src/main/webapp/_sdh/ng-examples/js/ch09-01-time-ago.js27
2 files changed, 0 insertions, 44 deletions
diff --git a/framework/src/onos/web/gui/src/main/webapp/_sdh/ng-examples/js/ch03-controller.js b/framework/src/onos/web/gui/src/main/webapp/_sdh/ng-examples/js/ch03-controller.js
deleted file mode 100644
index 92d3b0c0..00000000
--- a/framework/src/onos/web/gui/src/main/webapp/_sdh/ng-examples/js/ch03-controller.js
+++ /dev/null
@@ -1,17 +0,0 @@
-// Simple controller
-
-angular.module('notesApp', [])
- .controller('ListCtrl', [function () {
- var self = this;
- self.items = [
- {id: 1, label: 'First', done: true},
- {id: 2, label: 'Second', done: false}
- ];
-
- self.getDoneClass = function (item) {
- return {
- finished: item.done,
- unfinished: !item.done
- };
- };
- }]);
diff --git a/framework/src/onos/web/gui/src/main/webapp/_sdh/ng-examples/js/ch09-01-time-ago.js b/framework/src/onos/web/gui/src/main/webapp/_sdh/ng-examples/js/ch09-01-time-ago.js
deleted file mode 100644
index 1a8b7f1c..00000000
--- a/framework/src/onos/web/gui/src/main/webapp/_sdh/ng-examples/js/ch09-01-time-ago.js
+++ /dev/null
@@ -1,27 +0,0 @@
-// ch09-01-time-ago.js
-
-angular.module('filterApp', [])
- .filter('timeAgo', [function () {
- var _m = 1000 * 60,
- _h = _m * 60,
- _d = _h * 24,
- _mon = _d * 30;
-
- return function (ts, ignoreSecs) {
- var showSecs = !ignoreSecs,
- now = new Date().getTime(),
- diff = now - ts;
-
- if (diff < _m && showSecs) {
- return 'seconds ago';
- } else if (diff < _h) {
- return 'minutes ago';
- } else if (diff < _d) {
- return 'hours ago';
- } else if (diff < _mon) {
- return 'days ago';
- } else {
- return 'months ago';
- }
- }
- }]);