Modifying packaging to make the DHCP GUI work from WAR bundle-style packaging.

Change-Id: I1b9685fa1eebcac63ad41bc60db1f98b30aba656
diff --git a/apps/dhcp/src/main/resources/app/view/dhcp/dhcp.css b/apps/dhcp/src/main/resources/app/view/dhcp/dhcp.css
new file mode 100644
index 0000000..e0a2931
--- /dev/null
+++ b/apps/dhcp/src/main/resources/app/view/dhcp/dhcp.css
@@ -0,0 +1,27 @@
+/*
+ * Copyright 2015 Open Networking Laboratory
+ *
+ * Licensed 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.
+ */
+
+/*
+ ONOS GUI -- DHCP Server -- CSS file
+ */
+
+#ov-dhcp h2 {
+    display: inline-block;
+}
+
+#ov-dhcp div.ctrl-btns {
+    width: 45px;
+}
diff --git a/apps/dhcp/src/main/resources/app/view/dhcp/dhcp.html b/apps/dhcp/src/main/resources/app/view/dhcp/dhcp.html
new file mode 100644
index 0000000..3e14570
--- /dev/null
+++ b/apps/dhcp/src/main/resources/app/view/dhcp/dhcp.html
@@ -0,0 +1,47 @@
+<!-- DHCP Server partial HTML -->
+<div id="ov-dhcp">
+  <div class="tabular-header">
+    <h2>DHCP Mappings ({{tableData.length}} total)</h2>
+    <div class="ctrl-btns">
+      <div class="refresh" ng-class="{active: autoRefresh}"
+           icon icon-size="36" icon-id="refresh"
+           tooltip tt-msg="autoRefreshTip"
+           ng-click="toggleRefresh()"></div>
+    </div>
+  </div>
+
+  <div class="summary-list" onos-table-resize>
+    <div ng-show="loading" class="loading-wheel"
+         icon icon-id="loading" icon-size="75"></div>
+
+    <div class="table-header" onos-sortable-header>
+      <table>
+        <tr>
+          <td colId="mac" sortable>MAC Address</td>
+          <td colId="ip" sortable>IP Address</td>
+          <td colId="lease" sortable>Lease Expiry</td>
+        </tr>
+      </table>
+    </div>
+
+    <div class="table-body">
+      <table onos-flash-changes id-prop="mac">
+        <tr ng-if="!tableData.length" class="no-data">
+          <td colspan="2">
+            No mappings found
+          </td>
+        </tr>
+
+        <tr ng-repeat="dhcp in tableData track by $index"
+            ng-click="selectCallback($event, dhcp)"
+            ng-repeat-complete row-id="{{dhcp.mac}}">
+          <td>{{dhcp.mac}}</td>
+          <td>{{dhcp.ip}}</td>
+          <td>{{dhcp.lease}}</td>
+        </tr>
+      </table>
+    </div>
+
+  </div>
+
+</div>
diff --git a/apps/dhcp/src/main/resources/app/view/dhcp/dhcp.js b/apps/dhcp/src/main/resources/app/view/dhcp/dhcp.js
new file mode 100644
index 0000000..061d0de
--- /dev/null
+++ b/apps/dhcp/src/main/resources/app/view/dhcp/dhcp.js
@@ -0,0 +1,51 @@
+/*
+ * Copyright 2015 Open Networking Laboratory
+ *
+ * Licensed 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.
+ */
+
+/*
+ ONOS GUI -- DHCP Server View Module
+ */
+
+(function () {
+    'use strict';
+
+    // injected refs
+    var $log, $scope;
+
+    angular.module('ovDhcp', [])
+        .controller('OvDhcpCtrl',
+        ['$log', '$scope', 'TableBuilderService',
+
+            function (_$log_, _$scope_, tbs) {
+                $log = _$log_;
+                $scope = _$scope_;
+
+                function selCb($event, row) {
+                    $log.debug('Got a click on:', row);
+                }
+
+                tbs.buildTable({
+                    scope: $scope,
+                    tag: 'dhcp',
+                    selCb: selCb
+                });
+
+                $scope.$on('$destroy', function () {
+                    $log.debug('OvDhcpCtrl has been destroyed');
+                });
+
+                $log.log('OvDhcpCtrl has been created');
+            }]);
+}());
\ No newline at end of file
diff --git a/apps/dhcp/src/main/resources/gui/css.html b/apps/dhcp/src/main/resources/gui/css.html
new file mode 100644
index 0000000..d02ad44
--- /dev/null
+++ b/apps/dhcp/src/main/resources/gui/css.html
@@ -0,0 +1 @@
+<link rel="stylesheet" href="app/view/dhcp/dhcp.css">
\ No newline at end of file
diff --git a/apps/dhcp/src/main/resources/gui/js.html b/apps/dhcp/src/main/resources/gui/js.html
new file mode 100644
index 0000000..d37b576
--- /dev/null
+++ b/apps/dhcp/src/main/resources/gui/js.html
@@ -0,0 +1 @@
+<script src="app/view/dhcp/dhcp.js"></script>
\ No newline at end of file