You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by nc...@apache.org on 2016/01/15 18:33:39 UTC

[15/50] [abbrv] ambari git commit: AMBARI-14635. Ambari Admin: Add new "Settings" section (alexantonenko)

AMBARI-14635. Ambari Admin: Add new "Settings" section (alexantonenko)


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

Branch: refs/heads/branch-dev-patch-upgrade
Commit: 377901dacbacd62ecd3688bfa934203a760fa2fc
Parents: f181e9e
Author: Alex Antonenko <hi...@gmail.com>
Authored: Tue Jan 12 20:58:08 2016 +0200
Committer: Nate Cole <nc...@hortonworks.com>
Committed: Thu Jan 14 11:43:25 2016 -0500

----------------------------------------------------------------------
 .../main/resources/ui/admin-web/app/index.html  |  2 +
 .../authentication/AuthenticationMainCtrl.js    | 22 +++++++++
 .../loginActivities/LoginActivitiesMainCtrl.js  | 23 +++++++++
 .../ui/admin-web/app/scripts/i18n.config.js     |  8 ++++
 .../ui/admin-web/app/scripts/routes.js          | 12 +++++
 .../app/views/authentication/main.html          | 26 ++++++++++
 .../ui/admin-web/app/views/leftNavbar.html      | 11 ++++-
 .../views/loginActivities/homeDirectory.html    |  1 +
 .../app/views/loginActivities/loginMessage.html |  1 +
 .../app/views/loginActivities/main.html         | 50 ++++++++++++++++++++
 10 files changed, 155 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/377901da/ambari-admin/src/main/resources/ui/admin-web/app/index.html
----------------------------------------------------------------------
diff --git a/ambari-admin/src/main/resources/ui/admin-web/app/index.html b/ambari-admin/src/main/resources/ui/admin-web/app/index.html
index 7b31fff..268e92f 100644
--- a/ambari-admin/src/main/resources/ui/admin-web/app/index.html
+++ b/ambari-admin/src/main/resources/ui/admin-web/app/index.html
@@ -127,6 +127,8 @@
     <script src="scripts/i18n.config.js"></script>
     <script src="scripts/controllers/mainCtrl.js"></script>
     <script src="scripts/controllers/NavbarCtrl.js"></script>
+    <script src="scripts/controllers/authentication/AuthenticationMainCtrl.js"></script>
+    <script src="scripts/controllers/loginActivities/LoginActivitiesMainCtrl.js"></script>
     <script src="scripts/controllers/users/UsersCreateCtrl.js"></script>
     <script src="scripts/controllers/users/UsersListCtrl.js"></script>
     <script src="scripts/controllers/users/UsersShowCtrl.js"></script>

http://git-wip-us.apache.org/repos/asf/ambari/blob/377901da/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/authentication/AuthenticationMainCtrl.js
----------------------------------------------------------------------
diff --git a/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/authentication/AuthenticationMainCtrl.js b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/authentication/AuthenticationMainCtrl.js
new file mode 100644
index 0000000..a746aa3
--- /dev/null
+++ b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/authentication/AuthenticationMainCtrl.js
@@ -0,0 +1,22 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+'use strict';
+
+angular.module('ambariAdminConsole')
+  .controller('AuthenticationMainCtrl',['$scope', function($scope) {
+}]);

http://git-wip-us.apache.org/repos/asf/ambari/blob/377901da/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/loginActivities/LoginActivitiesMainCtrl.js
----------------------------------------------------------------------
diff --git a/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/loginActivities/LoginActivitiesMainCtrl.js b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/loginActivities/LoginActivitiesMainCtrl.js
new file mode 100644
index 0000000..84af924
--- /dev/null
+++ b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/controllers/loginActivities/LoginActivitiesMainCtrl.js
@@ -0,0 +1,23 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+'use strict';
+
+angular.module('ambariAdminConsole')
+  .controller('LoginActivitiesMainCtrl',['$scope', function($scope) {
+    $scope.tab = 'loginMessage';
+  }]);

