ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akovale...@apache.org
Subject ambari git commit: AMBARI-13224. "Retry" button is not work properly on "Enable Kerberos Wizard" at "Kerberize Cluster" step (akovalenko)
Date Thu, 24 Sep 2015 12:56:37 GMT
Repository: ambari
Updated Branches:
  refs/heads/trunk 43da8facc -> 49c10612c


AMBARI-13224. "Retry" button is not work properly on "Enable Kerberos Wizard" at "Kerberize
Cluster" step (akovalenko)


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

Branch: refs/heads/trunk
Commit: 49c10612c00c5b321d3550b6d8137d9024900341
Parents: 43da8fa
Author: Aleksandr Kovalenko <akovalenko@hortonworks.com>
Authored: Thu Sep 24 15:56:05 2015 +0300
Committer: Aleksandr Kovalenko <akovalenko@hortonworks.com>
Committed: Thu Sep 24 15:56:05 2015 +0300

----------------------------------------------------------------------
 .../main/admin/kerberos/step5_controller.js     | 51 ++++++++++----------
 .../main/admin/kerberos/step7_controller.js     |  5 +-
 ambari-web/app/routes/add_kerberos_routes.js    |  3 --
 3 files changed, 28 insertions(+), 31 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/49c10612/ambari-web/app/controllers/main/admin/kerberos/step5_controller.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/controllers/main/admin/kerberos/step5_controller.js b/ambari-web/app/controllers/main/admin/kerberos/step5_controller.js
index e42c156..3d16f84 100644
--- a/ambari-web/app/controllers/main/admin/kerberos/step5_controller.js
+++ b/ambari-web/app/controllers/main/admin/kerberos/step5_controller.js
@@ -162,31 +162,30 @@ App.KerberosWizardStep5Controller = App.KerberosProgressPageController.extend({
   }.property('status'),
 
   confirmProperties: function () {
-    var kdc_type = App.router.kerberosWizardController.content.serviceConfigProperties.findProperty('name','kdc_type').value,
-      filterObject = [
-        {
-          key: Em.I18n.t('admin.kerberos.wizard.step1.option.kdc'),
-          properties: ['kdc_type','kdc_host','realm','executable_search_paths']
-        },
-        {
-          key: Em.I18n.t('admin.kerberos.wizard.step1.option.ad'),
-          properties: ['kdc_type','kdc_host','realm','ldap_url','container_dn','executable_search_paths']
-        },
-        {
-          key: Em.I18n.t('admin.kerberos.wizard.step1.option.manual'),
-          properties: ['kdc_type','realm','executable_search_paths']
-        }
-      ],
-      kdcTypeProperties = filterObject.filter(function(item) {
-        return item.key === kdc_type;
-      }),
-      filterBy = kdcTypeProperties.length ? kdcTypeProperties[0].properties : [],
-      returnArray = App.router.kerberosWizardController.content.serviceConfigProperties.filter(function(item)
{
-        return filterBy.contains(item.name);
-      }).map(function(item) {
-        item['label'] = Em.I18n.t('admin.kerberos.wizard.step5.'+item['name']+'.label');
-        return item;
-      });
-    return returnArray;
+    var kdc_type = App.router.get('kerberosWizardController.content.kerberosOption'),
+        filterObject = [
+          {
+            key: Em.I18n.t('admin.kerberos.wizard.step1.option.kdc'),
+            properties: ['kdc_type', 'kdc_host', 'realm', 'executable_search_paths']
+          },
+          {
+            key: Em.I18n.t('admin.kerberos.wizard.step1.option.ad'),
+            properties: ['kdc_type', 'kdc_host', 'realm', 'ldap_url', 'container_dn', 'executable_search_paths']
+          },
+          {
+            key: Em.I18n.t('admin.kerberos.wizard.step1.option.manual'),
+            properties: ['kdc_type', 'realm', 'executable_search_paths']
+          }
+        ],
+        kdcTypeProperties = filterObject.filter(function (item) {
+          return item.key === kdc_type;
+        }),
+        filterBy = kdcTypeProperties.length ? kdcTypeProperties[0].properties : [];
+    return App.router.kerberosWizardController.content.serviceConfigProperties.filter(function
(item) {
+      return filterBy.contains(item.name);
+    }).map(function (item) {
+      item['label'] = Em.I18n.t('admin.kerberos.wizard.step5.' + item['name'] + '.label');
+      return item;
+    });
   }.property('App.router.kerberosWizardController.content.@each.serviceConfigProperties')
 });

http://git-wip-us.apache.org/repos/asf/ambari/blob/49c10612/ambari-web/app/controllers/main/admin/kerberos/step7_controller.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/controllers/main/admin/kerberos/step7_controller.js b/ambari-web/app/controllers/main/admin/kerberos/step7_controller.js
index ece50d7..71e94ca 100644
--- a/ambari-web/app/controllers/main/admin/kerberos/step7_controller.js
+++ b/ambari-web/app/controllers/main/admin/kerberos/step7_controller.js
@@ -113,11 +113,12 @@ App.KerberosWizardStep7Controller = App.KerberosProgressPageController.extend({
 
   retry: function () {
     this.set('showRetry', false);
+    this.removeObserver('tasks.@each.status', this, 'onTaskStatusChange');
+    this.set('status', 'IN_PROGRESS');
     this.get('tasks').setEach('status', 'PENDING');
-    App.router.send('retry');
+    this.setRequest(true);
   },
 
-
   /**
    * Enable or disable previous steps according to tasks statuses
    */

http://git-wip-us.apache.org/repos/asf/ambari/blob/49c10612/ambari-web/app/routes/add_kerberos_routes.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/routes/add_kerberos_routes.js b/ambari-web/app/routes/add_kerberos_routes.js
index d60ba79..ab4752f 100644
--- a/ambari-web/app/routes/add_kerberos_routes.js
+++ b/ambari-web/app/routes/add_kerberos_routes.js
@@ -347,9 +347,6 @@ module.exports = App.WizardRoute.extend({
         controller.connectOutlet('kerberosWizardStep7', controller.get('content'));
       });
     },
-    retry: function (router) {
-      router.get('kerberosWizardStep7Controller').setRequest(true);
-    },
     unroutePath: function () {
       return false;
     },


Mime
View raw message