From 4143478be3b23c786cc822a3b4845a6f18547dc7 Mon Sep 17 00:00:00 2001 From: Olivier Lamy Date: Wed, 15 Feb 2012 17:41:36 +0000 Subject: [PATCH] add layout/files for search/browse screens git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1244604 13f79535-47bb-0310-9956-ffa450edef68 --- .../src/main/webapp/index.html | 1 + .../src/main/webapp/js/archiva/main-tmpl.js | 6 +++-- .../src/main/webapp/js/archiva/search.js | 27 +++++++++++++++++++ .../webapp/js/archiva/templates/menu.html | 10 +++++++ .../webapp/js/archiva/templates/search.html | 18 +++++++++++++ 5 files changed, 60 insertions(+), 2 deletions(-) create mode 100644 archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/search.js create mode 100644 archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/search.html diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/index.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/index.html index 740d9ea74..76e2ad8ee 100644 --- a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/index.html +++ b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/index.html @@ -87,6 +87,7 @@ $.ajax( .script(buildLoadJsUrl("archiva/proxy-connectors.js")).wait() .script(buildLoadJsUrl("redback/operation.js")).wait() .script(buildLoadJsUrl("archiva/repository-groups.js")).wait() + .script(buildLoadJsUrl("archiva/search.js")).wait() .script(buildLoadJsUrl("redback/redback-tmpl.js")).wait() .script(buildLoadJsUrl("bootstrap.js")) .script(buildLoadJsUrl("knockout.simpleGrid.js")) diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/main-tmpl.js b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/main-tmpl.js index 743f009fd..e44dd0707 100644 --- a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/main-tmpl.js +++ b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/main-tmpl.js @@ -24,9 +24,10 @@ require(["text!js/archiva/templates/menu.html"+appendTemplateUrl(), "text!js/archiva/templates/repositories.html?"+appendTemplateUrl(), "text!js/archiva/templates/network-proxies.html?"+appendTemplateUrl(), "text!js/archiva/templates/proxy-connectors.html?"+appendTemplateUrl(), - "text!js/archiva/templates/repository-groups.html?"+appendTemplateUrl()], + "text!js/archiva/templates/repository-groups.html?"+appendTemplateUrl(), + "text!js/archiva/templates/search.html?"+appendTemplateUrl()], function(menu,topbar,message,modal,grids_generics,repositories,network_proxies,proxies_connectors, - repository_groups) { + repository_groups,search) { // template loading $.tmpl( menu ).appendTo("#html-fragments"); @@ -38,6 +39,7 @@ require(["text!js/archiva/templates/menu.html"+appendTemplateUrl(), $("#html-fragments").append(network_proxies); $("#html-fragments").append(proxies_connectors); $("#html-fragments").append(repository_groups); + $("#html-fragments").append(search); $.log("main-tmpl.js loaded"); } ); \ No newline at end of file diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/search.js b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/search.js new file mode 100644 index 000000000..b8dcdaad0 --- /dev/null +++ b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/search.js @@ -0,0 +1,27 @@ +/* + * 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() { + displayBrowse=function(){ + $("#main-content" ).html("coming soon :-)"); + } + + displaySearch=function(){ + $("#main-content" ).html("coming soon :-)"); + } +}); \ No newline at end of file diff --git a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/menu.html b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/menu.html index c9584125a..27b45443e 100644 --- a/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/menu.html +++ b/archiva-modules/archiva-web/archiva-webapp-js/src/main/webapp/js/archiva/templates/menu.html @@ -18,6 +18,16 @@ -->