ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From onechipore...@apache.org
Subject [4/5] git commit: AMBARI-6507. Create mappers for models. (onechiporenko)
Date Wed, 16 Jul 2014 16:09:24 GMT
AMBARI-6507. Create mappers for models. (onechiporenko)


Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/b76efd5b
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/b76efd5b
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/b76efd5b

Branch: refs/heads/trunk
Commit: b76efd5b63eedd6bafd7ab484bf2ec4a3c763b1d
Parents: 2636029
Author: Oleg Nechiporenko <onechiporenko@apache.org>
Authored: Wed Jul 16 18:42:35 2014 +0300
Committer: Oleg Nechiporenko <onechiporenko@apache.org>
Committed: Wed Jul 16 18:42:35 2014 +0300

----------------------------------------------------------------------
 .../jobs/src/main/resources/ui/Gruntfile.js     |   7 +-
 .../src/main/resources/ui/app/scripts/app.js    |  26 +-
 .../ui/app/scripts/assets/hive-queries.json     | 232 ++++++++
 .../ui/app/scripts/assets/hive-query-2.json     |   8 +
 .../app/scripts/assets/tezDag-name-to-id.json   | 552 +++++++++++++++++++
 .../resources/ui/app/scripts/assets/tezDag.json |  21 +
 .../ui/app/scripts/assets/tezDagVertex.json     | 221 ++++++++
 .../resources/ui/app/scripts/helpers/ajax.js    | 151 +++++
 .../resources/ui/app/scripts/helpers/date.js    |   5 +-
 .../app/scripts/mappers/jobs/hive_job_mapper.js | 217 ++++++++
 .../scripts/mappers/jobs/hive_jobs_mapper.js    |  96 ++++
 .../app/scripts/mappers/server_data_mapper.js   | 133 +++++
 .../main/resources/ui/app/scripts/models/job.js |  69 ---
 .../ui/app/scripts/models/jobs/abstract_job.js  |   6 +-
 .../ui/app/scripts/models/jobs/hive_job.js      |   2 +-
 .../ui/app/scripts/models/jobs/tez_dag.js       |  17 +-
 .../main/resources/ui/app/scripts/models/run.js | 121 ----
 .../src/main/resources/ui/app/scripts/router.js |   3 +-
 .../ui/app/scripts/routes/application_route.js  |  26 +-
 .../src/main/resources/ui/app/scripts/store.js  |   2 +-
 20 files changed, 1696 insertions(+), 219 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/b76efd5b/contrib/views/jobs/src/main/resources/ui/Gruntfile.js
----------------------------------------------------------------------
diff --git a/contrib/views/jobs/src/main/resources/ui/Gruntfile.js b/contrib/views/jobs/src/main/resources/ui/Gruntfile.js
index 5ebf75d..b5ce07b 100644
--- a/contrib/views/jobs/src/main/resources/ui/Gruntfile.js
+++ b/contrib/views/jobs/src/main/resources/ui/Gruntfile.js
@@ -255,10 +255,11 @@ module.exports = function (grunt) {
             cwd: '<%= yeoman.app %>',
             dest: '<%= yeoman.dist %>',
             src: [
-              '*.{ico,txt,php}',
+              '*.{ico,txt}',
               '.htaccess',
               'images/{,*/}*.{webp,gif}',
-              'styles/fonts/*'
+              'styles/fonts/*',
+              'scripts/assets/**/*'
             ]
           }
         ]
@@ -366,7 +367,7 @@ module.exports = function (grunt) {
     'concat',
     'cssmin',
     //'uglify',
-    'copy',
+    'copy:dist',
     //'rev',
     'usemin'
   ]);

http://git-wip-us.apache.org/repos/asf/ambari/blob/b76efd5b/contrib/views/jobs/src/main/resources/ui/app/scripts/app.js
----------------------------------------------------------------------
diff --git a/contrib/views/jobs/src/main/resources/ui/app/scripts/app.js b/contrib/views/jobs/src/main/resources/ui/app/scripts/app.js
index f4e1295..5622f4a 100644
--- a/contrib/views/jobs/src/main/resources/ui/app/scripts/app.js
+++ b/contrib/views/jobs/src/main/resources/ui/app/scripts/app.js
@@ -20,12 +20,32 @@ var App = window.App = Ember.Application.create();
 
 App.Helpers = Ember.Namespace.create();
 
+App.initializer({
+
+  name: "preload",
+
+  initialize: function(container, application) {
+
+    application.reopen({
+      /**
+       * Test mode is automatically enabled if running on localhost
+       * @type {bool}
+       */
+      testMode: (location.hostname == 'localhost')
+    });
+
+  }
+});
+
+
 /* Order and include as you please. */
-require('scripts/helpers/*');
-require('scripts/controllers/*');
+require('scripts/router');
 require('scripts/store');
+require('scripts/helpers/*');
 require('scripts/models/**/*');
+require('scripts/mappers/server_data_mapper.js');
+require('scripts/mappers/**/*');
+require('scripts/controllers/*');
 require('scripts/routes/*');
 require('scripts/components/*');
 require('scripts/views/*');
-require('scripts/router');


Mime
View raw message