GUI -- Fixed application upload/install functionality.

Change-Id: I5b02ff7470bda46b76bc067b64514204b474fb97
diff --git a/web/gui/src/main/webapp/WEB-INF/web.xml b/web/gui/src/main/webapp/WEB-INF/web.xml
index f83fbad..ace06db 100644
--- a/web/gui/src/main/webapp/WEB-INF/web.xml
+++ b/web/gui/src/main/webapp/WEB-INF/web.xml
@@ -139,6 +139,7 @@
             <param-name>com.sun.jersey.config.property.classnames</param-name>
             <param-value>
                 org.onosproject.ui.impl.TopologyResource,
+                org.onosproject.ui.impl.ApplicationResource
             </param-value>
         </init-param>
         <load-on-startup>1</load-on-startup>
diff --git a/web/gui/src/main/webapp/app/view/app/app.html b/web/gui/src/main/webapp/app/view/app/app.html
index c57da76..b3cc209 100644
--- a/web/gui/src/main/webapp/app/view/app/app.html
+++ b/web/gui/src/main/webapp/app/view/app/app.html
@@ -13,10 +13,13 @@
             <div id="app-uninstall"  icon icon-size="36" icon-id="minus"></div>
         </div>
 
-        <form id="app-form" method="POST" action="/onos/v1/applications/upload" enctype="multipart/form-data" style="display:none">
-            <input type="file" id="file" accept=".oar">
+        <form id="app-form" method="POST" action="rs/applications/upload"
+              target="app-form-response" enctype="multipart/form-data" style="display:none">
+            <input type="file" name="file" id="file" size="50" accept=".oar">
             <button type="submit" id="app-upload">Upload</button>
         </form>
+        <iframe id="app-form-response" name="app-form-response"
+                src="" width="0" height="0" style="visibility:hidden;display:none"></iframe>
     </div>
 
     <div class="summary-list" onos-fixed-header>
diff --git a/web/gui/src/main/webapp/app/view/app/app.js b/web/gui/src/main/webapp/app/view/app/app.js
index 674407b..cacd5e0 100644
--- a/web/gui/src/main/webapp/app/view/app/app.js
+++ b/web/gui/src/main/webapp/app/view/app/app.js
@@ -51,6 +51,11 @@
             $scope.sortCallback();
         };
 
+        document.getElementById('app-form-response').onload = function () {
+            document.getElementById('app-form').reset();
+            $scope.refresh();
+        }
+
         function appAction(action) {
             if (selection) {
                 $log.debug('Initiating uninstall of', selection);