http://git-wip-us.apache.org/repos/asf/ambari/blob/377901da/ambari-admin/src/main/resources/ui/admin-web/app/scripts/i18n.config.js
----------------------------------------------------------------------
diff --git a/ambari-admin/src/main/resources/ui/admin-web/app/scripts/i18n.config.js b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/i18n.config.js
index 40baf18..04485c6 100644
--- a/ambari-admin/src/main/resources/ui/admin-web/app/scripts/i18n.config.js
+++ b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/i18n.config.js
@@ -66,6 +66,8 @@ angular.module('ambariAdminConsole')
       'all': 'All',
       'group': 'Group',
       'user': 'User',
+      'settings': 'Settings',
+      'authentication': 'Authentication',
       'deleteConfirmation': 'Are you sure you want to delete {{instanceType}} {{instanceName}}?',
       'local': 'Local',
       'ldap': 'LDAP',
@@ -78,6 +80,12 @@ angular.module('ambariAdminConsole')
         'message': 'Are you sure you want to change the cluster name to {{clusterName}}?'
       },
 
+      'loginActivities': {
+        'loginActivities':'Login Activities',
+        'loginMessage': 'Login Message',
+        'homeDirectory': 'Home Directory'
+      },
+
       'controls': {
         'cancel': 'Cancel',
         'close': 'Close',

http://git-wip-us.apache.org/repos/asf/ambari/blob/377901da/ambari-admin/src/main/resources/ui/admin-web/app/scripts/routes.js
----------------------------------------------------------------------
diff --git a/ambari-admin/src/main/resources/ui/admin-web/app/scripts/routes.js b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/routes.js
index 260d0a7..6da7ff4 100644
--- a/ambari-admin/src/main/resources/ui/admin-web/app/scripts/routes.js
+++ b/ambari-admin/src/main/resources/ui/admin-web/app/scripts/routes.js
@@ -24,6 +24,18 @@ angular.module('ambariAdminConsole')
     templateUrl: 'views/main.html',
     controller: 'MainCtrl'
   },
