cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bfede...@apache.org
Subject [05/28] git commit: updated refs/heads/master to 35164fd
Date Mon, 13 May 2013 18:10:53 GMT
WIP: Service provider module

-Add 'add service provider' module to assist with creating a new
 service provider UI

-Add required functionality to append service provider to hardcoded list

-Add basic ASA 1000v provider to list (name, id, state)


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

Branch: refs/heads/master
Commit: 908115203e6997ad8bea6e273a10865e38726877
Parents: f094142
Author: Brian Federle <brian.federle@citrix.com>
Authored: Thu Apr 18 15:13:14 2013 -0700
Committer: Brian Federle <brian.federle@citrix.com>
Committed: Thu Apr 18 15:13:14 2013 -0700

----------------------------------------------------------------------
 .../asa1000vNetworkProvider.js                     |   25 ++++++++++
 ui/modules/infrastructure/infrastructure.js        |   37 +++++++++++++++
 ui/modules/modules.js                              |    2 +
 ui/scripts/system.js                               |    4 ++
 4 files changed, 68 insertions(+), 0 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/90811520/ui/modules/asa1000vNetworkProvider/asa1000vNetworkProvider.js
----------------------------------------------------------------------
diff --git a/ui/modules/asa1000vNetworkProvider/asa1000vNetworkProvider.js b/ui/modules/asa1000vNetworkProvider/asa1000vNetworkProvider.js
new file mode 100644
index 0000000..3855daf
--- /dev/null
+++ b/ui/modules/asa1000vNetworkProvider/asa1000vNetworkProvider.js
@@ -0,0 +1,25 @@
+// 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.
+(function($, cloudStack) {
+  cloudStack.modules.asa1000vNetworkProvider = function(module) {
+    module.infrastructure.networkServiceProvider({
+      id: 'ciscoAsa1000v',
+      name: 'Cisco ASA 1000v',
+      state: 'Disabled'
+    });
+  };
+}(jQuery, cloudStack));
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/90811520/ui/modules/infrastructure/infrastructure.js
----------------------------------------------------------------------
diff --git a/ui/modules/infrastructure/infrastructure.js b/ui/modules/infrastructure/infrastructure.js
new file mode 100644
index 0000000..01cc4d7
--- /dev/null
+++ b/ui/modules/infrastructure/infrastructure.js
@@ -0,0 +1,37 @@
+// 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.
+(function($, cloudStack) {
+  cloudStack.modules.infrastructure = function(module) {
+    module.pluginAPI.extend({
+      networkServiceProvider: function(args) {
+        var name = args.name;
+        var id = args.id;
+        var state = args.state;
+
+        $(window).bind('cloudStack.system.serviceProviders.makeHarcodedArray', function(event,
data) {
+          var nspHardcodingArray = data.nspHardcodingArray;
+
+          nspHardcodingArray.push({
+            id: id,
+            name: name,
+            state: state
+          });
+        });
+      }
+    });
+  };
+}(jQuery, cloudStack));
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/90811520/ui/modules/modules.js
----------------------------------------------------------------------
diff --git a/ui/modules/modules.js b/ui/modules/modules.js
index 490749f..f5dd62a 100644
--- a/ui/modules/modules.js
+++ b/ui/modules/modules.js
@@ -16,5 +16,7 @@
 // under the License.
 (function($, cloudStack) {
   cloudStack.modules = [
+    'infrastructure',
+    'asa1000vNetworkProvider'
   ];
 }(jQuery, cloudStack));

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/90811520/ui/scripts/system.js
----------------------------------------------------------------------
diff --git a/ui/scripts/system.js b/ui/scripts/system.js
index 73bf3fd..f888169 100644
--- a/ui/scripts/system.js
+++ b/ui/scripts/system.js
@@ -11666,6 +11666,10 @@
                         }
 		];
 
+    $(window).trigger('cloudStack.system.serviceProviders.makeHarcodedArray', {
+      nspHardcodingArray: nspHardcodingArray
+    });
+
 		if(selectedZoneObj.networktype == "Basic") {
 			nspHardcodingArray.push(
 				{


Mime
View raw message