Repository: ambari
Updated Branches:
  refs/heads/branch-1.7.0 08bae4fc8 -> 1cc2d64e5


AMBARI-7930 Jobs View: queries are not linking. (Buzhor Denys via ababiichuk)


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

Branch: refs/heads/branch-1.7.0
Commit: 1cc2d64e5892093a561d699c6f0a965a6794cfec
Parents: 08bae4f
Author: aBabiichuk <[email protected]>
Authored: Thu Oct 23 19:47:25 2014 +0300
Committer: aBabiichuk <[email protected]>
Committed: Thu Oct 23 21:00:49 2014 +0300

----------------------------------------------------------------------
 .../resources/ui/app/scripts/mappers/jobs/hive_job_mapper.js  | 2 +-
 .../resources/ui/app/scripts/mappers/jobs/hive_jobs_mapper.js | 7 ++++---
 2 files changed, 5 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/1cc2d64e/contrib/views/jobs/src/main/resources/ui/app/scripts/mappers/jobs/hive_job_mapper.js
----------------------------------------------------------------------
diff --git 
a/contrib/views/jobs/src/main/resources/ui/app/scripts/mappers/jobs/hive_job_mapper.js
 
b/contrib/views/jobs/src/main/resources/ui/app/scripts/mappers/jobs/hive_job_mapper.js
index 059c08a..80d484d 100644
--- 
a/contrib/views/jobs/src/main/resources/ui/app/scripts/mappers/jobs/hive_job_mapper.js
+++ 
b/contrib/views/jobs/src/main/resources/ui/app/scripts/mappers/jobs/hive_job_mapper.js
@@ -53,7 +53,7 @@ App.hiveJobMapper = App.QuickDataMapper.create({
       else {
         hiveJob.endTime = json.endtime;
       }
-      json.otherinfo.query = $.parseJSON(json.otherinfo.query);
+      json.otherinfo.query = $.parseJSON(Em.get(json, 'otherinfo.query') || 
Em.get(json, 'otherinfo.QUERY'));
       if (json.otherinfo.query && json.otherinfo.query.queryText) {
         hiveJob.query_text = json.otherinfo.query.queryText;
       }

http://git-wip-us.apache.org/repos/asf/ambari/blob/1cc2d64e/contrib/views/jobs/src/main/resources/ui/app/scripts/mappers/jobs/hive_jobs_mapper.js
----------------------------------------------------------------------
diff --git 
a/contrib/views/jobs/src/main/resources/ui/app/scripts/mappers/jobs/hive_jobs_mapper.js
 
b/contrib/views/jobs/src/main/resources/ui/app/scripts/mappers/jobs/hive_jobs_mapper.js
index 1cdb76d..f0ddf72 100644
--- 
a/contrib/views/jobs/src/main/resources/ui/app/scripts/mappers/jobs/hive_jobs_mapper.js
+++ 
b/contrib/views/jobs/src/main/resources/ui/app/scripts/mappers/jobs/hive_jobs_mapper.js
@@ -23,19 +23,20 @@ App.hiveJobsMapper = App.QuickDataMapper.create({
     user: 'primaryfilters.user',
     hasTezDag: {
       custom: function(source) {
-        var query = Ember.get(source, 'otherinfo.query');
+        var query = Ember.get(source, 'otherinfo.query') || Ember.get(source, 
'otherinfo.QUERY');
         return Ember.isNone(query) ? false : 
query.match("\"Tez\".*\"DagName:\"");
       }
     },
     queryText: {
       custom: function(source) {
-        var query = Ember.get(source, 'otherinfo.query');
+        var query = Ember.get(source, 'otherinfo.query') || Ember.get(source, 
'otherinfo.QUERY');
         return Ember.isNone(query) ? '' : $.parseJSON(query).queryText;
       }
     },
     failed: {
       custom: function(source) {
-        return Ember.get(source ,'otherinfo.status') === false;
+        var status = Ember.get(source ,'otherinfo.status') || Ember.get(source 
,'otherinfo.STATUS');
+        return status === false;
       }
     },
     startTime: {

Reply via email to