+  authentication: {
+    main: {
+      url: '/authentication',
+      templateUrl: 'views/authentication/main.html',
+      controller: 'AuthenticationMainCtrl'
+    }
+  },
+  loginActivities: {
+      url: '/loginActivities',
+      templateUrl: 'views/loginActivities/main.html',
+      controller: 'LoginActivitiesMainCtrl'
+  },
   users: {
     list: {
       url: '/users',

http://git-wip-us.apache.org/repos/asf/ambari/blob/377901da/ambari-admin/src/main/resources/ui/admin-web/app/views/authentication/main.html
----------------------------------------------------------------------
diff --git a/ambari-admin/src/main/resources/ui/admin-web/app/views/authentication/main.html b/ambari-admin/src/main/resources/ui/admin-web/app/views/authentication/main.html
new file mode 100644
index 0000000..7743d1e
--- /dev/null
+++ b/ambari-admin/src/main/resources/ui/admin-web/app/views/authentication/main.html
@@ -0,0 +1,26 @@
+<!--
+* Licensed to the Apache Software Foundation (ASF) under one
+* or more contributor license agreements.  See the NOTICE file
+* distributed with this work for additional information
+* regarding copyright ownership.  The ASF licenses this file
+* to you under the Apache License, Version 2.0 (the
+* "License"); you may not use this file except in compliance
+* with the License.  You may obtain a copy of the License at
+*
+*     http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+-->
+
+<div class="users-pane">
+  <div class="clearfix">
+    <ol class="breadcrumb pull-left">
+      <li class="active">{{'common.authentication' | translate}}</li>
+    </ol>
+  </div>
+  <hr>
+</div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/377901da/ambari-admin/src/main/resources/ui/admin-web/app/views/leftNavbar.html
----------------------------------------------------------------------
diff --git a/ambari-admin/src/main/resources/ui/admin-web/app/views/leftNavbar.html b/ambari-admin/src/main/resources/ui/admin-web/app/views/leftNavbar.html
index bf7f3a1..17f8f0b 100644
--- a/ambari-admin/src/main/resources/ui/admin-web/app/views/leftNavbar.html
+++ b/ambari-admin/src/main/resources/ui/admin-web/app/views/leftNavbar.html
@@ -102,7 +102,16 @@
         <li ng-class="{active: isActive('users.list')}"><link-to route="users.list" class="userslist-link">{{'common.users' | translate}}</link-to></li>
         <li ng-class="{active: isActive('groups.list')}"><link-to route="groups.list" class="groupslist-link">{{'common.groups' | translate}}</link-to></li>
       </ul>
-        
+    </div>
+  </div>
+
+  <div class="panel panel-default">
+    <div class="panel-heading"><span class="glyphicon glyphicon-cog"></span> {{'common.settings' | translate}}</div>
+    <div class="panel-body">
+      <ul class="nav nav-pills nav-stacked">
+        <li ng-class="{active: isActive('authentication.main')}"><link-to route="authentication.main">{{'common.authentication' | translate}}</link-to></li>
+        <li ng-class="{active: isActive('loginActivities')}"><link-to route="loginActivities">{{'common.loginActivities.loginActivities' | translate}}</link-to></li>
+      </ul>
     </div>
   </div>
 </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/377901da/ambari-admin/src/main/resources/ui/admin-web/app/views/loginActivities/homeDirectory.html
----------------------------------------------------------------------
diff --git a/ambari-admin/src/main/resources/ui/admin-web/app/views/loginActivities/homeDirectory.html b/ambari-admin/src/main/resources/ui/admin-web/app/views/loginActivities/homeDirectory.html
new file mode 100644
index 0000000..87ce7d5
--- /dev/null
+++ b/ambari-admin/src/main/resources/ui/admin-web/app/views/loginActivities/homeDirectory.html
@@ -0,0 +1 @@
+Home Directory
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ambari/blob/377901da/ambari-admin/src/main/resources/ui/admin-web/app/views/loginActivities/loginMessage.html
----------------------------------------------------------------------
diff --git a/ambari-admin/src/main/resources/ui/admin-web/app/views/loginActivities/loginMessage.html b/ambari-admin/src/main/resources/ui/admin-web/app/views/loginActivities/loginMessage.html
new file mode 100644
index 0000000..806e602
--- /dev/null
+++ b/ambari-admin/src/main/resources/ui/admin-web/app/views/loginActivities/loginMessage.html
@@ -0,0 +1 @@
+Login Message
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ambari/blob/377901da/ambari-admin/src/main/resources/ui/admin-web/app/views/loginActivities/main.html
----------------------------------------------------------------------
diff --git a/ambari-admin/src/main/resources/ui/admin-web/app/views/loginActivities/main.html b/ambari-admin/src/main/resources/ui/admin-web/app/views/loginActivities/main.html
new file mode 100644
index 0000000..7b35682
--- /dev/null
+++ b/ambari-admin/src/main/resources/ui/admin-web/app/views/loginActivities/main.html
@@ -0,0 +1,50 @@
+<!--
+* Licensed to the Apache Software Foundation (ASF) under one
+* or more contributor license agreements.  See the NOTICE file
+* distributed with this work for additional information
+* regarding copyright ownership.  The ASF licenses this file
+* to you under the Apache License, Version 2.0 (the
+* "License"); you may not use this file except in compliance
+* with the License.  You may obtain a copy of the License at
+*
+*     http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+-->
+
+<div class="users-pane">
+  <div class="clearfix">
+    <ol class="breadcrumb pull-left">
+      <li class="active">{{'common.loginActivities.loginActivities' | translate}}</li>
+    </ol>
+  </div>
+  <hr>
+  <ul class="nav nav-tabs">
+    <li ng-class="{active: tab == 'loginMessage'}">
+      <a ng-click="tab = 'loginMessage'">{{'common.loginActivities.loginMessage' | translate}}</a>
+    </li>
+    <li ng-class="{active: tab == 'homeDirectory'}">
+      <a ng-click="tab = 'homeDirectory'">{{'common.loginActivities.homeDirectory' | translate}}</a>
+    </li>
+  </ul>
+
+  <div class="tab-content">
+    <div ng-switch = "tab">
+      <div ng-switch-when = "loginMessage">
+        <div ng-include = "'views/loginActivities/loginMessage.html'"></div>
+      </div>
+
+      <div ng-switch-when = "homeDirectory">
+        <div ng-include = "'views/loginActivities/homeDirectory.html'"></div>
+      </div>
+    </div>
+  </div>
+
+
+
+
+</div>